发现PHP 5.3.3与PHP 5.2.x相比,编译参数起了比较大的变化。我使用以下编译参数编译成功。
- ./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=mysqlnd --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir=/usr --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr/local --enable-xml --disable-rpath --enable-discard-path --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fpm --enable-force-cgi-redirect --enable-mbstring --with-mcrypt --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --disable-ipv6 --without-pear --with-fpm-user=www --with-fpm-group=www
编译PHP 5.3.3之前,需要比PHP 5.2.13多做以下工作。
- cd /usr/ports/devel/libevent
- make install clean
- tar zxvf libmcrypt-2.5.8.tar.gz
- cd libmcrypt-2.5.8/libltdl
- ./configure --enable-ltdl-install
- make
- make install
- cd ..
- ./configure --prefix=/usr
- make
- make install
如非注明则为本站原创文章,欢迎转载。转载请注明转载自:moon's blog
我一般都是直接ports安装,请问下,ports安装和编译安装有啥区别么?
都一样,只不过编译安装自己指定路径,所有编译生成的文件都在指定目录内方便管理,不过貌似ports也是可以指定安装的路径,看个人喜好了 😛