When I try to build rpm from src rpm (Apache 2.4.1) I got this error:
rpmbuild -tb httpd-2.4.1.tar.bz2 --ba httpd.spec
+ ./configure --build=x86_64-redhat-linux-gnu --host=x86_64-redhat-linux-gnu --target=noarch-redhat-linux-gnu --program-prefix= --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info --enable-layout=RPM --libdir=/usr/lib64 --sysconfdir=/etc/httpd/conf --includedir=/usr/include/httpd --libexecdir=/usr/lib64/httpd/modules --datadir=/var/www --with-installbuilddir=/usr/lib64/httpd/build --enable-mpms-shared=all --with-apr=/usr --with-apr-util=/usr --enable-suexec --with-suexec --with-suexec-caller=apache --with-suexec-docroot=/var/www --with-suexec-logfile=/var/log/httpd/suexec.log --with-suexec-bin=/usr/sbin/suexec --with-suexec-uidmin=500 --with-suexec-gidmin=100 --enable-pie --with-pcre --enable-mods-shared=all --enable-ssl --with-ssl --enable-socache-dc --enable-bucketeer --enable-case-filter --enable-case-filter-in --disable-imagemap checking for chosen layout... RPM checking for working mkdir -p... yes checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking build system type... x86_64-redhat-linux-gnu checking host system type... x86_64-redhat-linux-gnu checking target system type... Invalid configuration `noarch-redhat-linux-gnu': machine `noarch-redhat' not recognized configure: error: /bin/sh build/config.sub noarch-redhat-linux-gnu failed błąd: Błędny stan wyjścia z /var/tmp/rpm-tmp.48153 (%build) Błędy budowania RPM-a: Błędny stan wyjścia z /var/tmp/rpm-tmp.48153 (%build)
I'm also trying to rpmbuild the Apache 2.4.1 on CentOS 5.5, and I solved that error with modifying the http.spec file:
The line with the --target is added. Compilation is running fine, so far.
From what you have posted it looks as if
noarch-redhat-linux-gnu
is not a recognizedtarget
parameter.I see you are on a
x86_64
machine. Have you tried running./configure
withtarget=x86_64-redhat-linux-gnu
?To fix building
automake 2.69
on an old legacy RPM based Linux the following was needed in thespec
file: