ubuntu12.04安装lnmp0.9安装总结

今天安装了ubuntu12.04,想在该系统下完成毕业设计。在网上找到了一个lnmp整合的安装包(www.lnmp.org).于是根据说明开始安装此软件。安装完毕后发现php并没有启动,提示没有找到/usr/local/php/bin/php-cgi: not found

在/usr/local/php/下发现只有etc目录,说明编译的时候出现了问题,于是重新单独编译了php

  
  
  
  
  1. jayao@jayao-Aspire-4935:~/下载/lnmp0.9-full/php-5.2.17$ sudo ./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --enable-discard-path --enable-magic-quotes --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fastcgi --enable-fpm --enable-force-cgi-redirect --enable-mbstring --with-mcrypt --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --with-mime-magic 

并没有问题,继续make,发现了问题

 

 

  
  
  
  
  1. sudo make ZEND_EXTRA_LIBS='-liconv' 
/home/jayao/下载/lnmp0.9-full/php-5.2.17/ext/openssl/xp_ssl.c:337: undefined reference to `SSLv2_client_method'
collect2: ld returned 1 exit status
make: *** [sapi/cgi/php-cgi] 错误 1
 

 

网上搜索了一下,大致需要打一个补丁(http://anonscm.debian.org/gitweb/?p=pkg-php/php.git;a=blob_plain;f=debian/patches/disable_SSLv2_for_openssl_1_0_0.patch;hb=3e2e5babbc9b4ae5b25688347bdf89ea862dbd92)。

原帖(http://bbs.vpser.net/viewthread.php?tid=6174&page=1&fromuid=3#pid16603)

将其放到php解压后的openssl目录中。

 

  
  
  
  
  1. sudo mv /home/jayao/下载/debian_patches_disable_SSLv2_for_openssl_1_0_0.patch /home/jayao/下载/lnmp0.9-full/php-5.2.17/ext/openssl/ 
  2. sudo patch -p3 <debian_patches_disable_SSLv2_for_openssl_1_0_0.patch  

重新编译,问题解决

 

你可能感兴趣的:(ubuntu,LNMP)