wget -c http://cn2.php.net/distributions/php-5.6.6.tar.bz2
yum install gmp-devel.x86_64 -y
tar xvf php-5.6.6.tar.bz2 && cd php-5.6.6
./configure --prefix=/usr/local/php --enable-fpm --with-fpm-user=www --with-fpm-group=www --with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d --with-openssl=/usr/local/openssl --with-zlib=/usr/local/zlib --with-curl --enable-ftp --with-gd --with-jpeg-dir --with-png-dir --with-freetype-dir --enable-gd-native-ttf --enable-mbstring --enable-zip --with-mysql=/usr/local/mysql/ --with-mysqli --with-mcrypt=/usr/local/libmcrypt --without-pear --with-libxml-dir=/usr --enable-xml --with-mhash --disable-rpath --enable-bcmath --with-pdo-mysql=mysqlnd --with-iconv-dir=/usr/local/ --enable-magic-quotes --enable-safe-mode --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-ftp --enable-pcntl --enable-sockets --with-xmlrpc --enable-soap --with-gettext --disable-fileinfo --with-gmp;
cpunu=6
make -j $cpunu ZEND_EXTRA_LIBS='-liconv' && make install
/etc/init.d/php-fpm restart
restart the php server
echo gmp_strval("0xFFFFF");
ps: 今天不小心第一行php代码没有; 结束,于是到处是500 丢人呀
wdcp安装php gmp扩展
http://bbs.qcloud.com/thread-4800-1-1.html
#这些都用不上
tar xvf gmp-5.1.2.tar.bz2
cd gmp-5.1.2 && ./configure
make -j4 && make install