【转】解决编译安装NGINX时make报错

编译参数:--[[email protected]]#./configure--user=nginx--group=nginx--prefix=/usr/local/nginx--with-http_stub_status_module--with-http_ssl_mod

编译参数:

--[[email protected] nginx-1.4.6]# ./configure --user=nginx --group=nginx --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-pcre=/usr/local/pcre/

NGINX编译通过后,make时报错如下:

[[email protected] nginx-1.4.6]# make make -f objs/Makefile make[1]: Entering directory `/usr/src/nginx-1.4.6‘ cd /usr/local/pcre/ \ && if [ -f Makefile ]; then make distclean; fi \ && CC="cc" CFLAGS="-O2 -fomit-frame-pointer -pipe " \ ./configure --disable-shared /bin/sh: line 2: ./configure: No such file or directory make[1]: *** [/usr/local/pcre//Makefile] Error 127 make[1]: Leaving directory `/usr/src/nginx-1.4.6‘ make: *** [build] Error 2 [[email protected] nginx-1.4.6]#

主要错误:make[1]: *** [/usr/local/pcre//Makefile] Error 127

查看了下帮助

[[email protected] nginx-1.4.6]# ./configure --help | grep ‘\--with-pcre‘ --with-pcre force PCRE library usage --with-pcre=DIR set path to PCRE library sources --with-pcre-opt=OPTIONS set additional build options for PCRE --with-pcre-jit build PCRE with JIT compilation support [[email protected] nginx-1.4.6]#

发现--with-pcre=DIR是设置pcre的源码目录,而不是pcre的安装目录

重新修改Nginx编译参数

[[email protected] nginx-1.4.6]# ./configure --user=nginx --group=nginx --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-pcre=/usr/src/pcre-8.10/

编译通过后执行make && make install 都应该不会有问题

时间: 2024-10-05 10:04:52

【转】解决编译安装NGINX时make报错的相关文章

编译安装nginx时配置开机自启

详细编译安装nginx请参考[Nginx目录结构与配置文件详解]以及[Nginx安装部署],在这里就进行简单安装 安装Nginx 环境介绍 操作系统: [[email protected] ~]# cat /etc/redhat-release CentOS Linux release 7.6.1810 (Core) [[email protected] ~]# uname -a Linux localhost.localdomain 3.10.0-957.el7.x86_64 #1 SMP T

mysql5.5 免编译安装及脚本启动报错深入

Mysql安装环境简介: 最近在做MHA.已经安装完毕heartbeat和drbd,现在准备安装Mysql. Mysql安装目录:/opt/mysql Mysql数据目录:/data/mysql 备注:/data目录实际是drbd需要同步到备节点的磁盘分区 [[email protected] src]# df -h Filesystem     Size  Used Avail Use% Mounted on /dev/sda2      9.5G  2.0G  7.1G 22% / tmpf

编译安装php5.6.30报错

[[email protected]_id01_u4_19.116 Software]# cat /etc/redhat-release CentOS release 6.8 (Final)...编译报错:make: *** [sapi/cli/php] Error 1 分析在编译安装php时出现 [undefined reference to libiconv_open']子类的错误信息,表示在 ./configure 没抓好些环境变数值,错误发生点在建立 [ -o sapi/cli/php]

centos7.2编译安装mysql5.7.21报错解决

编译安装mysql 安装环境安装包[[email protected] ~]# ls /root/tools/app.tar.gz mysql-5.7.21 mysql-5.7.21.tar.gz nginx-1.15.0.tar.gz nginx_conf.tar.gz操作系统[[email protected] ~]# cat /etc/redhat-release CentOS Linux release 7.2.1511 (Core) 内存[[email protected] ~]# f

Yum编译安装Error Downloading Packages报错

1:执行yum clean all 清除缓存目录下的软件包及旧的headers: 2:接着执行 yum list重新列出所有已经安装和可以安装的软件包: 3:重新执行上述命令,发现yum编译成功: 注意:如果执行 yum list 报错,那就检查一下yum仓库是否有问题:并清除/etc/yum.repos.d/下多余.repo文件!

centos7 安装nginx及处理报错信息

1通过wget方式下载nginx的安装包下载连接可以到nginx官网去获取 www.nginx.org 此处给一个可以下载的链接 http://120.52.51.15/nginx.org/download/nginx-1.14.2.tar.gz linux 命令台 输入命令 wget http://120.52.51.15/nginx.org/download/nginx-1.14.2.tar.gz .FAQ :如果提示wget错误 使用命令 yum install wget 进行安装2 解压

完美解决oracle11gR2安装grid检查ASM报错PRVG-10122

报错PRVG-10122 rac1,rac2都报错 先讲主要原因:kmod-oracleasm包的版本比较老,要安装适配自己内核版本的 首先我在rac1上卸载掉之前下载的kmod-oracleasm yum install kmod-oracleasm 安装一下 #oracleasm configure [[email protected] sysconfig]# oracleasm configure ORACLEASM_ENABLED=true ORACLEASM_UID=grid ORAC

centos7源码安装mysql时cmake报错

报错代码: CMake Error at cmake/boost.cmake:81 (MESSAGE):You can download it with -DDOWNLOAD_BOOST=1 -DWITH_BOOST=解决办法:1.在/usr/local下创建一个名为boost的文件夹mkdir -p /usr/local/boost2.进入这个新创建的文件夹然后下载boostwget http://www.sourceforge.net/projects/boost/files/boost/1

mysql编译安装完启动时候报错

[[email protected] mysql]# /etc/init.d/mysqld start Starting MySQL. ERROR! The server quit without updating PID file (/tmp/mysql.pid). [[email protected] mysql]# tail -f data/host2.err InnoDB: Error: log file ./ib_logfile0 is of different size 0 4194