User Tools

Site Tools


php:buildphpapachenginxfromsource

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
php:buildphpapachenginxfromsource [2019/11/14 02:59] – [Build and Install Memcache server] adminphp:buildphpapachenginxfromsource [2022/10/29 16:15] – external edit 127.0.0.1
Line 5: Line 5:
 yum install gcc-c++ yum install gcc-c++
 yum install automake yum install automake
 +yum install make
 </code> </code>
 ===== Build and config PHP and Nginx ===== ===== Build and config PHP and Nginx =====
Line 278: Line 279:
 yum install libxml2-devel yum install libxml2-devel
 yum install libxslt-devel yum install libxslt-devel
 +yum install bison bison-devel
 </code> </code>
   * step2: Build libmcrypt: libmcrypt-2.5.8.tar.gz   * step2: Build libmcrypt: libmcrypt-2.5.8.tar.gz
Line 286: Line 288:
 </code> </code>
      
-  * step4: Build php-fpm (add option **--enable-fpm**)<code bash>+  * Step4:If you don't find file configure, run script below<code bash> 
 +./buildconf --force 
 +</code>  
 +  * step5: Build php-fpm (add option **--enable-fpm**)<code bash>
 tar zxvf php-5.3.28.tar.gz tar zxvf php-5.3.28.tar.gz
 cd php-5.3.28 cd php-5.3.28
Line 292: Line 297:
 make & make install make & make install
 cp php.ini-production /usr/local/php/etc/php.ini cp php.ini-production /usr/local/php/etc/php.ini
 +</code>
 +=== Build PHP7.4 with php-fpm ===
 +<code bash>
 +./configure --prefix=/onec/php7 --with-config-file-path=/onec/php7/etc --with-libdir=lib64 --enable-fpm --disable-rpath --disable-ipv6 --disable-safe-mode --enable-opcache --enable-calendar --enable-bcmath --enable-ftp --enable-soap --enable-shared --enable-mbstring --disable-mbregex --enable-magic-quotes --enable-sockets --with-openssl --with-zlib --with-gd --with-jpeg-dir=/usr --with-png-dir=/usr --with-freetype-dir=/usr --with-zlib-dir=/usr --with-mysql --with-mysqli --without-sqlite3 --without-pdo-sqlite --with-pdo-mysql --with-pear --with-curl --with-curlwrappers --with-mcrypt=/usr/local
 +</code> option **--disable-mbregex** fix error:<code>
 +configure: error: Package requirements (oniguruma) were not met
 </code> </code>
 === Script start php-fpm === === Script start php-fpm ===
php/buildphpapachenginxfromsource.txt · Last modified: 2024/10/28 05:24 by admin