Installation with homebrew php5.3 + php-fpm under osx snow leopard

Forum recently to give a custom php, and I was supposed python control, so the machine would be no php runtime environment, began to toss, originally configured on centos nginx + php-fpm quite simple, direct way yum install on it , which under the mac to a little trouble, although there are php on macports, but the method hack If you install php-fpm if necessary, in order not to trouble climbing the text using homebrew see ways to use third-party formula can be installed, The following start. 

 

If you have not used homebrew, so the venue Homebrew look at the site, installation is simple, because it is a pile of ruby script, so you type directly in the terminal:

ruby -"$(curl -fsSLk https://gist.github.com/raw/323731/install_homebrew.rb)" 

Since you are playing this, I assume you have installed xcode, 3 or 4 can be. The next step is to download the formula php, 

  1. -The curl https://github.com/ampt/homebrew/raw/php/Library/Formula/php.rb
  2. mv php.rb `brew --prefix`/Library/Formula

 

If you want to see php installation options, you can use

  1. brew options php

 

Ah, can now be installed, I just need php and php-mysql, so:

  1. brew install php --with-mysql --with-fpm

 So basically it. 

Reproduced in: https: //www.cnblogs.com/Stephen/archive/2011/04/09/Mac_Snow_Leopard_Homebrew_Install_PHP.html

Guess you like

Origin blog.csdn.net/weixin_33981932/article/details/93223635