Search code examples
phpapacheapc

MAMP upgrading APC


MAMP 2 comes shipped with APC 3.1.9. I am trying to run Symfony however it requires APC 3.1.13.

I was able to install APC 3.1.13 using pecl install APC.

After installation I was able to grab the apc.so file: /opt/local/lib/php/extensions/no-debug-non-zts-20090626/apc.so and replace the /Applications/MAMP/bin/php/php5.4.4/lib/php/extensions/no-debug-non-zts-2010052‌​5/apc.so file`.

I think im on the right track, but when rebooting apache it no longer says apc is installed when calling phpinfo()

I was able to switch to PHP5.3 and replace the apc.so file in the corresponding extensions folder. This showed that php was using apc 3.1.13.

Is there a reason this would not work for php5.4?


Solution

  • It's probably not working because a Mac comes shipped with PHP 5.3. As you installed APC you did so for PHP 5.3. So moving the .so file to a PHP 5.4 environment doesn't cut it.

    MAMP provides components and libraries on there site. Or here's a direct link: http://sourceforge.net/projects/mamp/files/mamp/2.1.2/MAMP_components_2.1.2.zip/download

    APC is included in there.

    Hope this helps!