Ticket #20492 (assigned defect)
php4, php5, php5-devel: php links with libldap if present
| Reported by: | ryandesign@… | Owned by: | ryandesign@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 1.7.1 |
| Keywords: | Cc: | ingo@… | |
| Port: | php4, php5, php5-devel |
Description
php links with libldap if the openldap port is installed, though no dependency is declared. This causes an error if openldap is subsequently uninstalled:
$ php dyld: Library not loaded: /mp/lib/libldap-2.3.0.dylib Referenced from: /mp/bin/php Reason: image not found Trace/BPT trap
php should be changed to not link with unrequested libraries. See if --disable-all fixes this. Check whether php4 is affected as well.
Change History
comment:3 in reply to: ↑ description Changed 4 years ago by ryandesign@…
- Status changed from new to assigned
Replying to ryandesign@…:
php should be changed to not link with unrequested libraries. See if --disable-all fixes this.
php5 @5.3.0_2 uses --disable-all but it has not fixed this problem.
comment:4 Changed 3 years ago by ryandesign@…
We are actually requesting ldap, but wanting it to come from /usr:
platform macosx {
configure.args-append \
--with-ldap=/usr
}
I don't know why we do that. Presumably the fix is to not request ldap at all in the php5 port, and instead create a php5-ldap port that depends on the openldap port, thereby furthering #19091.
Note: See
TracTickets for help on using
tickets.


We cannot specify --with-ldap and leave it blank either: in the case the user does not specify a path, configure will look for ldap.h and include in /usr and /usr/local. The ./configure --help output did not reflect this properly. This is changed in CVS now.