现在的位置: 首页FreeBSD>正文
FreeBSD 8.0编译安装PHP 5.3.3
2011年04月19日 FreeBSD 评论数 2 ⁄ 被围观 11,004 次+

发现PHP 5.3.3与PHP 5.2.x相比,编译参数起了比较大的变化。我使用以下编译参数编译成功。

  1. ./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多做以下工作。

  1. cd /usr/ports/devel/libevent
  2. make install clean
  3. tar zxvf libmcrypt-2.5.8.tar.gz
  4. cd libmcrypt-2.5.8/libltdl
  5. ./configure --enable-ltdl-install
  6. make
  7. make install
  8. cd ..
  9. ./configure --prefix=/usr
  10. make
  11. make install
本文地址:http://www.92csz.com/10/131.html
如非注明则为本站原创文章,欢迎转载。转载请注明转载自:moon's blog
 

目前有 2 条留言 其中:访客:1 条, 博主:1 条

  1. nosun : 2012年10月30日19:26:56  -49楼

    我一般都是直接ports安装,请问下,ports安装和编译安装有啥区别么?

    • clairelume : 2012年11月07日11:09:02

      都一样,只不过编译安装自己指定路径,所有编译生成的文件都在指定目录内方便管理,不过貌似ports也是可以指定安装的路径,看个人喜好了 😛