php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #77446 Trying to compile PHP with LDAP without using shared libs
Submitted: 2019-01-11 13:44 UTC Modified: 2021-08-19 15:40 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: cyril dot makloufi at gmail dot com Assigned: cmb (profile)
Status: Not a bug Package: LDAP related
PHP Version: 7.3.1 OS: MacOS
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
45 + 27 = ?
Subscribe to this entry?

 
 [2019-01-11 13:44 UTC] cyril dot makloufi at gmail dot com
Description:
------------
Hello,

I'm trying to build PHP with LDAP as a static library.
But the make command always ask for ldap.dylib.
I removed LIBS="$LIBS $LDAP_SHARED_LIBADD" in php-sources/ext/ldap/config.m4 (line 195)
and it looks to be working.
I may have missed something but I didn't find any option to do this correctly.
LDAP is the only extension that makes this problem.

Test script:
---------------
LDAP Building :

./configure --prefix="$DEPS_DIR"
        --disable-backends
        --enable-ldap
        --without-fetch
        --without-cyrus-sasl
        --enable-shared=no 
        --enable-static=yes
make
make install

PHP Building :

./configure --prefix="$INSTALL_DIR"
        --disable-cli
        --enable-cgi
        --enable-shared=no
        --enable-static=yes
        --with-ldap=$DEPS_DIR"
make
make install

Expected result:
----------------
PHP build correctly

Actual result:
--------------
make command failed and ask for libldap.dylib and liblber.dylib

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-08-19 15:40 UTC] cmb@php.net
-Status: Open +Status: Not a bug -Package: Compile Failure +Package: LDAP related -Assigned To: +Assigned To: cmb
 [2021-08-19 15:40 UTC] cmb@php.net
If you want to build fully static, you need a static build of
libldap and liblber.  Obviously, that's not the case in your
setup.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 07:01:31 2024 UTC