I just installed Mountain Lion, and of course I've had to set up Xcode Command Line Tools, reinstall Git, and do other things to get up and running again for programming. Naturally, PHP was pushed back to 5.3 from 5.4 that I previously had installed when my MacBook Pro was running Lion. I ran through the process downloading PHP 5.4, unzipping it (tar xf php5.4), configuring it (./configure with and without options), making it (make), running the make test (make test), and installing the make (sudo make install). When I ran configuration with options it did not allow me to make and when I ran without configuration options it failed to pass make test a few times (when this occurred I sent the information to Zend). When it did pass make test though, it said that it installed successfully, but when I would check the version (php -v) it still comes up with PHP 5.3. I've done this almost nine times with restarts and re-downloading the package every time; no sauce. Does anyone have any ideas what could possibly be going wrong? Any help on this issue would be greatly appreciated.
|
|
I strongly suggest you use the package installer or use a full stack of configuration options when compiling, including the --prefix option so you know where the binary gets installed to. I can only guess PHP 5.4 installed itself into Alternatively, you could just symlink the new php binary to /usr/bin/php, (delete or rename the default binary before that):
|
|||||
|
|
Have you tried installing it via Homebrew? Also just found a blog post (you have to scroll down a bit to the Homebrew section) which is saying that the problem with compiling PHP might be because ML doesn't come with X11, but there's a workaround. Actually, here's the relevant bit from the blog post:
|
|||
|
|
|
I've installed MAMP and everything works fine. |
|||||||||
|