jyr/MNPP — Issue #22: PHP 5.2 doesn't work in Lion
Author: smoothify
Created: 2012-01-03 00:06:26+00:00
State: open

Hello

I'm using Lion and trying to use PHP 5.2 rather than 5.3 (which works)

Running the command ```sudo /Applications/MNPP/init/mnpp --php52 --start``` causes the following error:

dyld: Library not loaded: /opt/local/lib/libiconv.2.dylib
Referenced from: /Applications/MNPP/Library/php52/bin/php-cgi
Reason: Incompatible library version: php-cgi requires version 8.0.0 or later, but libiconv.2.dylib provides version 7.0.0
/Applications/MNPP/Library/php52/sbin/php-fpm: line 43: 28512 Trace/BPT trap: 5 $php_fpm_BIN --fpm $php_opts
failed

For some reason its looking for the lib in the non-existent /opt/local/lib/ folder, rather than the correct place /Applications/MNPP/Library/libiconv/lib/.

If I add a symlink to correct file, I get the following error

dyld: Library not loaded: /opt/local/lib/libintl.8.dylib
Referenced from: /Applications/MNPP/Library/lib/libidn.11.dylib
Reason: image not found

Adding another symlink fixes this, and allows PHP 5.2 to start correctly. Is there a change that could be made to the php-fpm startup, or are these paths compiled inside the binary?