mac OSX php upgrade for MAMP Print

  • 1

MAMP can run several versions of php but but default may not be runnig the version you want. More complicated than selecting the php version is installing a new one. Below is the script I used to install the latest build on my machine. ALso, the regular ./configure would not work so i added the prefix which makes the configure compile using the php version in mamp.

download file for installing here: http://www.libssh2.org/download/
get the new version and chagne the file name in the installer to match

also get the new version of this file ssh2-0.12.tgz here https://pecl.php.net/package/ssh2

in mamp go to file -> edit template -> php -> then your version -> add this text to the bottom of the file "extension=ssh2.so"


_________________________________________________________
the regular ./configure would not work so i added the prefix which makes the configure compile using the php version in mamp.

download file for installing here: http://www.libssh2.org/download/
get the new version and chagne the file name in the installer to match

also get the new version of this file ssh2-0.12.tgz here https://pecl.php.net/package/ssh2

in mamp go to file -> edit template -> php -> then your version -> add this text to the bottom of the file "extension=ssh2.so"



sudo bash
cd /usr/local/src
curl -OL http://ftpmirror.gnu.org/autoconf/autoconf-2.68.tar.gz
tar xzf autoconf-2.68.tar.gz
cd autoconf-2.68
./configure --prefix=/usr/local
make
make install

cd /usr/local/src
curl -OL http://ftpmirror.gnu.org/automake/automake-1.11.tar.gz
tar xzf automake-1.11.tar.gz
cd automake-1.11
./configure --prefix=/usr/local
make
make install

cd /usr/local/src
curl -OL http://ftpmirror.gnu.org/libtool/libtool-2.4.tar.gz
tar xzf libtool-2.4.tar.gz
cd libtool-2.4
./configure --prefix=/usr/local
make
make install

cd /usr/local/src
curl -OL http://download.icu-project.org/files/icu4c/4.8.1.1/icu4c-4_8_1_1-src.tgz
tar xzf icu4c-4_8_1_1-src.tgz
cd icu/source
./configure --prefix=/usr/local
make
make install

 

 


cd /Users/josh/Desktop/
tar -xf libssh2-1.6.0.tar.gz
cd libssh2-1.6.0
./configure --prefix=/Applications/MAMP/bin/php/php5.6.10/include/php/configure
make
sudo make install

 


cd /Users/josh/Desktop/
tar -xf ssh2-0.12.tgz
cd ssh2-0.12
/Applications/MAMP/bin/php/php5.6.10/bin/phpize
./configure --prefix=/Applications/MAMP/bin/php/php5.6.10/include/php/configure
make


Was this answer helpful?

« Back