nginix安装带有MaC语言 LD上的自定义OpenSSL:为架构X86_64找不到的符号



尝试使用以下命令在Mac机器上安装NGINX。

./configure --prefix=. --sbin-path=nginx_mac/nginx --conf-path=nginx_mac/nginx.conf --error-log-path=nginx_mac/error.log --pid-path=nginx_mac/nginx.pid --lock-path=nginx_mac/nginx.lock --with-pcre=../pcre-8.40 --without-http_rewrite_module --with-http_ssl_module --with-openssl=/Users/nbbuild/CA5/openssl-1.0.2d
make

我运行后,将其投入到以下错误:

   ld: symbol(s) not found for architecture x86_64
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    make[1]: *** [objs/nginx] Error 1
    make: *** [build] Error 2

不确定是什么原因引起了这个问题。任何人都可以帮助我。

我有相同的错误。在运行make后,尝试在./objs/Makefile中替换以下行。

之前:

&& ./config --prefix=/Users/macbook/Downloads/nginx-1.13.5/../openssl-1.0.2l/.openssl no-shared no-ssl3 

之后:

&& ./Configure darwin64-x86_64-cc --prefix=/Users/macbook/Downloads/nginx-1.13.5/../openssl-1.0.2l/.openssl no-shared no-ssl3 

,然后再次运行make。请勿运行./configure,因为它会覆盖它的变化。仅供参考,我在此处找到了此解决方案:https://www.widlabs.com/article/mac-os-os-os-x-nginx-compile-symbol-not-not-found-found-found-found-found-found-found-found-found-found-found-found-found-found-chartectuct-x86_64。

我希望这对您有帮助。

最新更新