Nginx Install (Mac OS) error Ld:symbol (s) not found for architecture x86_64

Source: Internet
Author: User
Tags openssl library

Today on the Mac OS compiled installation Nginx, error: Ld:symbol (s) not found for architecture x86_64, after some tossing and finding, because Nginx relies on the OpenSSL library, view OpenSSL. Config file found that the problem should be Openssl/config script to your system is 64 bit, but will be based on $kernel_bits to determine whether to turn on x86_64 compilation, default does not open, he will give you 5 seconds to confirm whether to stop compiling, manually set x86_ 64 compile, so default you generate the OpenSSL library file is 32 bits, and finally statically linked to nginx error. There seems to be no good way to pass the x86_64 parameters to the OpenSSL configuration file (Openssl/config Guess OS architecture, set whether the compiled parameter is 32-bit or 64-bit, default is 32 bit, and then call openssl/ Configure generate Makefile),

The solution is:

Run the Nginx source directory first
$./configure

And then in the OBJS, open the makefile,

Found:./config--prefix=xxx.openssl no-shared (Note: XXX is an existing OpenSSL source path)

Change the./config of the paragraph to./configure DARWIN64-X86_64-CC Other later parameters unchanged, save

And then make is compiled and passed.

Nginx Install (Mac OS) error Ld:symbol (s) not found for architecture x86_64

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.