--On Friday, March 20, 2009 2:15 AM +0100 Michael Ströder michael@stroeder.com wrote:
Quanah Gibson-Mount wrote:
--On Friday, March 20, 2009 2:01 AM +0100 Michael Ströder michael@stroeder.com wrote:
- It's my strong opinion that if someone unpacks a release tar.gz and
builds it running "make test" should not conflict with an already installed version of /usr/lib/libl{dap,ber}*. It's quite normal that you build and test before installing the next release. Isn't it? Having a separate build system without any pre-installed libldap is nearly impossible today. On openSUSE even the software installation tool zypper has a dependency on libldap.
I regularly build OpenLDAP on 16 different boxes, covering 11 different OSes, 2 of which are OSX (10.4 and 10.5). I have never encountered this issue, even though all of those 16 boxes have the ldap libraries installed in /usr/lib. My files end up being linked correctly.
So then please tell me what I'm doing wrong.
Please note that
- the build itself works correctly. Only running "make test" without
prior "make install" is the problem. 2. I'm installing under a separate prefix not /usr/lib.
I don't know, but here's my example configure:
LDFLAGS="-L/usr/local/lib -R/usr/local/lib" LD_LIBRARY_PATH=/usr/local/lib CPPFLAGS="-I/usr/local/include" CC=gcc CXX=g++ CFLAGS='-g -O2 -DSLAP_LIGHTWEIGHT_DISPATCHER' CXXFLAGS='-g -O2' sh ../configure --datadir='${prefix}/lib' --libexecdir='${prefix}/lib' --sharedstatedir='${prefix}/lib' --prefix=/usr/local --disable-ipv6 --with-cyrus-sasl --with-tls --enable-dynamic --enable-slapd --enable-modules --enable-spasswd --enable-rewrite --enable-rlookups --enable-wrappers --enable-backends=mod --disable-shell --disable-sql --enable-overlays=mod --enable-debug --enable-slapi=yes --disable-ndb
and here's my resulting slapd:
[root@freelancer .libs]# ldd slapd libldap_r-2.4.so.2 => not found liblber-2.4.so.2 => not found libuuid.so.1 => /lib64/libuuid.so.1 (0x000000395ec00000) libdb-4.7.so => /usr/local/lib/libdb-4.7.so (0x00002b3129678000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00002b31299c1000) libsasl2.so.2 => /usr/local/lib/libsasl2.so.2 (0x00002b3129bdb000) libgssapi.so.2 => /usr/local/lib/libgssapi.so.2 (0x00002b3129df3000) libheimntlm.so.0 => /usr/local/lib/libheimntlm.so.0 (0x00002b312a022000) libkrb5.so.25 => /usr/local/lib/libkrb5.so.25 (0x00002b312a227000) libhx509.so.4 => /usr/local/lib/libhx509.so.4 (0x00002b312a4f4000) libwind.so.0 => /usr/local/lib/libwind.so.0 (0x00002b312a738000) libasn1.so.8 => /usr/local/lib/libasn1.so.8 (0x00002b312a95f000) libcom_err.so.1 => /usr/local/lib/libcom_err.so.1 (0x00002b312abe4000) libroken.so.18 => /usr/local/lib/libroken.so.18 (0x00002b312ade7000) libcrypt.so.1 => /lib64/libcrypt.so.1 (0x0000003960400000) libssl.so.0.9.8 => /usr/local/lib/libssl.so.0.9.8 (0x00002b312affb000) libcrypto.so.0.9.8 => /usr/local/lib/libcrypto.so.0.9.8 (0x00002b312b247000) libresolv.so.2 => /lib64/libresolv.so.2 (0x0000003961c00000) libltdl.so.7 => /usr/local/lib/libltdl.so.7 (0x00002b312b5c4000) libdl.so.2 => /lib64/libdl.so.2 (0x000000395e400000) libwrap.so.0 => /usr/lib64/libwrap.so.0 (0x00002b312b7cc000) libc.so.6 => /lib64/libc.so.6 (0x000000395e000000) /lib64/ld-linux-x86-64.so.2 (0x000000395dc00000) libnsl.so.1 => /lib64/libnsl.so.1 (0x0000003961400000)
And here is my resulting lt-slapd: [root@freelancer .libs]# ldd lt-slapd libldap_r-2.4.so.2 => /usr/local/build/openldap-2.4.16/qbuild/libraries/libldap_r/.libs/libldap_r-2.4.so.2 (0x00002b99e1623000) liblber-2.4.so.2 => /usr/local/build/openldap-2.4.16/qbuild/libraries/liblber/.libs/liblber-2.4.so.2 (0x00002b99e186e000) libuuid.so.1 => /lib64/libuuid.so.1 (0x000000395ec00000) libdb-4.7.so => /usr/local/lib/libdb-4.7.so (0x00002b99e1a89000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00002b99e1dd2000) libsasl2.so.2 => /usr/local/lib/libsasl2.so.2 (0x00002b99e1fec000) libgssapi.so.2 => /usr/local/lib/libgssapi.so.2 (0x00002b99e2204000) libheimntlm.so.0 => /usr/local/lib/libheimntlm.so.0 (0x00002b99e2433000) libkrb5.so.25 => /usr/local/lib/libkrb5.so.25 (0x00002b99e2638000) libhx509.so.4 => /usr/local/lib/libhx509.so.4 (0x00002b99e2905000) libwind.so.0 => /usr/local/lib/libwind.so.0 (0x00002b99e2b49000) libasn1.so.8 => /usr/local/lib/libasn1.so.8 (0x00002b99e2d70000) libcom_err.so.1 => /usr/local/lib/libcom_err.so.1 (0x00002b99e2ff5000) libroken.so.18 => /usr/local/lib/libroken.so.18 (0x00002b99e31f8000) libcrypt.so.1 => /lib64/libcrypt.so.1 (0x0000003960400000) libssl.so.0.9.8 => /usr/local/lib/libssl.so.0.9.8 (0x00002b99e340c000) libcrypto.so.0.9.8 => /usr/local/lib/libcrypto.so.0.9.8 (0x00002b99e3658000) libresolv.so.2 => /lib64/libresolv.so.2 (0x0000003961c00000) libltdl.so.7 => /usr/local/lib/libltdl.so.7 (0x00002b99e39d5000) libdl.so.2 => /lib64/libdl.so.2 (0x000000395e400000) libwrap.so.0 => /usr/lib64/libwrap.so.0 (0x00002b99e3bdd000) libc.so.6 => /lib64/libc.so.6 (0x000000395e000000) /lib64/ld-linux-x86-64.so.2 (0x000000395dc00000) libnsl.so.1 => /lib64/libnsl.so.1 (0x0000003961400000)
and I have no installed openldap in /usr/local/*
The /usr/lib dir has pre-existing libldap:
[root@freelancer lib]# ls -l libldap* lrwxrwxrwx 1 root root 21 Jan 14 09:48 libldap-2.3.so.0 -> libldap-2.3.so.0.2.15 -rwxr-xr-x 1 root root 238544 Jul 9 2008 libldap-2.3.so.0.2.15 lrwxrwxrwx 1 root root 23 Jan 14 09:48 libldap_r-2.3.so.0 -> libldap_r-2.3.so.0.2.15 -rwxr-xr-x 1 root root 255636 Jul 9 2008 libldap_r-2.3.so.0.2.15
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration