nginx-1.10.1.tar.gz
openssl-1.0.1t.tar.gz
pcre-8.39.tar.bz2
zlib128.zip
解壓上面的軟件包到指定目錄
我這裏統一解壓到了我的用戶目錄新建的live文件夾下
/home/webrtc/live/
2.操作系統我這裏採用的centos7
//安裝pcre-devel,否則會make出錯
->yum install pcre-devel
//進入到ngnix解壓後的源碼目錄
->cd home/username/live/nginx_解壓目錄
//配置nginx
->./configure --prefix=/usr/local/nginx --with-pcre=/home/webrtc/live/pcre --with-zlib=/home/webrtc/live/zlib --with-openssl=/home/webrtc/live/openssl
–with-pcre是指需要pcre庫,/path/to/your/pcre/是指的pcre源代碼路徑,其他的同理。
其中–prefix是指定你執行make install後nginx的安裝目錄(不是你解壓的nginx源碼目錄),
3.->make
4.->make install5.執行下面的命令看到進程出現,證明安裝成功了
[root@localhost conf]# ps -ef | grep nginx
root 60091 1 0 23:13 ? 00:00:00 nginx: master process ./nginx
nobody 60092 60091 0 23:13 ? 00:00:00 nginx: worker process
root 60291 18983 0 23:19 pts/1 00:00:00 grep --color=auto nginx