Compiling Apache on 9.1 fails
We're unable to successfully compile Apache (2.0.52) with SUSE 9.1 (2.6.4-52-default) 64bit . We have no problems with the 32bit version of SUSE 9.1 and Apache 2.0.52.. A fresh install of 9.1 started us out. Apache 2.0.52 was downloaded, gunzipped, untarred and configure was run. It fails at the make. We've reinstalled a couple of times but without finding anybody else having problems here, we're not sure what to do next and appreciate any help. Since this is 64 bit we thought the reference to /usr/lib (instead of /usr/lib64) might be causing the problem. We're thinking of just going with the 32bit install... make ... Making all in support make[1]: Entering directory `/root/apache/httpd-2.0.52/support' make[2]: Entering directory `/root/apache/httpd-2.0.52/support' /root/apache/httpd-2.0.52/srclib/apr/libtool --silent --mode=compile gcc -g -O2 -pthread -DLINUX=2 -D_REENTRANT -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -DAP_HAVE_DESIGNATED_INITIALIZER -I/root/apache/httpd-2.0.52/srclib/apr/include -I/root/apache/httpd-2.0.52/srclib/apr-util/include -I. -I/root/apache/httpd-2.0.52/os/unix -I/root/apache/httpd-2.0.52/server/mpm/prefork -I/root/apache/httpd-2.0.52/modules/http -I/root/apache/httpd-2.0.52/modules/filters -I/root/apache/httpd-2.0.52/modules/proxy -I/root/apache/httpd-2.0.52/include -I/root/apache/httpd-2.0.52/modules/generators -I/root/apache/httpd-2.0.52/modules/dav/main -prefer-non-pic -static -c htpasswd.c && touch htpasswd.lo /root/apache/httpd-2.0.52/srclib/apr/libtool --silent --mode=link gcc -g -O2 -pthread -DLINUX=2 -D_REENTRANT -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -DAP_HAVE_DESIGNATED_INITIALIZER -I/root/apache/httpd-2.0.52/srclib/apr/include -I/root/apache/httpd-2.0.52/srclib/apr-util/include -I. -I/root/apache/httpd-2.0.52/os/unix -I/root/apache/httpd-2.0.52/server/mpm/prefork -I/root/apache/httpd-2.0.52/modules/http -I/root/apache/httpd-2.0.52/modules/filters -I/root/apache/httpd-2.0.52/modules/proxy -I/root/apache/httpd-2.0.52/include -I/root/apache/httpd-2.0.52/modules/generators -I/root/apache/httpd-2.0.52/modules/dav/main -export-dynamic -o htpasswd htpasswd.lo /root/apache/httpd-2.0.52/srclib/pcre/libpcre.la /root/apache/httpd-2.0.52/srclib/apr-util/libaprutil-0.la -lexpat /root/apache/httpd-2.0.52/srclib/apr/libapr-0.la -lrt -lm -lcrypt -lnsl -lpthread -ldl /usr/lib/libexpat.so: could not read symbols: Invalid operation collect2: ld returned 1 exit status make[2]: *** [htpasswd] Error 1 make[2]: Leaving directory `/root/apache/httpd-2.0.52/support' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/root/apache/httpd-2.0.52/support' make: *** [all-recursive] Error 1
* HES Support <suse@hesinc.biz> [041027 23:50]:
We're unable to successfully compile Apache (2.0.52) with SUSE 9.1 (2.6.4-52-default) 64bit . We have no problems with the 32bit version of SUSE 9.1 and Apache 2.0.52..
A fresh install of 9.1 started us out. Apache 2.0.52 was downloaded, gunzipped, untarred and configure was run. It fails at the make.
We've reinstalled a couple of times but without finding anybody else having problems here, we're not sure what to do next and appreciate any help. Since this is 64 bit we thought the reference to /usr/lib (instead of /usr/lib64) might be causing the problem. We're thinking of just going with the 32bit install...
make ... /root/apache/httpd-2.0.52/srclib/apr-util/libaprutil-0.la -lexpat /root/apache/httpd-2.0.52/srclib/apr/libapr-0.la -lrt -lm -lcrypt -lnsl -lpthread -ldl /usr/lib/libexpat.so: could not read symbols: Invalid operation ^^^^^^^^^^^^^^^^^^^^^ here you are trying to link a 32bit lib in a 64bit object. That can't work.
Probably sth. went wrong during configuration - check for pathes */lib/
collect2: ld returned 1 exit status make[2]: *** [htpasswd] Error 1 make[2]: Leaving directory `/root/apache/httpd-2.0.52/support' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/root/apache/httpd-2.0.52/support' make: *** [all-recursive] Error 1
-- Check the List-Unsubscribe header to unsubscribe For additional commands, email: suse-amd64-help@suse.com
-- Stefan Fent <stefan.fent@suse.com> SuSE Linux AG, Maxfeldstr. 5, D-90409 Nuernberg Phone: +49-911-740 53 - 559 GPG fingerprint = B226 E3DA 37B0 2170 7403 D19C 18AF E579 9161 4BBC
Thanks, Stefan. We figured it was a library issue but didn't know the best action to take. We've looked through the configure script and logs and didn't see anything of relevance. So, here's what we tried and it seemed to work, although we don't like this fix at all: cd /usr mv lib lib.save ln -s lib64 lib cd /root/apache/httpd-2.0.52 ./configure ./make No make errors this time. While we've moved the 32bit library back into place, taking the above action to succesfully compile apache makes us nervous. Apache is up and running, though... Jim Stefan Fent wrote:
* HES Support <suse@hesinc.biz> [041027 23:50]:
We're unable to successfully compile Apache (2.0.52) with SUSE 9.1 (2.6.4-52-default) 64bit . We have no problems with the 32bit version of SUSE 9.1 and Apache 2.0.52..
A fresh install of 9.1 started us out. Apache 2.0.52 was downloaded, gunzipped, untarred and configure was run. It fails at the make.
We've reinstalled a couple of times but without finding anybody else having problems here, we're not sure what to do next and appreciate any help. Since this is 64 bit we thought the reference to /usr/lib (instead of /usr/lib64) might be causing the problem. We're thinking of just going with the 32bit install...
make ... /root/apache/httpd-2.0.52/srclib/apr-util/libaprutil-0.la -lexpat /root/apache/httpd-2.0.52/srclib/apr/libapr-0.la -lrt -lm -lcrypt -lnsl -lpthread -ldl /usr/lib/libexpat.so: could not read symbols: Invalid operation
^^^^^^^^^^^^^^^^^^^^^ here you are trying to link a 32bit lib in a 64bit object. That can't work.
Probably sth. went wrong during configuration - check for pathes */lib/
collect2: ld returned 1 exit status make[2]: *** [htpasswd] Error 1 make[2]: Leaving directory `/root/apache/httpd-2.0.52/support' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/root/apache/httpd-2.0.52/support' make: *** [all-recursive] Error 1
-- Check the List-Unsubscribe header to unsubscribe For additional commands, email: suse-amd64-help@suse.com
* HES Support (suse@hesinc.biz) [20041028 16:09]:
mv lib lib.save ln -s lib64 lib
cd /root/apache/httpd-2.0.52 ./configure ./make
This is a realy ugly hack. It may allow to compile apache but during that time it'll prevent any 32 bit app to be run. It would be much better to really identify the culprit. Philipp -- Philipp Thomas <pth@suse.de> Research & Development SUSE LINUX AG, Maxfeldstr. 5, D-90409 Nuremberg, Germany
Philipp Thomas wrote:
* HES Support (suse@hesinc.biz) [20041028 16:09]:
mv lib lib.save ln -s lib64 lib
cd /root/apache/httpd-2.0.52 ./configure ./make
This is a realy ugly hack. It may allow to compile apache but during that time it'll prevent any 32 bit app to be run. It would be much better to really identify the culprit.
Philipp
That's a good point, if it's a large app like koffice you are building. There is always the method I mentioned in my previous post. I hope it gets fixed in 9.2. I've googled and there is nothing similar I've found on Mandrake or gentoo, but there are quite a few posts across the hardware spectrum and one thread where H.J Lu the gcc maintainer was looking at this issue back in 1999 and asked if a mailing list should be set up for it, but he got no responses, someone suggested it could possibly be handled in libtool. Regards Sid. -- Sid Boyce .... Hamradio G3VBV and keen Flyer =====LINUX ONLY USED HERE=====
HES Support wrote:
Thanks, Stefan. We figured it was a library issue but didn't know the best action to take. We've looked through the configure script and logs and didn't see anything of relevance. So, here's what we tried and it seemed to work, although we don't like this fix at all:
cd /usr mv lib lib.save ln -s lib64 lib
cd /root/apache/httpd-2.0.52 ./configure ./make
No make errors this time. While we've moved the 32bit library back into place, taking the above action to succesfully compile apache makes us nervous. Apache is up and running, though...
Jim
Very neat. I've found that it always looks in /usr/lib for static libraries, the other way around it is to change all instances of /usr/lib to /usr/lib64 in the configure script, run it, then do the same changes in the Makefiles. Regards Sid. -- Sid Boyce .... Hamradio G3VBV and keen Flyer =====LINUX ONLY USED HERE=====
* HES Support (suse@hesinc.biz) [20041027 23:58]:
Since this is 64 bit we thought the reference to /usr/lib (instead of /usr/lib64) might be causing the problem.
And indeed it is. If you had taken a look at our apache2 source rpm, you'd have seen that we apply this patch (httpd-2.0.36-lib64.dif): --- httpd-2.0.36.orig/srclib/apr-util/build/apu-conf.m4 Sat Apr 20 00:06:34 2002 +++ httpd-2.0.36.lib64/srclib/apr-util/build/apu-conf.m4 Mon Jun 3 22:58:51 2002 @@ -448,6 +448,11 @@ expat_include_dir="$1/include" expat_libs="$1/lib/libexpat.la" elif test -r "$1/include/expat.h" -a \ + -r "$1/lib64/libexpat.la"; then + dnl same, but */lib64/ + expat_include_dir="$1/include" + expat_libs="$1/lib64/libexpat.la" + elif test -r "$1/include/expat.h" -a \ -r "$1/lib/libexpat.a"; then dnl Expat 1.95.* installation (without libtool) dnl FreeBSD textproc/expat2 that looks like it will fix your problem. After applying this patch, you should call the same commands as our spec file does: autoreconf --force --install ./buildconf Philipp -- Philipp Thomas <pth@suse.de> Research & Development SUSE LINUX AG, Maxfeldstr. 5, D-90409 Nuremberg, Germany
Thanks - I'll try that later today. Philipp Thomas wrote:
* HES Support (suse@hesinc.biz) [20041027 23:58]:
Since this is 64 bit we thought the reference to /usr/lib (instead of /usr/lib64) might be causing the problem.
And indeed it is. If you had taken a look at our apache2 source rpm, you'd have seen that we apply this patch (httpd-2.0.36-lib64.dif):
--- httpd-2.0.36.orig/srclib/apr-util/build/apu-conf.m4 Sat Apr 20 00:06:34 2002 +++ httpd-2.0.36.lib64/srclib/apr-util/build/apu-conf.m4 Mon Jun 3 22:58:51 2002 @@ -448,6 +448,11 @@ expat_include_dir="$1/include" expat_libs="$1/lib/libexpat.la" elif test -r "$1/include/expat.h" -a \ + -r "$1/lib64/libexpat.la"; then + dnl same, but */lib64/ + expat_include_dir="$1/include" + expat_libs="$1/lib64/libexpat.la" + elif test -r "$1/include/expat.h" -a \ -r "$1/lib/libexpat.a"; then dnl Expat 1.95.* installation (without libtool) dnl FreeBSD textproc/expat2
that looks like it will fix your problem. After applying this patch, you should call the same commands as our spec file does:
autoreconf --force --install ./buildconf
Philipp
participants (4)
-
HES Support
-
Philipp Thomas
-
Sid Boyce
-
Stefan Fent