Hi everyone!
        I'm working with an Apache2 server and PHP4 inside a Red Hat 9. I have compiled and added my own PHP libraries as shared objects without any problems, but now I need to add the Ldap library.
I 've tried to compile it in two ways, first as a static module inside the PHP binary file, and the second one as a shared object, but in both cases I've got some problems.

If I try to use it as part of the PHP binary file, the ldap library runs ok, but my PHP libraries do not work!!! It's strange because when I load the libraries ( dl(...) ) there are no errors, but I can not use them... Do you have any idea about what can be the problem? I'm sure that my php.ini is ok, I mean, the extension-dir points to the correct directory....( phpinfo() )

My second choice was to compile it as a shared object. I did it with the phpize tool (./configure, make and make install), and with the php configure script, but in both cases I obtained the same result: a not valid "ldap.so".
My command was this:
./configure --with-apxs2=/home/ivanf/local/apache2/bin/apxs --with-config-file-path=/home/ivanf/local/php         --prefix=/home/ivanf/local/php --with-ldap=shared

and the error shown in my browser:

Warning: dl(): Invalid library (maybe not a PHP library) 'ldap.so' in         home/ivanf/local/apache2/htdocs/php/AD.php on line 8

My AD.php is as simple as the following...

    <body>

<?php
        dl("ldap.so");
        echo "<H1> Pagina de pruebas...</H1>";
        $ds=ldap_connect("ldap://192.168.7.105");
?>

</body>


Please, could  anyone help me????

My bests regards in advance!!

Thank you!

Ivan

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to