Centos下Apache的源码安装
2016-12-01 19:01
302 查看
版本:httpd2.4.23
依赖包:apr-1.5.2.tar.gz apr-util-1.5.4.tar.gz gcc pcre
①先安装好GCC,简单 ,yum install最合适
②tar httpd-2.4.23 apr-1.5.2.tar.gz apr-util-1.5.4.tar.gz 解压
③ apr以及apr-util这两个文件夹移动到httpd-2.4.23的srclib目录
mv apr-1.5.2 apr
mv apr-util-1.5.4 apr-util
mv apr /usr/local/httpd-2.4.23/srclib/
mv apr-util /usr/local/httpd-2.4.23/srclib/
④解压pcre,进入解压后的目录,
./configure --prefix=/usr/local/pcre
make
make install
⑤cd /usr/local/httpd-2.4.23
./configure --prefix=/opt/apache2 --with-pcre=/usr/local/pcre
make
make install
在初期安装出现问题:buckets/apr_brigade.c: In function 'apr_brigade_partition':
buckets/apr_brigade.c:140: error: 'APR_SIZE_MAX' undeclared (first use in this function)
buckets/apr_brigade.c:140: error: (Each undeclared identifier is reported only once
buckets/apr_brigade.c:140: error: for each function it appears in.)
make[1]: *** [buckets/apr_brigade.lo] Error 1
make: *** [all-recursive] Error 1
解决方案 :apr以及apr-util版本问题,apr-util是1.5版本的,apr是1.2版本的,删除apr-1.2后换用1.5版本,一次性安装成功。
依赖包:apr-1.5.2.tar.gz apr-util-1.5.4.tar.gz gcc pcre
①先安装好GCC,简单 ,yum install最合适
②tar httpd-2.4.23 apr-1.5.2.tar.gz apr-util-1.5.4.tar.gz 解压
③ apr以及apr-util这两个文件夹移动到httpd-2.4.23的srclib目录
mv apr-1.5.2 apr
mv apr-util-1.5.4 apr-util
mv apr /usr/local/httpd-2.4.23/srclib/
mv apr-util /usr/local/httpd-2.4.23/srclib/
④解压pcre,进入解压后的目录,
./configure --prefix=/usr/local/pcre
make
make install
⑤cd /usr/local/httpd-2.4.23
./configure --prefix=/opt/apache2 --with-pcre=/usr/local/pcre
make
make install
在初期安装出现问题:buckets/apr_brigade.c: In function 'apr_brigade_partition':
buckets/apr_brigade.c:140: error: 'APR_SIZE_MAX' undeclared (first use in this function)
buckets/apr_brigade.c:140: error: (Each undeclared identifier is reported only once
buckets/apr_brigade.c:140: error: for each function it appears in.)
make[1]: *** [buckets/apr_brigade.lo] Error 1
make: *** [all-recursive] Error 1
解决方案 :apr以及apr-util版本问题,apr-util是1.5版本的,apr是1.2版本的,删除apr-1.2后换用1.5版本,一次性安装成功。
相关文章推荐
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- CentOS7下源码安装Apache2.4.9
- CentOS下源码安装Apache2.4+PHP5.4+MySQL5.5
- CentOs5.4 64/32系统 ---源码安装apache2.2.23
- CentOS 6.5 apache源码安装2.0版
- centos7下 源码安装 apache记录
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- Linux下MySQL、Apache、PHP源码安装全程实录(CentOS 6.4)
- centos5.5下源码安装apache
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- CentOS 6.3 安装配置Apache2.2.6的方法(源码编译安装)
- centos 6.2 源码安装 apache-2.2.21
- CentOS下源码安装Apache2.4+PHP5.4+MySQL5.5
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- 亲测CentOS 6.6 x86_64下源码安装LAMP平台(APACHE 2.4.16+MYSQL 5.6.17+PHP 5.6.7)
- CentOS 4.4下源码编译安装apache+php+mysql
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境
- CentOS 5.8 中源码安装apache2.4.7和php5.4.23
- CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境