當前位置:首頁 » 編程軟體 » centos65編譯php

centos65編譯php

發布時間: 2022-04-17 12:24:38

㈠ 求助,centos7編譯源碼php時載入庫的問題

php-fpm參數:

--start 啟動
--stop 強制終止
--quit 平滑終止
--restart 重啟
--reload 重新平滑載入php的php.ini
--logrotate 重新啟用log文件

㈡ centos編譯安裝php7怎麼加入apache

直接下載PHP7.0.2的安裝包解壓,編譯,安裝:
下載php7,並解壓
$ cd /usr/src/
$ wget http://cn2.php.net/distributions/php-7.0.2.tar.gz
#解壓
$ tar -xzxvf php-7.0.2.tar.gz
$ cd php-7.0.2
解壓完後先不要編譯,請檢查是否安裝了gcc ,沒有的話執行yum install gcc
檢查是否安裝了libxml2 ,沒有的話執行yum install libxml2
檢查是否安裝了libxml2-devel,沒有的話執行yum install libxml2-devel
註:因為改為用nginx了,所以編譯參數中的--with-apxs2=/usr/bin/apxs去掉了,如果要配置apache用,安裝PHP前,請先安裝apache。

㈢ 我的CentOS6.0已經安裝了php 5.3.2 ,怎麼給它加上php-fpm呢

PHP-FPM是一個PHP FastCGI管理器,是只用於PHP的。
PHP-FPM其實是PHP源代碼的一個補丁,旨在將FastCGI進程管理整合進PHP包中。必須將它patch到你的PHP源代碼中,在編譯安裝PHP後才可以使用。
現在我們可以在最新的PHP 5.3.2的源碼樹里下載得到直接整合了PHP-FPM的分支,據說下個版本會融合進PHP的主分支去。相對Spawn-FCGI,PHP-FPM在CPU和內存方面的控制都更勝一籌,而且前者很容易崩潰,必須用crontab進行監控,而PHP-FPM則沒有這種煩惱。
PHP5.3.3已經集成php-fpm了,不再是第三方的包了。PHP-FPM提供了更好的PHP進程管理方式,可以有效控制內存和進程、可以平滑重載PHP配置,比spawn-fcgi具有更多優點,所以被PHP官方收錄了。在./configure的時候帶 –enable-fpm參數即可開啟PHP-FPM。
使用PHP-FPM來控制PHP-CGI的FastCGI進程

㈣ centos 下編輯php用什麼好

用VIM就行啊,強大的文本編輯器
如果用的是centos桌面的話,可以用emacs

㈤ centos7編譯php5.4.38時出錯

1. centos7信息

uname -a

linux dev 3.10.0-327.el7.x86_64 #1 SMP Thu Nov 19 22:10:57 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

2. 運行 ./configure 報錯

configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
3. 運行 grep error config.log

cc: error: unrecognized command line option '-V'
cc: fatal error: no input files
cc: error: unrecognized command line option '-qversion'
cc: fatal error: no input files
conftest.c:9:19: fatal error: stdio.h: No such file or directory
configure:4076: error: in `/usr/local/src/php-5.6.19':
configure:4078: error: cannot run C compiled programs.

4. 按照網上說的方法 在configure後面加上了 --host=x86_64 ,報錯
configure: error: in `/usr/local/src/php-5.6.19':
configure: error: C preprocessor "/lib/cpp" fails sanity check
5. config.log中錯誤提示,差好幾個頭文件

cc: error: unrecognized command line option '-V'
cc: fatal error: no input files
cc: error: unrecognized command line option '-qversion'
cc: fatal error: no input files
conftest.c:9:19: fatal error: stdio.h: No such file or directory
configure:4076: error: in `/usr/local/src/php-5.6.19':
configure:4078: error: cannot run C compiled programs.
[root@dev php-5.6.19]# grep error config.log
cc: error: unrecognized command line option '-V'
cc: fatal error: no input files
cc: error: unrecognized command line option '-qversion'
cc: fatal error: no input files
conftest.c:9:19: fatal error: stdio.h: No such file or directory
conftest.c:9:20: fatal error: stdarg.h: No such file or directory
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
cc: error: unrecognized command line option '-qlanglvl=extc89'
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
cc: error: unrecognized command line option '-qlanglvl=ansi'
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
cc: error: unrecognized command line option '-std'
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
<command-line>:0:1: error: missing '(' after predicate
conftest.c:9:20: fatal error: stdarg.h: No such file or directory
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
<command-line>:0:1: error: missing '(' after predicate
conftest.c:9:20: fatal error: stdarg.h: No such file or directory
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
cc: error: unrecognized command line option '-Xc'
| These don't provoke an error unfortunately, instead are silently treated
| as 'x'. The following inces an error, until -std is added to get
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
conftest.c:12:0: fatal error: assert.h: No such file or directory
| Syntax error
conftest.c:12:0: fatal error: assert.h: No such file or directory
| Syntax error
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
conftest.c:10:21: fatal error: limits.h: No such file or directory
| Syntax error
configure:4478: error: in `/usr/local/src/php-5.6.19':
configure:4480: error: C preprocessor "/lib/cpp" fails sanity check

