httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject mod_deflate as a DSO on Solaris (perhaps generic?)
Date Sat, 05 Jan 2002 00:38:02 GMT
On my Solaris systems (Solaris 8 for i86 and Sparc), configure finds
/usr/local/lib/libz.a and /usr/local/include/whatever, but
mod_deflate.so won't load because of an unresolved reference to
deflateInit2_.

checking whether to enable mod_deflate... checking dependencies
checking for zlib location... /usr/local
  adding "-I/usr/local/include" to INCLUDES
  setting LDFLAGS to "-L/usr/local/lib"
  adding "-R/lib" to LDFLAGS
  adding "-lz" to LIBS
checking for zlib library... found
checking for zutil.h... no
checking whether to enable mod_deflate... shared

Cannot load /export/home/trawick/apacheinst/modules/mod_deflate.so 
into server: ld.so.1: httpd: fatal: relocation error: file 
/export/home/trawick/apacheinst/modules/mod_deflate.so: symbol 
deflateInit2_: referenced symbol not found

I would guess that the problem is that mod_deflate.so wasn't
statically linked with this libz.a, but I HAVEN'T TRIED IT YET.
Perhaps Solaris ld discarded the libz stuff because it wasn't used by
httpd.

(I hit the same problem on AIX but [erroneously] guessed at the time
that only AIX would need libz.a statically linked with mod_deflate.so
instead of statically linked with httpd.)

How do other folks deal with this?  Always use a shared object libz?
Statically linking it with mod_deflate.so seems less error-prone
(assuming the build is correct), particularly if you want to run a
build on multiple machines.

-- 
Jeff Trawick | trawick@attglobal.net | PGP public key at web site:
       http://www.geocities.com/SiliconValley/Park/9289/
             Born in Roswell... married an alien...

Mime
View raw message