ubuntu18.04 编译Tengine

下载pcre、openssl、zlib三个源码包

ngx_murmur_hash2文件出现错误,编译选项增加 -Wno-error 

使用openssl-1.1.1会导致以下错误

/opt/ngnix/openssl-1.1.1/.openssl/lib/libcrypto.a(threads_pthread.o): In function `fork_once_func':
threads_pthread.c:(.text+0x16): undefined reference to `pthread_atfork'
collect2: error: ld returned 1 exit status

编译脚本:

./configure --with-cc-opt="-Wno-error" \
--with-pcre=/home/Temp/pcre-8.38 \
--with-openssl=/home/Temp/openssl-1.1.0i \
--with-zlib=/home/Temp/zlib-1.2.11

make

猜你喜欢

转载自www.cnblogs.com/csig/p/9957464.html