Created
February 23, 2010 11:02
-
-
Save sibprogrammer/312070 to your computer and use it in GitHub Desktop.
Script for building HipHop for PHP at Ubuntu 9.10 32-bit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
sudo apt-get install cmake g++ libboost-dev flex bison re2c libmysqlclient-dev \ | |
libxml2-dev libmcrypt-dev libicu-dev openssl binutils-dev libcap-dev \ | |
libgd2-xpm-dev zlib1g-dev libtbb-dev libonig-dev libpcre3-dev git-core \ | |
autoconf libtool libcurl4-openssl-dev libboost-system-dev \ | |
libboost-program-options-dev libboost-filesystem-dev curl | |
# getting hiphop source code | |
mkdir hiphop | |
cd hiphop | |
git clone git://github.com/facebook/hiphop-php | |
cd hiphop-php | |
export CMAKE_PREFIX_PATH=`pwd`/../ | |
export HPHP_HOME=`pwd` | |
export HPHP_LIB=`pwd`/bin | |
git submodule init | |
git submodule update | |
cd .. | |
# building libevent | |
wget http://www.monkey.org/~provos/libevent-1.4.13-stable.tar.gz | |
tar -xzvf libevent-1.4.13-stable.tar.gz | |
cd libevent-1.4.13-stable | |
cp ../hiphop-php/src/third_party/libevent.fb-changes.diff . | |
patch < libevent.fb-changes.diff | |
./configure --prefix=$CMAKE_PREFIX_PATH | |
make | |
make install | |
cd .. | |
# building icu | |
wget http://download.icu-project.org/files/icu4c/4.2.1/icu4c-4_2_1-src.tgz | |
tar -xvzf icu4c-4_2_1-src.tgz | |
cd icu/source | |
./configure --prefix=$CMAKE_PREFIX_PATH | |
make | |
make install | |
cd ../../ | |
# building libcurl | |
wget http://curl.haxx.se/download/curl-7.20.0.tar.gz | |
tar -xvzf curl-7.20.0.tar.gz | |
cd curl-7.20.0 | |
cp ../hiphop-php/src/third_party/libcurl.fb-changes.diff . | |
patch -p0 < libcurl.fb-changes.diff | |
./configure --prefix=$CMAKE_PREFIX_PATH | |
make | |
make install | |
cd .. | |
# patching hiphop for 32-bit | |
cd hiphop-php | |
curl sparcs.kaist.ac.kr/~tinuviel/hiphop/src-util-hash-long-long.diff | patch -p1 | |
curl sparcs.kaist.ac.kr/~tinuviel/hiphop/src-cpp-base-ssize_t.diff | patch -p1 | |
curl sparcs.kaist.ac.kr/~tinuviel/hiphop/src-lib-format-string.diff | patch -p1 | |
# building hiphop | |
cmake . | |
make |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment