Skip to content

Instantly share code, notes, and snippets.

Created September 8, 2016 20:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/9e2b10ea08ba146f6aee2a2c72f65fe9 to your computer and use it in GitHub Desktop.
Save anonymous/9e2b10ea08ba146f6aee2a2c72f65fe9 to your computer and use it in GitHub Desktop.
sudo apt-get build-dep php5
sudo apt-get install -y php5 php5-dev libapache2-mod-php5 php-pear autoconf automake curl libcurl3-openssl-dev build-essential libxslt1-dev re2c libxml2 libxml2-dev php5-cli bison libbz2-dev libreadline-dev
sudo apt-get install -y libfreetype6 libfreetype6-dev libpng12-0 libpng12-dev libjpeg-dev libjpeg8-dev libjpeg8 libgd-dev libgd3 libxpm4 libltdl7 libltdl-dev
sudo apt-get install -y libssl-dev openssl
sudo apt-get install -y gettext libgettextpo-dev libgettextpo0
sudo apt-get install -y libicu-dev
sudo apt-get install -y libmhash-dev libmhash2
sudo apt-get install -y libmcrypt-dev libmcrypt4
sudo apt-get install -y apache2-dev
curl -L -O https://github.com/phpbrew/phpbrew/raw/master/phpbrew
chmod +x phpbrew
sudo mv phpbrew /usr/local/bin/phpbrew
phpbrew init
source /home/vagrant/.phpbrew/bashrc
phpbrew lookup-prefix ubuntu
phpbrew update --old
sudo chmod -R oga+rw /etc/apache2
sudo chmod -R oga+rw /usr/lib/apache2/modules
sudo ln -s /usr/include/freetype2 /usr/include/freetype2/freetype
phpbrew install php-5.3.29 +default +mysql +pdo +intl +gettext +apxs2
phpbrew switch 5.3.29
phpbrew -d ext install gd -- --with-libdir=lib/x86_64-linux-gnu --with-gd=shared --enable-gd-native-ttf --with-jpeg-dir=/usr --with-png-dir=/usr --with-freetype-dir=/usr/include/freetype2/ft2build.h --with-xpm-dir=/usr
phpbrew off
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment