安装
Centos  6.4
zlib1.2.8
mysql下载下zip如何安装
libpng1.6.9
jpegsrcv9a.
Freetype.2.5.3
apr-1.5.0
apr-util-1.5.3
gd2.44
libgd2.10
备注:  .xz  解压文件:先 xz -d 将 解压成 xxx.tar 然后,再用 tar xvf xxx.tar来解包。
安装cmake2.8.12.2
安装Mysql5.6.16
# cmake -DMYSQL_DATADIR=/base/MySQL/data
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
-DEXTRA_CHARSETS=all
-DMYSQL_UNIX_ADDR=/base/MySQL/socket
-DMYSQL_TCP_PORT=3306
-DMYSQL_USER=mysql
-DCMAKE_INSTALL_PREFIX=/base/MySQL
-DINSTALL_SBINDIR=bin
上面参数过于复杂
所以直接 cmake .
make
make install
默认安装路径/usr/local/mysql
groupadd mysql 
useradd -g mysql mysql
chown -sql /usr/local/mysql
cd /usr/local/mysql/scripts
./mysql_install_db –user=mysql  --basedir=/usr/local/mysql –datadir=/usr/local/mysql/data
cd  /usr/local/mysql/support-files
cp mysql.server /etc/rc.d/init.d/mysql
cp my-defaultf /etc/myf
chkconfig -add mysql
chkconfig mysql on
service mysql start
mysql
安装httpd2.4.7
./configure --prefix=/usr/local/apache2 --enable-lib64 --libdir=/usr/lib64 --enable-so --enable-deflate=shared --enable-expires=shared --enable-rewrite=shared --enable-mods-s
hared=all --enable-modules=all --enable-static-support --with-z=/usr/local/zlib --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util --with-included-apr --with-pcre=/usr/local/pcre --enable-cache --enable-disk-cache --enable-mem-cache --enable-file-cache
make
make install
cd /usr/local/apache2
cd bin
./apachectl -t
./apchectl  start
成功
安装libxml2-2.9.1
./configure –prefix=/usr/local/libxml
make
make[4]: *** [libxml.lo] 错误 1
make[4]: Leaving directory `/root/libxml2-2.9.1/python'
make[3]: *** [all-recursive] 错误 1
make[3]: Leaving directory `/root/libxml2-2.9.1/python'
make[2]: *** [all] 错误 2
make[2]: Leaving directory `/root/libxml2-2.9.1/python'
make[1]: *** [all-recursive] 错误 1
make[1]: Leaving directory `/root/libxml2-2.9.1'
make: *** [all] 错误 2
make clean
重装
试验./configure
依旧出错
再重装
安装libtool
libtool-2.
依旧出错
安装libiconv1.14
依旧出错
安装 apr-iconv-1.2.1
依旧出错
跳过
直接安装libmcrypt-2.5.7
再次重装libxml
./configure --prefix=/usr/local/libxml2 --disable-static --with-history --with-python --with-modules --disable-shared –with-pic
make
错误依旧
安装python-2.7.5.tar.bz2
tar xvf python-2.7.5.tar.bz2
cd python-2.7.5
./configure –prefix=/usr/local/python
make
make install
重新编译libxml
./configure --prefix=/usr /local/libxml2 --disable-static --with-history
make
仍旧出错
下载
Python-2.7.6
xz -d Python-2.7.
tar  xvf Python-2.7.6.tar
cd Python-2.7.6
./configure --prefix=/usr      \
            --enable-shared    \
            --with-system-expat \
            --with-system-ffi  \
            --enable-unicode=ucs4 &&
make
make install
继续重新编译libxml
./configure –prefix=/usr/local/libxml2 –with-python=/usr/local/python
make
make install
通过
安装 mhash0.9.9.9
下载curl-7.35.安装
安装php-5.5.10
./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc/ --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir=/usr/local/libiconv --with-freetype-dir=/usr/local/freetype/ --with-jpeg-dir=/usr/local/jpeg9/ --with-png-dir=/usr/local/libpng/ --with-zlib-dir=/usr/local/zlib/ --with-libxml-dir=/usr/local/libxml2/ --enable-xml --enable-mbstring --enable-ftp --with-gd=/usr/local/gd2/ --with-mhash=/usr/local/libmhash --without-pear --enable-sockets --enable-soap --enable-gd-native-ttf --enable-sysvsem --enable-sysvshm --enable-shmop --enable-zip  --with-mcrypt
=/usr/local/libmcrypt/ --with-pcre-regex=/usr/local/pcre  --enable-bcmath  --with-curl=/usr/local/curl  --enable-mbregex --with-openssl
出错
/root/php-5.5.10/ext/gd/gd.c:57:22: 错误:X11/xpm.h:没有那个文件或目录
make: *** [ext/gd/gd.lo] 错误 1
重新编译GD
重新编译 php
错误依旧
下载libxpm-3.5.
yum install libxpm-develop
重新编译PHP
/root/php-5.5.10/ext/gd/gd.c:1330: undefined reference to `XpmLibraryVersion'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] 错误 1
make clean
make ZEND_EXTRA_LIBS='-liconv'
make: *** [libphp5.la] 错误 1
yum  install libtool-ltdl-devel
yum  install libtool
重新编译PHP
依旧出错
cd/usr/loal/mysql
ln -s libmysqlclient.so.15.0.0 libmysqlclient_r.so
出错/usr/bin/ld: cannot find -liconv
collect2: ld returned 1 exit status
make: *** [libphp5.la] 错误
将--with-iconv-dir=/usr/local/libiconv去掉重新编译
./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc/ --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir=/usr/local/libiconv --with-freetype-dir=/usr/local/freetype/ --with-jpeg-dir=/usr/local/jpeg9/ --with-png-dir=/usr/local/libpng/ --with-zlib-dir=/usr/local/zlib/ --with-libxml-dir=/usr/local/libxml2/ --enable-xml --enable-mbstring --enable-ftp --with-gd=/usr/local/gd2/ --with-mhash=/usr/local/libmhash --without-pear --enable-sockets --enable-soap --enable-gd-native-ttf --enable-sysvsem --enable-sysvshm --enable-shmop --enable-zip --with-mcrypt=/
usr/local/libmcrypt/ --with-pcre-regex=/usr/local/pcre --enable-bcmath  --with-curl=/usr/local/curl  --enable-mbregex --with-openssl

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。