ubuntu编译安装httpd make时报错,百度上各种答案都已试过不行,求大神帮忙看看?

/bin/bash: tools/gen_test_char: cannot execute binary file: Exec format error
Makefile:141: recipe for target 'include/private/apr_escape_test_char.h' failed
make[3]: * [include/private/apr_escape_test_char.h] Error 126
make[3]: * Waiting for unfinished jobs....
make[3]: Leaving directory '/opt/src/httpd-2.4.39/srclib/apr'
/opt/src/httpd-2.4.39/srclib/apr/build/apr_rules.mk:118: recipe for target 'all-recursive' failed
make[2]: * [all-recursive] Error 1
make[2]: Leaving directory '/opt/src/httpd-2.4.39/srclib/apr'
/opt/src/httpd-2.4.39/build/rules.mk:75: recipe for target 'all-recursive' failed
make[1]: * [all-recursive] Error 1
make[1]: Leaving directory '/opt/src/httpd-2.4.39/srclib'
/opt/src/httpd-2.4.39/build/rules.mk:75: recipe for target 'all-recursive' failed
make: * [all-recursive] Error 1

参与12

4同行回答

bryanbryan软件架构设计师金融研发
cannot execute binary file: Exec format error 是不是文件没下全,有问题https://dev.mysql.com/doc/refman/5.5/en/installing-source-distribution.html显示全部

cannot execute binary file: Exec format error 是不是文件没下全,有问题

https://dev.mysql.com/doc/refman/5.5/en/installing-source-distribution.html

收起
银行 · 2019-07-18
hbhe0316hbhe0316数据库管理员IBM
下面是我的一个安装步骤:3.5. 安装apache步骤3.5.1. 安装pcre-8.38[root@apache apache]# tar xvf pcre-8.38.tar.gz[root@apache apache]# cd pcre-8.38/[root@apache pcre-8.38]# ./configure --prefix=/apache/pcre-8.38[root@apache pcre-8.38]# make &&...显示全部

下面是我的一个安装步骤:
3.5. 安装apache步骤
3.5.1. 安装pcre-8.38
[root@apache apache]# tar xvf pcre-8.38.tar.gz
[root@apache apache]# cd pcre-8.38/
[root@apache pcre-8.38]# ./configure --prefix=/apache/pcre-8.38
[root@apache pcre-8.38]# make && make install
3.5.2. 安装expat
[root@apache apache]# tar xvf expat_2.0.1.orig.tar.gz
[root@apache apache]# cd expat-2.0.1/
[root@apache expat-2.0.1]# ./configure --prefix=/apache/expat
[root@apache expat-2.0.1]# make && make install
3.5.3. 安装apr
[root@apache apache]# tar xvf apr-1.7.0.tar.gz
[root@apache apache]# cd apr-1.7.0/
[root@apache apr-1.7.0]# ./configure --prefix=/apache/apr
[root@apache apr-1.7.0]# make && make install
3.5.4. 安装apr-util
[root@apache apache]# tar xvf apr-util-1.6.1.tar.gz
[root@apache apache]# cd apr-util-1.6.1/
[root@apache apr-util-1.6.1]# ./configure --prefix=/apache/apr-util --with-apr=/apache/apr/bin/apr-1-config --with-expat=/apache/expat
[root@apache apr-util-1.6.1]# make && make install

3.5.5. 安装httpd 2.4.39
[root@apache apache]# tar xvf httpd-2.4.39.tar.gz
[root@apache apache]# cd httpd-2.4.39/
[root@apache httpd-2.4.39]# ./configure --prefix=/apache --with-apr=/apache/apr --with-apr-util=/apache/apr-util --with-pcre=/apache/pcre-8.38
[root@apache httpd-2.4.39]# make && make install
3.6. 安装后验证
使用root用户登陆,将/apache目录设置为apache用户所有。
[root@apache /]# chown -R apache:apache /apache/
修改/apache/conf/httpd.conf文件
将Listen 80修改成大于1024的端口号,以便非root用户可以使用,如下,我将80端口修改成8080
[root@apache conf]# cat httpd.conf | grep 8080
Listen 8080
启动apache
[root@apache conf]# /apache/bin/apachectl start
[root@apache conf]# netstat -an | grep 8080
tcp6 0 0 :::8080 :::* LISTEN

相关软件包下载:
链接:https://pan.baidu.com/s/1G8Xl4iIZLFFQaTRX1XC7Ng
提取码:753x

收起
IT分销/经销 · 2019-07-21
浏览3184
匿名用户匿名用户
重新更换下载包,一定要对应硬件类型显示全部

重新更换下载包,一定要对应硬件类型

收起
金融其它 · 2019-07-19
浏览3072
匿名用户匿名用户
可以再换一个下载地址。下载后,看看 readme 和 install 文档,看是否当前系统版本能满足软件要求。显示全部

可以再换一个下载地址。下载后,看看 readme 和 install 文档,看是否当前系统版本能满足软件要求。

收起
银行 · 2019-07-18
浏览3052

提问者

lyx15731059252
研发工程师天融信

相关问题

相关资料

问题状态

  • 发布时间:2019-07-18
  • 关注会员:5 人
  • 问题浏览:5282
  • 最近回答:2019-07-21
  • X社区推广