0

I'm trying to install Laravel4 on my 10.6 Mac / PHP 5.4.14. And I seem to be going down a rabbit hole.

After "composer install"ing Laravel4 .. command line showed that I needed the Mcrypt PHP extension. So I tried to install that and I was told I had to have Mhash installed. So I installed Mhash .. then went back and installed Mcrypt

extension = mcrypt.so
Libraries have been installed in:
/Users/****/downloads/php-5.4.14/ext/mcrypt/modules

Then I went back to installing Laravel 4 and now I'm showing this

PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/local/lib/php/extensions/no-debug-non-zts-20100525/intl.so' - dlopen(/opt/local/lib/php/extensions/no-debug-non-zts-20100525/intl.so, 9): image not found in Unknown on line 0
Loading composer repositories with package information
Installing dependencies from lock file
Nothing to install or update
Generating autoload files
PHP Warning:  PHP Startup: Unable to load dynamic library '/opt/local/lib/php/extensions/no-debug-non-zts-20100525/intl.so' - dlopen(/opt/local/lib/php/extensions/no-debug-non-zts-20100525/intl.so, 9): image not found in Unknown on line 0
Laravel requires the Mcrypt PHP extension.

.. and I thought I had already taken care of that intl.so issue .. but it seems I installed an old version?

Module compiled with module API=20090626
PHP    compiled with module API=20100525
These options need to match
in Unknown on line 0
Laravel requires the Mcrypt PHP extension.

So can someone maybe give me a bit of perspective on this and point me in the right direction? I'm a little fuzzy with compiling PHP.

1
  • 1
    I used this to install mcrypt, you may of already seen it, but if not... coolestguyplanettech.com/… Commented May 16, 2013 at 18:59

2 Answers 2

2

Your command line might be using a different version of PHP. You'll have to update your path variable in your .bash_profile file to point to the correct version of PHP.

Sign up to request clarification or add additional context in comments.

4 Comments

What should that look like?
Your .bash_profile should be located in your User Home directory. This worked for me "export PATH=/usr/local/php5/bin:$PATH" -- no quotes of course -- but this could vary based on where your new version of PHP is installed. This is a great resource for installing PHP link
Thank you for the link. I think I would like to try to reinstall 5.4.14 from scratch. I seem to keep having issues with the intl.so extension. Do you know if I have to do anything to "uninstall" a version? I can't find anything from googling. I somehow wonder if installing over installs can confuse things. I would just like to clean things out, start from scratch and follow the site you suggested.
I believe you just need to delete the directory containing the PHP version. I've used the link and have had no problems with installing with other PHP versions on my system. Look into Homebrew and installing PHP through there as well. Might be easier for you to remove things with Homebrew
1

How are you installing PHP?

I'm thinking the 5.4 version you installed is getting mixed up with the built-in 5.3 version that comes with OS X.

1 Comment

I guess that could be a problem. If there is something special you do to "uninstall" a version I don't think I did it. I just followed instructions on downloading and installing PHP5.4. So .. for example, right now my /opt/local/lib/php/ext folder has 3 folders in it. "no-debug-non-zts-20090626", a double - "no-debug-non-zts-20090626 2", and ""no-debug-non-zts-20100525". But the 2010 folder (which I am assuming belongs to php5.4) didn't have intl.so, as I recall. So I followed online instructions to get it (prolly where the doubled 2009 folder comes from). So what should I do?

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.