[Dovecot] autoconf check for ldap not linking with -lber

Jorgen Lundman lundman at lundman.net
Tue Oct 17 07:41:52 UTC 2006


If anyone cares, I needed:

from: LIBS="-lldap $LIBS"

to:   LIBS="-lldap -llber -lresolv $LIBS"

to compile, that's without SSL support in OpenLDAP.

Lund


Jorgen Lundman wrote:
> 
> Maybe not a big deal, but generally you (used to?) link against both:
> 
> configure:31276: checking for ldap_init in -lldap
> configure:31311: gcc -o conftest -std=gnu99 -I/usr/local/include -Wall 
> -W -Wmiss
> ing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts 
> -Wformat
> =2 -Wbad-function-cast -I/usr/sfw/include    -L/usr/local/lib conftest.c 
> -lldap
>   -lsocket -lnsl -lrt -lsendfile >&5
> Undefined                       first referenced
>  symbol                             in file
> ber_sockbuf_io_readahead            /usr/local/lib/libldap.so
> ber_sockbuf_alloc                   /usr/local/lib/libldap.so
> ber_sockbuf_io_fd                   /usr/local/lib/libldap.so
> 
> But could be special situation as my LDAP version is fixed, due to 
> production environment using it. It also failed when OpenLDAP was linked 
> against OpenSSL, since it does not try with the SSL libraries.
> 
> Lund
> 

-- 
Jorgen Lundman       | <lundman at lundman.net>
Unix Administrator   | +81 (0)3 -5456-2687 ext 1017 (work)
Shibuya-ku, Tokyo    | +81 (0)90-5578-8500          (cell)
Japan                | +81 (0)3 -3375-1767          (home)


More information about the dovecot mailing list