: This article describes how to compile the php source code of laravel and apache in linux. For more information about PHP tutorials, see. Method:
1) wgethttp: // mirrors.sohu.com/php/php-5.6.9.tar.gz
2) go to the decompressed php source code directory and execute. /configure -- enable-fpm -- enable-mbstring -- with-apxs2 =/usr/local/apache2/bin/apxs -- with-mcrypt -- with-pdo_mysql -- with-openssl -- disable-fileinfo
3) execute make & make install
Note:
1) -- enable-fpm is used to enable php through php-fpm, which can better manage FastCGI than php-cgi. (The latter is easy to automatically fail. pay special attention to the above configurations. if you just add -- enable-fpm to compile a version separately to use php-fpm, this may cause many problems due to inconsistent compilation versions)
2) -- with-apxs2 =/usr/local/apache2/bin/apxs this is related to apache, must be configured, so that the libphp5.so generated by the compilation will be automatically added to the apache side.
3) -- with-mcrypt -- with-pdo_mysql -- with-openssl these are required by laravel
4) -- disable-fileinfo must be added. Otherwise, an error may be reported during compilation: virtual memory exhausted: Cannot allocate memory.
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.
The above introduces the support for laravel and apache php source code compilation in linux, including some content, hope to be helpful to friends who are interested in PHP tutorials.