安裝
centorOs下面的安裝
安裝前置工作
yum groupinstall "Development tools"
yum install httpd-devel
yum install httpd php php-mysql php-mbstring
yum install libxml2-devel gd-devel libmcrypt-devel libcurl-devel openssl-devel
yum -y install libxml2 libxml2-devel openssl openssl-devel
curl-devel libjpeg-devel libpng-devel freetype-devel
libmcrypt-devel epel-release libmcrypt-devel
版本號
phpmyadmin : 4.6.6
php版本: php5.5
openssl的版本:1.0.1
支持的mysql : mysql5.5及以上
安裝mcrypt
wget http://nchc.dl.sourceforge.net/project/mcrypt/Libmcrypt/2.5.8/libmcrypt-2.5.8.tar.gz
tar xvf libmcrypt-2.5.8.tar.gz
cd libmcrypt-2.5.8
./configure --prefix=/usr/local/libmcrypt
make
make install
升級bison
cd /var/soft/
wget http://ftp.gnu.org/gnu/bison/bison-2.6.4.tar.gz
tar -xvzf bison-2.6.4.tar.gz
cd bison-2.6.4
./configure
make && make install
openssql的安裝
wget http://www.openssl.org/source/openssl-1.0.1g.tar.gz
./config --prefix=/usr --openssldir=/usr/local/openssl shared
make
make test
make install
php的安裝
http://us3.php.net/downloads.php
1.下載
2.configure
sudo ./configure --with-apxs2=/usr/sbin/apxs
--disable-cli --enable-shared --with-libxml-dir
--with-gd --with-openssl --enable-mbstring
--with-mysqli --with-mysql --enable-opcache
--enable-mysqlnd --enable-zip --with-zlib-dir
--with-pdo-mysql --with-jpeg-dir --with-freetype-dir
--with-curl --without-pdo-sqlite --without-sqlite3
--with-mcrypt=/usr/local/libmcrypt/
問題
1.
配置
配置httpd
建立httpd和php的關聯
AddType application/x-httpd-php .php
AddType application/x-httpd-php .php .phtml .php3
AddType application/x-httpd-php-source .phps
LoadModule php7_module modules/libphp7.so