解决编译apache出现的问题:configure: error: APR not found . Please read the documentation

摘要:
今天编译apache时出错:#/configure--前缀

今日编译apache时出错:

#./configure --prefix……检查编辑环境时出现:

checking for APR... no
configure: error: APR not found .  Please read the documentation

解决办法:

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.编译安装:

  1. yum remove apr-util-devel apr apr-util-mysql apr-docs apr-devel apr-util apr-util-docs 

具体步骤如下:

  a:解决apr not found问题>>>>>>

  1. [root@xt test]# tar -zxf apr-1.4.5.tar.gz  
  2. [root@xt test]# cd  apr-1.4.5  
  3. [root@xt apr-1.4.5]# ./configure --prefix=/usr/local/apr  
  4. [root@xt apr-1.4.5]# make && make install  
  5.  

  b:解决APR-util not found问题>>>>

  1. [root@xt test]# tar -zxf apr-util-1.3.12.tar.gz  
  2. [root@xt test]# cd apr-util-1.3.12  
  3. [root@xt apr-util-1.3.12]# ./configure --prefix=/usr/local/apr-util -with- apr=/usr/local/apr/bin/apr-1-config  
  4. [root@xt apr-util-1.3.12]# make && make install 


  c:解决pcre问题>>>>>>>>>

  1. [root@xt test]#unzip -o pcre-8.10.zip  
  2. [root@xt test]#cd pcre-8.10  
  3. [root@xt pcre-8.10]#./configure --prefix=/usr/local/pcre  
  4. [root@xt pcre-8.10]#make && make install 

4.最后编译Apache时加上:

--with-apr=/usr/local/apr

--with-apr-util=/usr/local/apr-util/

 --with-pcre=/usr/local/pcre

成功编译完成~

make[1]: *** [pcrecpp.lo] Error 1 解决方法

make[1]: *** [pcrecpp.lo] Error 1

说明缺少安装gcc-c++库,安装即可
安装命令:yum -y install gcc-c++
重新configure,make && make install通过。

免责声明:文章转载自《解决编译apache出现的问题:configure: error: APR not found . Please read the documentation》仅用于学习参考。如对内容有疑问,请及时联系本站处理。

上篇Fiddler 菜单功能 Host配置 请求伪造 接口调试Kotlin Eclipse 环境搭建下篇

宿迁高防,2C2G15M,22元/月;香港BGP,2C5G5M,25元/月 雨云优惠码:MjYwNzM=

相关文章

Linux下安装Nginx并实现socket代理

nginx可以使用各平台的默认包来安装,本文是介绍使用源码编译安装,包括具体的编译参数信息。 正式开始前,编译环境gcc g++ 开发库之类的需要提前装好,这里默认你已经装好。 ububtu平台编译环境可以使用以下指令 1 2 apt-get install build-essential apt-get install libtool cen...

PCRE函数简介和使用示例【转】

PCRE函数简介和使用示例 标签:正则表达式listbuffercompilationnullperl 原文地址:http://blog.csdn.net/sulliy/article/details/6247155 PCRE是一个NFA正则引擎,不然不能提供完全与Perl一致的正则语法功能。但它同时也实现了DFA,只是满足数学意义上的正则。 P...

centos 安装 apache2.4

1. centos 安装 apache2.4 安装基础依赖:# yum install gcc gcc-c++ glibc glibc-devel gd gd-devel zlib zlib-devel libtool-ltdl-devel flex autoconf automakeapache 需要依赖apr 和 apr-util、apr-iconv、...

linux应用之nginx的源码安装及配置(centos)

1、准备工作选首先安装这几个软件:GCC,PCRE(Perl Compatible Regular Expression),zlib,OpenSSL。Nginx是C写的,需要用GCC编译;Nginx的Rewrite和HTTP模块会用到PCRE;Nginx中的Gzip用到zlib;用命令“# gcc”,查看gcc是否安装;如果出现“gcc: no input...

手动安装Nginx

本分类下有一个环境一键安装.那这背后发生了什么呢?咱们手动使用源码进行安装.1.首先保证有一个能联网的centos.2.百度 ningx 官网   点download  http://nginx.org/en/download.html  找到最新版的nginx下载地址. 发贴时最新的是1.12 http://nginx.org/download/ngin...

pcre 使用

1、主页地址:http://www.pcre.org/下载pcre-7.8.tar.bz22、解压缩:tar xjpf pcre-7.8.tar.bz23、配置:cd pcre-7.8./configure --prefix=/usr/local/pcre-7.8 --libdir=/usr/local/lib/pcre --includedir=/usr...