mod_auth_ldap - solaris 10 - apache2

From: Dragos Stoichitescu (dragos.stoichitescu@connex.ro)
Date: Mon Aug 14 2006 - 07:06:21 EDT


 Hi,

I'm having a hard time trying to compile (as a dynamic shared object)
modauthldap against apache2 on a solaris 10 (sparc) box.

#/usr/apache2/bin/httpd -l
Compiled in modules:
 core.c
 prefork.c
 http_core.c
 mod_so.c
So https was compiled with DSO support.

# which gcc
/usr/sfw/bin/gcc

I have installed openldap

# ./configure --with-apxs=/usr/apache2/bin/apxs -with-ldap-dir=/usr/local
creating cache ./config.cache
checking whether make sets ${MAKE}... yes
checking for gcc... gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking for socket... no
checking for __socket... no
checking for socket in -lsocket... yes
checking for htonl... yes
checking for gethostname... yes
checking for gethostbyaddr... no
checking for __gethostbyaddr... no
checking for gethostbyaddr in -lnsl... yes
checking for yp_get_default_domain... yes
checking for res_search... no
checking for __res_search... no
checking for res_search in -lresolv... yes
checking for inet_aton... yes
checking for dn_skipname... yes
checking for Apache 2.0 module support via DSO through APXS... yes
checking for path of LDAP SDK... /usr/local
checking for 3 arg ldap_set_rebind_proc... no
checking for ldap_start_tls_s... yes
checking whether to enable SSL... no
updating cache ./config.cache
creating ./config.status
creating Makefile
creating mk_withldap

======================================================================
You're compiling the module as Dynamic Shared Object (DSO)
Make sure your apache is compiled with DSO support. To test, type
$ /path_of/httpd -l and make sure mod_so.c is in the list

Final Compilation Flags:
 APXS = /usr/apache2/bin/apxs
 DEFINES = -DHAVE_SOCKET=1 -DHAVE_LIBSOCKET=1 -DHAVE_HTONL=1
-DHAVE_GETHOSTNAME=1 -DHAVE_GETHOSTBYADDR=1 -DHAVE_LIBNSL=1
-DHAVE_YP_GET_DEFAULT_DOMAIN=1 -DHAVE_RES_SEARCH=1 -DHAVE_LIBRESOLV=1
-DHAVE_INET_ATON=1 -DHAVE_DN_SKIPNAME=1 -DHAVE_LDAP=1
-DHAVE_LDAP_START_TLS_S=1
 LDAP_DIR = /usr/local
 LDAP_INCLUDE_DIR = /usr/local/include
 LDAP_LIB_DIR = /usr/local/lib
 CPPFLAGS = -I/usr/local/include
 LDFLAGS = -L/usr/local/lib
 LIBS = -lldap -llber -lresolv -lnsl -lsocket
======================================================================
If everything looks ok, at the shell prompt, type:
make
make install

