PHP3 and Solaris 7 LDAP

From: Date: Tue, 16 Nov 1999 13:01:52 +0000
Subject: PHP3 and Solaris 7 LDAP
Groups: php.dev 
Request: Send a blank email to php-dev+get-12603@lists.php.net to get a copy of this message
I compile with the script below and it works fine. When I enable the "--with-ldap" option without path information, PHP3 should find and use the Solaris LDAP functions in /usr/include and /usr/lib, which it does. The compile fails, though, with the following completely strange error message for main.c, of all places: gcc -g -O2 -O2 -I. -I. -I/opt/include -I/opt/include -I/opt/ include -I/opt/include/mysql -I/usr/include -I/opt/include/ucd-snmp -I/usr/local /include -c main.c -o main.o main.c: In function `php3_printf': main.c:309: `__builtin_va_alist' undeclared (first use in this function) main.c:309: (Each undeclared identifier is reported only once main.c:309: for each function it appears in.) main.c: In function `php3_error': main.c:382: `__builtin_va_alist' undeclared (first use in this function) Somehow the Solaris 7 LDAP includes seem to mess up some internal PHP3 or gcc declarations? If I chose "--with-ldap=/opt/ldap", the binary fails in libldapssl30.so from netscape, due to the fact that the library is not thread safe. It does mix calls to _r and non-_r-functions, but links against libthread.so, which makes it useless in a Solaris environment. The resulting binary fails in libthread.so in libldapssl30.so in LDAP_Version in php3_phpinfo(). How do you compile PHP3 with LDAP support in Solaris 7? Kristian The build script, with LDAP disabled (works). Enable "--with-ldap" to use Solaris 7 LDAP and it fails during compile, enable "--with-ldap=/opt/ldap" to use Netscape LDAP SDK and it fails during runtime: kk@wwwx ~/Source/php3 $ cat do-conf cp $0 $0.kris # cvs update -d -P autoconf ./configure \ --with-config-file-path=/opt/NUphp-3.0.12/lib \ --with-dbase \ --with-db2=/opt \ --with-exec-dir=/opt/bin \ --with-ftp \ --with-gd=/opt \ --with-gdbm=/opt \ --with-imap=/opt \ --with-jpeg-dir=/opt \ --with-mcrypt=/opt \ --with-mhash=/opt \ --with-mysql=/opt \ --with-ndbm=/usr \ --with-pcre-regex \ --with-pdflib=/opt \ --with-posix \ --with-snmp=/opt \ --with-tiff-dir=/opt \ --with-ttf=/opt \ --with-xml=/opt \ --with-yp=/usr \ --with-zlib=/opt \ --disable-magic-quotes \ --disable-short-tags \ --enable-bcmath \ --enable-dba \ --enable-debugger \ --enable-display-source \ --enable-force-cgi-redirect \ --enable-memory-limit \ --enable-sysvsem \ --enable-sysvshm \ --enable-track-vars \ --enable-url-fopen-wrapper \ --prefix=/opt/NUphp-3.0.12 # --with-ldap=/opt/ldap \ # --enable-t1lib \ # --with-oracle=/opt/oracle/oracle/8.0.3 \ ## sed -e 's/#define.*NSLDAP.*/#define HAVE_NSLDAP 0/' < config.h > config.h.new # mv config.h config.h.old # mv config.h.new config.h make depend make -j 2 strip php mcs -d php -- Kristian Köhntopp, NetUSE Kommunikationstechnologie GmbH Siemenswall, D-24107 Kiel, Germany, +49 431 386 436 00 Using PHP3? See our web development library at http://phplib.netuse.de/ (We have moved! Update your bookmarks!)

« previous php.dev (#12603) next »