Posts Tagged "mamp"

Compile PHP Extensions on Mac Snow Leopard OS X

If you have to custom compile PHP Extensions on Mac with Snow Leopard OS X while using MAMP , you will need to execute following commands. These are necessary to compile modules with both 32bit and 64bit support.

/Applications/MAMP/bin/php5.3/bin/phpize
MACOSX_DEPLOYMENT_TARGET=10.6
CFLAGS="-arch i386 -arch x86_64 -g -Os -pipe -no-cpp-precomp"
CCFLAGS="-arch i386 -arch x86_64 -g -Os -pipe"
CXXFLAGS="-arch i386 -arch x86_64 -g -Os -pipe"
LDFLAGS="-arch i386 -arch x86_64 -bind_at_load"
export CFLAGS CXXFLAGS LDFLAGS CCFLAGS MACOSX_DEPLOYMENT_TARGET