|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #77392 ./configure fails on OpenSSL library searches
Submitted: 2018-12-31 22:11 UTC Modified: 2019-01-10 17:44 UTC
Avg. Score:1.0 ± 0.0
Reproduced:0 of 1 (0.0%)
From: john dot iliffe at iliffe dot ca Assigned:
Status: Open Package: *Configuration Issues
PHP Version: 7.3.0 OS: Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2018-12-31 22:11 UTC] john dot iliffe at iliffe dot ca
This report contains elements of bug reports 72363 (PHP 7.0 and 7.1 and 75726 (PHP 7.1.12).  Note the non-standard location of OpenSSL on my server.  It appears that the with-openssl= configuration variable is not being picked up.

./configure prefix=/usr/php-7.3.0 --enable-fpm --with-fpm-user=phpfpm --with-libdir=lib64 --with-fpm-group=phpfpm --with-fpm-systemd --disable-short-tags --with-openssl=/usr/openssl-1.1.0i --with-pcre-regex --with-imap=/usr/lib64 --with-imap-ssl=/usr/openssl-1.1.0i/include/openssl --with-pgsql=/usr/postgres-9.6.2/bin --enable-zip --with-pear

Fails with one of several errors:
configure: error: Cannot find OpenSSL's libraries
 - can sometimes be resolved by changing to with-openssl=/usr/openssl-1.1.0i/lib 
but this leads to 
configure: error: Cannot find OpenSSL's <evp.h> 
 - can resolve this by coding the FULL path to the include libraries:
    OPENSSL_INCDIR=/usr/openssl-1.1.0i/include/openssl in line 19052 and several 
   other places where it occurs.  Unfortunately, this messes up libs again.

There is a typo in lines 3843 and 45626 of the configure file, "-qversion" should be "--version".  It gives a configure fatal error when encountered but the configuration continues anyway, at least to the errors above.

Test script:
The ./configure shown in the previous section

Expected result:
I would expect a valid make file for the compile step. 


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2019-01-10 15:05 UTC] bugs dot php dot net at mundpropaganda dot net
"-qversion" should be perfectly fine. It caters to older versions of gcc.

I think you need to provide the directory _prefix_ to "--with-openssl", not the actual openssl directory. 

So if your openssl install really lives in "/usr/openssl-1.1.0i", you need to create a symlink à la "/usr/openssl -> /usr/openssl-1.1.0i" and run configure with "--with-openssl=/usr"

See also:
 [2019-01-10 17:44 UTC] john dot iliffe at iliffe dot ca
Thank you for the response.

I tried as suggested, set a link from /usr/openssl -> /usr/openssl-1.1.0i and changed the configuration as follows:

./configure prefix=/usr/php-7.3.0 --enable-fpm --with-fpm-user=phpfpm --with-libdir=lib64 --with-fpm-group=phpfpm --with-fpm-systemd --disable-short-tags --with-openssl=/usr/openssl --with-pcre-regex --with-imap=/usr/lib64 --with-imap-ssl=/usr/openssl --with-pgsql=/usr/postgres-9.6.2 --enable-zip --with-pear

which results in error "Cannot find OpenSSl's libraries".  I also tried changing the locations of OpenSSL to just /usr (ie --with-openssl=/usr) and that results in error "Cannot find OpenSSL's <evp.h>".  

Since there are two different places in the config where the openssl path is required, I tried various combinations of the above but all ended with "Cannot find OpenSSL's libraries"

Yes, I have several versions of OpenSSL on this server, each installed as noted under "/usr/<openssl version number>" and unfortunately they are included in various compiles (like Apache).

Thanks again.
 [2019-01-10 21:11 UTC] bugs dot php dot net at mundpropaganda dot net
Check this out:

The header files are supposed to be at "{prefix}/includes/openssl/". So your symlinks needs to be "/usr/includes/openssl -> /usr/openssl-1.1.0i", then run configure with "--with-openssl=/usr".
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Wed Jan 16 12:01:25 2019 UTC