> Hello,
>
> I am trying to compile OpenLDAP 2.3.39 on my sun box. Below details on
> my compilation environment :
>
>
[...]
> PATH=/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin
> LD_LIBRARY_PATH=/usr/local/lib
> PKG=openldap-2.3.39
> PREFIX=/usr/local
>
> export PATH PKG PREFIX LD_LIBRARY_PATH
>
> /usr/bin/env \
> CC="/usr/local/bin/cc" \
> CXX="/usr/local/bin/c++" \
> CFLAGS="-O2 -pipe" \
> LDFLAGS="-L/usr/local/ssl/lib/libssl.a
> -L/usr/local/ssl/lib/libcrypto.a -L/usr/local/ssl/lib -L/usr/local/lib
> -R/usr/local/lib" \
>
Under LDFLAGS, you include several library directories for use at
compile time (-L) but only /usr/local/lib for runtime (-R).
While you have no problems compiling, the ldd output shows that the
binaries can't find the appropriate libraries when run (i.e. in runtime).
Add the ssl library path (/usr/local/ssl/lib) as a runtime library path
as well and you should be OK.
By the way, if I remember correctly, -L is for directories only, in
which case it makes no sense to add libssl.a or libcrypto.a with -L. If
the compile process can't identify by itself which libraries it needs,
which it should, these should be specified with -l (lowercase L).
okay if we forget 5 minutes ssl part of this compilation, let we simplify the configure script with this
PATH=/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin
LD_LIBRARY_PATH=/usr/local/lib
PKG=openldap-2.3.39
PREFIX=/usr/local
export PATH PKG PREFIX LD_LIBRARY_PATH
/usr/bin/env \
CFLAGS="-O2 -pipe" \
CPPFLAGS="-I/usr/local/include" \
LDFLAGS=" -rpath=/usr/lib:/usr/local/lib -L/usr/local/lib" \
SHELL=/bin/sh \
CONFIG_SHELL=/bin/sh \
./configure \
--prefix=/usr/local \
--sysconfdir=/etc \
--enable-crypt \
--enable-dynamic \
--with-threads=posix \
--without-cyrus-sasl \
--disable-debug \
--disable-slapd \
--disable-slurpd \
--disable-monitor \
--disable-bdb \
--disable-hdb \
--disable-relay \
--disable-glue \
--disable-syncprov
.. and this is what I get
# ldd /usr/local/bin/ldapsearch
ldd: /usr/local/bin/ldapsearch: file has insecure interpreterELF
# /usr/local/bin/ldapsearch
Killed
# ldd /usr/local/lib/libldap.so
liblber-2.3.so.0 => /usr/local/lib/liblber-2.3.so.0
libresolv.so.2 => /lib/libresolv.so.2
libgen.so.1 => /lib/libgen.so.1
libnsl.so.1 => /lib/libnsl.so.1
libsocket.so.1 => /lib/libsocket.so.1
libc.so.1 => /lib/libc.so.1
libgcc_s.so.1 => /usr/local/lib/libgcc_s.so.1
libdl.so.1 => /lib/libdl.so.1
libmp.so.2 => /lib/libmp.so.2
/usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1
I also tried to modify line 'LD="/usr/ccs/bin/ld"' with 'LD="/usr/ccs/bin/ld -R/usr/local/lib"' in /usr/local/bin/libtool just to test .. always the same result. Finally I tested my compilation environment again by recompiling squid and bind that successfully compile on the same desktop and I do not get any problem.
So there seems to be something specific with OpenLDAP that give bad result. I already tested more than 50 compilation tentatives but I even do not get any idea about the problem.
Please can somebody help me because I really need to compile this package on my system for production matters and I may not get any package as is on the net.
Concerning log files, I moved them so the new place are
http://jlang.dyndns.org/openldap-2.3.39-ccs_ld.loghttp://jlang.dyndns.org/openldap-2.3.39-local_ld.loghttp://jlang.dyndns.org/openldap-2.3.39.log
Help is really appreciated.
For further details, your favourite search engine should be more than
helpful as long as you feed it the right keywords.
--
Bjørn
-----------------------------------------------------------------
ATTENTION:
The information in this electronic mail message is private and
confidential, and only intended for the addressee. Should you
receive this message by mistake, you are hereby notified that
any disclosure, reproduction, distribution or use of this
message is strictly prohibited. Please inform the sender by
reply transmission and delete the message without copying or
opening it.
Messages and attachments are scanned for all viruses known.
If this message contains password-protected attachments, the
files have NOT been scanned for viruses by the ING mail domain.
Always scan attachments before opening them.
-----------------------------------------------------------------