0

Is there a good way to install a PHP development stack, including PHP 5.4, that isn't XAMPP or MAMP, and that doesn't require compiling PHP?

I am struggling with the numerous installations required to have a standalone Apache server on my Mac, and it just doesn't make sense to me that there isn't any installer that does this properly.

hakre
  • 193,403
  • 52
  • 435
  • 836
Roie Cohen
  • 74
  • 1
  • 7
  • 1
    What's wrong with MAMP or XAMPP, especially as its just for development. I use MAMP with no issues. Can set it up exactly like my production web server too. OSX comes with a built in web server (apache I believe) which you can turn on by going to the "sharing" page in "system preferences". – Thomas Clayson Jul 02 '12 at 12:29
  • On further probing aparently php comest pre-installed in Mac OSX too. Should be easy: here is something that might help: http://stackoverflow.com/questions/6790568/how-do-you-get-php-working-on-mac-os-x-lion-10-7 – Thomas Clayson Jul 02 '12 at 12:31
  • MAMP and XAMPP are very limiting. There's only so much you can configure them to do, and specifically, if you need PHP features that are not including in XAMPP/MAMP distribution for Max OS 10.7... I don't think it's reasonable to rely only on two solutions. Also, I don't understand why Apple doesn't supply a proper development environment - you have an Apache server, but not PHP?... How odd is that? – Roie Cohen Jul 02 '12 at 16:22
  • The pre-installed apache on mac is even less compelling. Even on Lion, the PHP version isn't the latest, and there are known bugs related to it. And I'm still baffled vy the scarcity of solutions out there... – Roie Cohen Jul 14 '12 at 10:28

1 Answers1

1

We had the same problem (especially with missing PECL extensions), and came up with two different solutions, in this order:

  1. First we've used Zend Server Community Edition, which has the great advantage of shipping with many extensions, and is free. You can download MySQL Community Server separately, and you've got a working MAMP installation.
  2. Because this was still not perfect (hard to get PEAR working, for example), we now use what proved to be the best solution for us, running a full LAMP stack on a CentOS virtual machine, with the free VirtualBox, and share the web folder between the host computer and the guest.

If you want to be up & ready in minutes, choose the first solution.

If you want to take some time to set up a virtual machine, you will enjoy the best of both worlds: a real LAMP server always available in your machine, and your usual tools on your favourite OS for your daily work. We're now using this solution on both Windows & MacOS, and really enjoy it.

BenMorel
  • 34,448
  • 50
  • 182
  • 322