標籤:安裝apache tar arc 其他 源碼包 please 問題 ref 安裝
http://mirrors.tuna.tsinghua.edu.cn/apache//httpd/httpd-2.4.27.tar.bz2Apache下載連結
在解壓Apache源碼包進入目錄運行
#./configure --prefix=/usr/local/apach時出現:
................
checking for APR... no
configure: error: APR not found . Please read the documentation
用yum下載了Apr也沒用,後來尋找資料發現完整的APR實際上包含了三個開發包:apr、apr-util以及apr-iconv,每一個開發包分別獨立開發,並擁有自己的版本。
解決辦法
1.下載所需軟體包:
1.wget http://archive.apache.org/dist/apr/apr-1.4.5.tar.gz
2.wget http://archive.apache.org/dist/apr/apr-util-1.3.12.tar.gz
3.wget http://jaist.dl.sourceforge.net/project/pcre/pcre/8.10/pcre-8.10.zip
2.
解決apr not found問題>>>>>>
[[email protected]]# tar -zxf apr-1.4.5.tar.gz
[[email protected]]# cd apr-1.4.5
[[email protected]]# ./configure --prefix=/usr/local/apr
[[email protected]]# make
[[email protected]]# make install
解決APR-util not found問題>>>>
[[email protected]]# tar -zxf apr-util-1.3.12.tar.gz
[[email protected]]# cd apr-util-1.3.12
[[email protected]]#./configure --prefix=/usr/local/apr-util -with- apr=/usr/local/apr/bin/apr-1-config
[[email protected]]# make
[[email protected]]# make install
解決pcre問題>>>>>>>>>
[[email protected]]# unzip -o pcre-8.10.zip
[[email protected]]# cd pcre-8.10
[[email protected]]# ./configure --prefix=/usr/local/pcre
[[email protected]]# make
[[email protected]]# make install
上述所有make install 以後可以用echo $?的傳回值來確認是否安裝成功(傳回值為0則成功,其他值為為安裝成功)
現在再回頭安裝Apache並指定Apache,apr,apr-util以及apr-iconv的位置。
[[email protected]]# ./configure --prefix=/usr/local/apache --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util --wieh-apr-iconv=/usr/local/pcre
[[email protected]]# make
[[email protected]]# make install
Apache安裝編譯遇到APR的問題