问题 1
./configure: error: the HTTP rewrite module requires the PCRE library
sudo apt-get update
sudo apt-get install libpcre3 libpcre3-dev
问题 2
./configure: error: the HTTP gzip module requires the zlib library.
sudo apt-get install zlib1g-dev
问题 3
./configure: error: the HTTP XSLT module requires the libxml2/libxslt libraries
sudo apt-get install libxml2 libxml2-dev libxslt-dev
问题 4
./configure: error:the HTTP image filter module requires the GD library.
sudo apt-get install libgd-dev libgd2-xpm-dev
问题 5
./configure: error: the GeoIP module requires the GeoIP library.
sudo apt-get install geoip-database libgeoip-dev
问题 6
./configure: error: C compiler cc is not found
sudo apt install build-essential
#如果安装失败切换阿里源
vim /etc/apt/sources.list
#然后写入如下,即可设置阿里源 以下只适合20.04
deb http://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
#在执行如下即可安装
sudo apt-get update
提供部分离线包
ubuntu20.04 安装 nginx 常用依赖库.zip
# 文件内容如下
1.gcc_4%3a9.3.0-1ubuntu2_amd64.deb
2.libgd-dev_2.2.5-5.2ubuntu2.1_amd64.deb
3.libpcre3_2%3a8.39-12ubuntu0.1_amd64.deb
4.libpcre3-dev_2%3a8.39-12ubuntu0.1_amd64.deb
5.libssl-dev_1.1.1f-1ubuntu2.19_amd64.deb
6.libx11-6_2%3a1.6.9-2ubuntu1.2_amd64.deb
7.libxml2-dev_2.9.10+dfsg-5ubuntu0.20.04.6_amd64.deb
8.libxpm-dev_1%3a3.5.12-1ubuntu0.20.04.1_amd64.deb
9.libxslt1-dev_1.1.34-4ubuntu0.20.04.1_amd64.deb
10.libxt-dev_1%3a1.1.5-1_amd64.deb
11.openssl_1.1.1f-1ubuntu2.19_amd64.deb
12.zlib1g_1%3a1.2.11.dfsg-2ubuntu1.5_amd64.deb
欢迎来到这里!
我们正在构建一个小众社区,大家在这里相互信任,以平等 • 自由 • 奔放的价值观进行分享交流。最终,希望大家能够找到与自己志同道合的伙伴,共同成长。
注册 关于