Setup MAMP 3.0.7 and PHP 5.6.1 with Laravel
Solving the MAMP php 5.6.1 php.ini configuration error.
I recently updated my MacBook Pro to OSX 10.10 Yosemite and unlike my work computer I had some issues. I decided to also upgrade MAMP while I was at it to version 3.0.7 and this fixed the issue I was having but also caused some other issues with Command line PHP.
Once I confirmed that the start error was corrected I confirmed that I was running MAMP’s version of PHP in the command line.
Everything was good, When I ran artisan I got the “Mcrypt PHP extension required.” Error.
This was bothering me since the extension in
/Applications/MAMP/bin/php/php5.6.1/conf/php.ini was included.
Running php -m didn’t list Mcrypt however the Redline and PCNTL extensions were showing up.
I eventually noticed that the php.ini for version 5.6.1 was actually looking in the wrong location for extensions. The reason Redline and PCNTL showed up at all was because I gave them a hard path.
Somewhere around line 422 of the php.ini you should see “extension_dir” and change no-debug-non-zts-20121212 to no-debug-non-zts-20131226
Close and reload terminal, run artisan again and hopefully the error is gone.
For easy access here are some other helpful notes on getting things set up for MAMP, Laravel, Composer, and the command line.
- OSX Command line MAMP for use with Laravel and Composer.
- Laravel Tinker ( Boris ) + MAMP + OS X Yosemite