centos8 설치php7.2 소스 설치 간단한 노트

1426 단어 운영 체제
yum -y install libxml2 libxml2-devel gd gd-devel
 wget http://cn2.php.net/distributions/php-7.2.0.tar.gz
 tar -zxvf php-7.2.0.tar.gz //  
 cd php-7.2.0 //    


 
./configure --prefix=/usr/local/php --with-iconv-dir=/usr/local/libiconv --with-config-file-path=/usr/local/php --enable-mbstring --with-openssl --enable-ftp --with-gd --with-jpeg-dir=/usr --with-png-dir=/usr --with-mysql=mysqlnd --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-pear --enable-sockets --with-freetype-dir=/usr --with-zlib --with-libxml-dir=/usr --with-xmlrpc --enable-zip --enable-fpm --enable-xml --enable-sockets --with-gd --with-zlib --enable-zip --with-freetype-dir=/usr/lib/ --enable-soap --enable-pcntl --enable-cli --with-curl
make ZEND_EXTRA_LIBS='-liconv'    #  ,        
make install
cp php.ini-production /usr/local/php/etc/php.ini
cp /usr/local/php/etc/php-fpm.conf.default /usr/local/php/etc/php-fpm.conf
cp /usr/local/php/etc/php-fpm.d/www.conf.default /usr/local/php/etc/php-fpm.d/www.conf
cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
chmod +x /etc/init.d/php-fpm    //     
ln -s /etc/init.d/php-fpm /usr/bin/   //     

vim /etc/profile

export PATH=/usr/local/php/bin:$PATH       #     

source /etc/profile //         

 

좋은 웹페이지 즐겨찾기