Fix nginx add OpenSSL module compile times error problem

Source: Internet
Author: User

As shown in title, the error message is as follows:

/bin/sh:line 2:./config:no such file or directorymake[1]: * * * [/usr/local/ssl/.openssl/include/openssl/ssl.h] Error 127 MAKE[1]: Leaving directory '/usr/local/src/nginx-1.9.9 ' make: * * * [build] Error 2

Need to explain is, I compile here the use of Nginx source code is 1.9.9. According to the error message we know that the error is because nginx at compile time and can not find the corresponding file in the/usr/local/ssl/.openssl/directory, in fact, we open/usr/local/ssl/ This directory can be found in this directory is not the. OpenSSL directory, so we modify the Nginx compile when the path selection of OpenSSL can solve this problem

Solution:

Open the /usr/local/src/nginx-1.9.9/auto/lib/openssl/conf file under the Nginx source file:

Find this piece of code:

core_incs= "$CORE _incs $OPENSSL/.openssl/include" core_deps= "$CORE _deps $OPENSSL/.openssl/include/openssl/ssl.h" core_libs= "$CORE _libs $OPENSSL/.openssl/lib/libssl.a" core_libs= "$CORE _libs $OPENSSL/.openssl/lib/libcrypto.a" core_libs= "$CORE _libs $NGX _LIBDL"

Change to the following code:

core_incs= "$CORE _incs $OPENSSL/.openssl/include" core_deps= "$CORE _deps $OPENSSL/include/openssl/ssl.h" core_libs= " $CORE _libs $OPENSSL/lib/libssl.a "core_libs=" $CORE _libs $OPENSSL/lib/libcrypto.a "core_libs=" $CORE _libs $NGX _LIBDL "

And then the installation of Nginx compiled can be

PS: Reference article:

    • http://blog.csdn.net/signmem/article/details/18974587


This article is from "Zifangsky's personal blog" blog, make sure to keep this source http://983836259.blog.51cto.com/7311475/1835809

Fix nginx add OpenSSL module compile times error problem

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.