# make
/usr/apache2/bin/apxs -c -DHAVE_SOCKET=1 -DHAVE_LIBSOCKET=1
-DHAVE_HTONL=1 -DHAVE_GETHOSTNAME=1 -DHAVE_GETHOSTBYADDR=1
-DHAVE_LIBNSL=1 -DHAVE_YP_GET_DEFAULT_DOMAIN=1 -DHAVE_RES_SEARCH=1
-DHAVE_LIBRESOLV=1 -DHAVE_INET_ATON=1 -DHAVE_DN_SKIPNAME=1 -DHAVE_LDAP=1
-DHAVE_LDAP_START_TLS_S=1 -I/usr/local/include mod_auth_ldap.c
/var/apache2/build/libtool --silent --mode=compile /opt/SUNWspro/bin/cc
-prefer-pic -xO3 -xarch=v8 -xspace -W0,-Lt -W2,-Rcond_elim -Xa -xildoff
-DSSL_EXPERIMENTAL -DSSL_ENGINE -DSOLARIS2=10 -D_POSIX_PTHREAD_SEMANTICS
-D_REENTRANT -I/usr/apache2/include -I/usr/apache2/include
-I/usr/apache2/include -I/usr/local/include -DHAVE_SOCKET=1
-DHAVE_LIBSOCKET=1 -DHAVE_HTONL=1 -DHAVE_GETHOSTNAME=1
-DHAVE_GETHOSTBYADDR=1 -DHAVE_LIBNSL=1 -DHAVE_YP_GET_DEFAULT_DOMAIN=1
-DHAVE_RES_SEARCH=1 -DHAVE_LIBRESOLV=1 -DHAVE_INET_ATON=1
-DHAVE_DN_SKIPNAME=1 -DHAVE_LDAP=1 -DHAVE_LDAP_START_TLS_S=1 -c -o
mod_auth_ldap.lo mod_auth_ldap.c && touch mod_auth_ldap.slo
"mod_auth_ldap.c", line 759: warning: implicit function declaration:
ldap_simple_bind_s
"mod_auth_ldap.c", line 786: warning: implicit function declaration:
ldap_search_s
"mod_auth_ldap.c", line 978: warning: implicit function declaration:
ldap_get_values
"mod_auth_ldap.c", line 978: warning: improper pointer/integer
combination: op "="
"mod_auth_ldap.c", line 1203: warning: implicit function declaration:
getpid
"mod_auth_ldap.c", line 1204: warning: implicit function declaration:
ldap_init
"mod_auth_ldap.c", line 1204: warning: improper pointer/integer
combination: op "="
"mod_auth_ldap.c", line 1296: warning: implicit function declaration:
ldap_unbind
"mod_auth_ldap.c", line 1528: warning: implicit function declaration:
ldap_compare_s
/var/apache2/build/libtool --silent --mode=link /opt/SUNWspro/bin/cc -o
mod_auth_ldap.la -rpath /usr/apache2/libexec -module -avoid-version
mod_auth_ldap.lo
/usr/apache2/bin/apxs -c mod_auth_ldap.o -L/usr/local/lib -lldap -llber
-lresolv -lnsl -lsocket
/var/apache2/build/libtool --silent --mode=link /opt/SUNWspro/bin/cc -o
mod_auth_ldap.la -rpath /usr/apache2/libexec -module -avoid-version
mod_auth_ldap.o -L/usr/local/lib -lldap -llber -lresolv -lnsl -lsocket

*** Warning: Linking the shared library mod_auth_ldap.la against the
non-libtool
*** objects mod_auth_ldap.o is not portable!

# make install
/usr/apache2/bin/apxs -i -a -c mod_auth_ldap.o -L/usr/local/lib -lldap
-llber -lresolv -lnsl -lsocket
/var/apache2/build/libtool --silent --mode=link /opt/SUNWspro/bin/cc -o
mod_auth_ldap.la -rpath /usr/apache2/libexec -module -avoid-version
mod_auth_ldap.o -L/usr/local/lib -lldap -llber -lresolv -lnsl -lsocket

*** Warning: Linking the shared library mod_auth_ldap.la against the
non-libtool
*** objects mod_auth_ldap.o is not portable!
/var/apache2/build/instdso.sh SH_LIBTOOL='/var/apache2/build/libtool'
mod_auth_ldap.la /usr/apache2/libexec
/var/apache2/build/libtool --mode=install cp mod_auth_ldap.la /usr/apache2/libexec/
cp .libs/mod_auth_ldap.so /usr/apache2/libexec/mod_auth_ldap.so
chmod +x /usr/apache2/libexec/mod_auth_ldap.so
cp .libs/mod_auth_ldap.lai /usr/apache2/libexec/mod_auth_ldap.la
cp .libs/mod_auth_ldap.a /usr/apache2/libexec/mod_auth_ldap.a
cp: cannot access .libs/mod_auth_ldap.a
apxs:Error: Command failed with rc=131072
.
*** Error code 1
make: Fatal error: Command failed for target `install'

No matter what compiler I use (SUN provided or GNU) I get the error
above. I dunno what mod_auth_ldap.a is .... and how come I get passed the
make command and there is no mod_auth_ldap.a file ... .

Does anybody have any idea ??

thanks

-- 
Dragos Stoichitescu
UNIX System Administrator
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers


This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:40:36 EDT