6. gcc安裝信息

[root@dev php-5.6.19]# rpm -qa | grep glibc
compat-glibc-headers-2.12-4.el7.centos.x86_64
glibc-utils-2.17-106.el7_2.4.x86_64
glibc-common-2.17-106.el7_2.4.x86_64
glibc-devel-2.17-106.el7_2.4.x86_64
glibc-static-2.17-106.el7_2.4.x86_64
glibc-2.17-106.el7_2.4.x86_64
glibc-headers-2.17-106.el7_2.4.x86_64
compat-glibc-2.12-4.el7.centos.x86_64

[root@dev php-5.6.19]# gcc -v
Using built-in specs.

COLLECT_GCC=gcc

COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/4.8.5/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-languages=c,c++,objc,obj-c++,java,fortran,ada,go,lto --enable-plugin --enable-initfini-array --disable-libgcj --with-isl=/builddir/build/BUILD/gcc-4.8.5-20150702/obj-x86_64-redhat-linux/isl-install --with-cloog=/builddir/build/BUILD/gcc-4.8.5-20150702/obj-x86_64-redhat-linux/cloog-install --enable-gnu-indirect-function --with-tune=generic --with-arch_32=x86-64 --build=x86_64-redhat-linux
Thread model: posix
gcc version 4.8.5 20150623 (Red Hat 4.8.5-4) (GCC)

㈥ centos編譯安裝php 怎麼安裝jpeg擴展

伺服器跑的的環境主要是Python/Ruby,有時也需要簡單跑跑PHP腳本,所以也安裝了PHP,環境是Nginx+php-fpm,PHP是源碼編譯安裝的,所以是最小化安裝,甚至連mysqli擴展都沒有。今天需要用到GD庫,才發現沒GD庫環境,所以需要安裝這個擴展。對付單個擴展,單獨編譯動態載入是比較方便快捷的。安裝過程也比較繁雜

㈦ CentOS6.3 編譯安裝php 錯誤 bash: --prefix=/usr/local/php/: 沒有那個文件或目錄

先建目錄
mkdir -p /usr/local/php

㈧ centos 6.5 64位 編譯安裝php5.6.8 完成後沒有 /etc/php.d目錄

配置文件在源碼包需要手動復制過去,或者在編譯安裝的時候指定位置

㈨ Centos7下編譯php5.6.19出錯,怎麼解決

第一次編譯安裝PHP的時候很順利,因為要增加freetype,所以要重新編譯,結果死活就是無法通過configure。
1. centos7信息
2. 運行 ./configure 報錯
3. 運行 grep error config.log
4. 按照網上說的方法 在configure後面加上了 --host=x86_64 ,報錯
5. config.log中錯誤提示,差好幾個頭文件
6. gcc安裝信息
下次那你還有什麼不懂的你就去後盾人看看,那裡的教學視頻有很多,我就是在那裡學會的

㈩ centos7編譯php出現問題 系統:CENTOS7 64位 PHP版本:7.1.0 APACHE版本:2.4.25 MYSQL版

1、php的編譯問題主要是依賴包沒有提前安裝
2、如果依賴mysql,就先安裝mysql-devel或編譯mysql
3、需要提前安裝的有,不能寫太細,太細會被度娘屏蔽:
yasm-1.3.0.tar.gz
libmcrypt-2.5.8.tar.gz
libvpx-v1.3.0.tar.bz2
tiff-4.0.3.tar.gz
libpng-1.6.16.tar
freetype-2.5.4.tar.gz
jpegsrc.v9a.tar.gz
libgd-2.2.3.tar.gz
t1lib-5.1.2.tar.gz
4、安裝編譯php
5、安裝php後有一些優化包根據需要安裝

熱點內容
x3000r存儲卡 發布:2025-03-19 00:12:22 瀏覽:219
ie不顯示腳本錯誤 發布:2025-03-19 00:09:53 瀏覽:956
免費網頁源碼 發布:2025-03-19 00:09:00 瀏覽:260
工業企業資料庫 發布:2025-03-18 23:51:44 瀏覽:93
寶馬車的配置主要看哪些 發布:2025-03-18 23:50:09 瀏覽:484
esxi虛擬存儲 發布:2025-03-18 23:49:59 瀏覽:771
mc自己開伺服器地址 發布:2025-03-18 23:47:10 瀏覽:701
藍凌關聯配置什麼意思 發布:2025-03-18 23:46:16 瀏覽:347
雲存儲vmware 發布:2025-03-18 23:41:51 瀏覽:890
怎麼從配置模式轉到用戶模式 發布:2025-03-18 23:36:07 瀏覽:334