how does libldap detection work in ./configure script?

Tomasz Chmielewski mangoo at wpkg.org
Wed Jan 25 08:16:43 GMT 2006


Gerald (Jerry) Carter schrieb:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Tomasz Chmielewski wrote:
> 
>>I'm trying to cross-compile Samba 3.0.21a for a target Linux/mipsel.
>>
>>Actually, it does compile after some minor chenges, and runs fine.
>>
>>
>>What I failed to compile is ldap support - if I add --with-ldap to the
>>./configure script, it fails:
>>
>>checking for LDAP support... yes
>>checking ldap.h usability... yes
>>checking ldap.h presence... yes
>>checking for ldap.h... yes
>>checking lber.h usability... yes
>>checking lber.h presence... yes
>>checking for lber.h... yes
>>checking for ber_scanf in -llber... yes
>>checking for ldap_init in -lldap... no
>>checking for ldap_set_rebind_proc... no
>>checking whether ldap_set_rebind_proc takes 3 arguments... 3
>>configure: error: libldap is needed for LDAP support
> 
> 
> Check config.log for the reason of the failure.  That the
> first thing to do.

I checked that many times, but I didn't know what I'm looking for.
But I guess that's it - no it's only to find out how to cope with that:

# mipsel-linux-uclibc-gcc -o conftest -Os -s -D_SAMBA_BUILD_ 
-I/home/data/wrt54/libiconv-1.9.1/include     -I/home/data/wrt54/db/ 
-I/home/data/wrt54/libtool-1.5.22/libltdl/ 
-I/home/data/wrt54/openldap-2.3.18/include -L/home/data/wrt54/db/.libs 
-L/home/data/wrt54/libtool-1.5.22/libltdl/.libs 
-L/home/data/wrt54/openldap-2.3.18/libraries/libldap/.libs 
-L/home/data/wrt54/libiconv-1.9.1/lib/.libs 
-L/home/data/wrt54/openldap-2.3.18/libraries/liblber/.libs 
-L/home/data/wrt54/openldap-2.3.18/libraries/libldap_r/.libs 
-Wl,-rpath,/usr/lib conftest.c -lldap -llber   -ldl
/home/data/wrt54/openldap-2.3.18/libraries/libldap/.libs/libldap.so: 
undefined reference to `lutil_memcmp'
collect2: ld returned 1 exit status


-- 
Tomasz Chmielewski
http://wpkg.org


More information about the samba-technical mailing list