編譯配置php

2021-07-26 11:06:45 字數 1574 閱讀 7706

一、安裝相關的依賴:

yum -y install

gccgcc-c++ bzip2-devel libjpeg-devel libpng-devel freetype-devel libxml2-devel

二、解壓php安裝包php-5.6.29.tar.gz

tar -xzvf php-5.6.29.tar.gz

三、編譯安裝php

cd /home/oldboy/tools/php-5.6.29

./configure \

--with-iconv-dir=/usr/local/libiconv \

--with-freetype-dir \

--with-jpeg-dir \

--with-zlib \

--disable-rpath \

--enable-safe-mode \

--enable-bcmath \

--enable-shmop \

--enable-sysvsem \

--enable-inline-optimization \

--with-curl \

--enable-fpm \

--enable-mbstring \

--with-mcrypt \

--with-gd \

--enable--gd-native-ttf \

--with-openssl \

--with-mhash \

--enable-sockets \

--with-xmlrpc \

--enable-zip \

--enable-soap \

--enable-short-tags \

--enable-zend-multibyte \

--enable-static \

--with-xsl \

--with-fpm-user=nginx \

--with-fpm-group=nginx \

--enable-ftp

ldconfig -v

configure: error: off_t undefined; check your library configuration

此錯誤是由於以下的問題引起的重啟安裝libxslt,或者指定libxslt目錄所在的位置為題解決。。

五、複製php的配置檔案

cp /usr/src/php-5.6.22/php.ini-production /usr/local/php5.6/etc/php.ini

編譯php的配置引數

怕忘記,記錄再此.這個兩個伺服器上的設定,都只是參考.php 4.3.11 configure prefix home raid system php with mysql home raid system mysql with apxs home raid system apache bin ap...

編譯php的配置引數

怕忘記,記錄再此.這個兩個伺服器上的設定,都只是參考.php 4.3.11 configure prefix home raid system php with mysql home raid system mysql with apxs home raid system apache bin ap...

交叉編譯配置移植PHP

安裝php 進入php資料夾 tar xzvf php 5.3.16.tar.gz 4 配置 進入解壓後的資料夾 cc arm linux gcc configure host arm linux prefix home ocean php enable sockets enable pdo dis...