For those of you using Laravel and trying to run
composer install and getting an mcrypt error (Laravel requires the Mcrypt PHP extension.), this will fix it for you.
I use homebrew and have php 5.6 installed.
$ brew install mcrypt
for the mcrypt php extension:
$ brew install php56-mcrypt
It’s really that easy.