Edit report at http://bugs.php.net/bug.php?id=49876&edit=1

 ID:                 49876
 Comment by:         nessunoero at libero dot it
 Reported by:        graham dot simpson at hsbcib dot com
 Summary:            configure fails --with-ldap Cannot find ldap
                     libraries in /usr/lib
 Status:             Bogus
 Type:               Bug
 Package:            Compile Failure
 Operating System:   SuSE Linux 10 SP 2 x86_64
 PHP Version:        5.3.0
 Block user comment: N
 Private report:     N

 New Comment:

useful howto

http://wiki.lepr-e.com/wiki/index.php/Ubuntu_Smtp_Server


Previous Comments:
------------------------------------------------------------------------
[2009-10-19 13:42:21] graham dot simpson at hsbcib dot com

Okay, found all the software where only lib exists and created a
suitable link to lib from lib64. Specifiying the --with-libdir=lib64,
now means that it compiles with the --with-ldap. Thanks for the help.

------------------------------------------------------------------------
[2009-10-19 13:16:44] graham dot simpson at hsbcib dot com

Firstly, many thanks for picking this up.

-

The rest of my PHP configuration relies on libs in /usr/lib64 and that
works. I didn't use --with-libdir=lib64 because my LD_LIBRARY_PATH and
SHLIB_PATH include /usr/lib64 and are set to:



/opt/sybase/Connect64forODBC60/lib:/opt/sybase/httpd-2.2.13/lib:/opt/sybase/libxslt-1.1.26/lib:/opt/sybase/libxml2-2.7.5/lib:/opt/sybase/freetds-0.82/lib:/opt/sybase/openssl-0.9.8k/lib:/opt/sybase/DBA_SDK1500-16721/DataAccess/ODBC/lib:/opt/sybase/DBA_SDK1500-16721/OCS-15_0/lib:/opt/sybase/DBA_SDK1500-16721/OCS-15_0/lib3p:/usr/lib64:/lib64:/usr/X11R6/lib64:/opt/gnome/lib64:/usr/local/lib64:/usr/X11R6/lib/X11/locale/lib64:/usr/X11R6/lib64:/var/lib/stunnel/lib64:/u01/sq/ora_1/oracle/client/11.2.0/lib:/usr/lib64:/usr/lib:/home/db2inst/sqllib/lib64:/home/db2inst/sqllib/lib32



The problem with setting --with-libdir=lib64 is that not all software
that I'm linking against has libs in lib64, some are just in lib.

------------------------------------------------------------------------
[2009-10-19 11:14:00] [email protected]

Your configure line is missing this: --with-libdir=lib64

------------------------------------------------------------------------
[2009-10-14 15:05:45] graham dot simpson at hsbcib dot com

Sorry, meant to post my configure line also...

CFLAGS="-DSYB_LP64" ./configure  --prefix=${TDIR}/php-5.3.0 --with-ldap
--enable-libgcc --with-oci8 --with-pdo-oci
--with-sybase-ct=${SYBASE}/${SYBASE_OCS}
--with-pdo-dblib=${TDIR}/freetds-0.82 --with-curl --enable-pcntl
--with-gettext --with-mcrypt --enable-soap --with-pear --with-zlib
--disable-cgi --with-readline --with-bz2
--with-apxs2=${TDIR}/httpd-2.2.13/bin/apxs
--with-libxml-dir=${TDIR}/libxml2-2.7.5
--with-xsl=${TDIR}/libxslt-1.1.26 --with-openssl=${TDIR}/openssl-0.9.8k

------------------------------------------------------------------------
[2009-10-14 14:59:56] graham dot simpson at hsbcib dot com

Description:
------------
64bit SuSE 10.2 with openldap2-2.3, openldap2-devel-2.3 installed.

Configure --with-ldap fails with:

checking for LDAP support... yes

checking for LDAP Cyrus SASL support... no

configure: error: Cannot find ldap libraries in /usr/lib.

-

rpm -q -l openldap2-devel

/usr/include/lber.h

/usr/include/lber_types.h

/usr/include/ldap.h

/usr/include/ldap_cdefs.h

/usr/include/ldap_features.h

/usr/include/ldap_schema.h

/usr/include/ldap_utf8.h

/usr/include/slapi-plugin.h

/usr/lib64/liblber.a

/usr/lib64/liblber.so

/usr/lib64/libldap.a

/usr/lib64/libldap.so

/usr/lib64/libldap_r.a

/usr/lib64/libldap_r.so

-

Should be looking in /usr/lib64. Which is odd because my LD_LIBRARY_PATH
contains /usr/lib64.

-

Altering --with-ldap to --with-ldap=/usr or /usr/lib64, then complains
about not finding the ldap.h, viz:

checking for LDAP support... yes

checking for LDAP Cyrus SASL support... no

configure: error: Cannot find ldap.h

-

The problem seems to be the configure script find ldap.h in
/usr/include/ldap.h, so sets LDAP_LIBDIR=/usr/lib (line 52114), later it
looks for /usr/lib/liblber.a instead of /usr/lib64/liblber.a.

-

Maybe I've got that wrong. The weird thing is I know other directives in
my configure are picking up stuff from /usr/lib64.

-

Thanks for any help you can give.

GSi





------------------------------------------------------------------------



-- 
Edit this bug report at http://bugs.php.net/bug.php?id=49876&edit=1

Reply via email to