php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #25719 openssl library not found
Submitted: 2003-10-01 13:53 UTC Modified: 2003-10-03 05:34 UTC
From: elmicha@php.net Assigned:
Status: Closed Package: Compile Failure
PHP Version: 4CVS-2003-10-02 (stable) OS: Linux
Private report: No CVE-ID: None
 [2003-10-01 13:53 UTC] elmicha@php.net
Description:
------------
Not sure if it's the same problem as reported in the closed #25703; but with php4-STABLE-200310011530, I still get:

checking for OpenSSL support... yes
checking for pkg-config... /usr/local/bin/pkg-config
checking for OpenSSL version... >= 0.9.6
checking for CRYPTO_free in -lcrypto... yes
checking for SSL_CTX_set_ssl_version in -lssl... no
configure: error: libssl not found!



Reproduce code:
---------------
./configure --with-openssl

Expected result:
----------------
configure should find the ssl lib. It works fine with PHP-4.3.3.

Actual result:
--------------
config.log says configure used this check:

configure:16233: gcc -o conftest -D_FILE_OFFSET_BITS=64  -Wl,-rpath,/usr/local/ssl/lib -L/usr/local/ssl/lib -lintl -lcrypto conftest.c -lssl  -lresolv -lm -ldl -lnsl  1>&5
/usr/local/ssl/lib/libssl.a(ssl_lib.o): In function `SSL_clear':
ssl_lib.o(.text+0x83): undefined reference to `ERR_put_error'
ssl_lib.o(.text+0xd2): undefined reference to `BUF_MEM_free'
[...]

When I try

gcc -o conftest -D_FILE_OFFSET_BITS=64  -Wl,-rpath,/usr/local/ssl/lib -L/usr/local/ssl/lib -lintl  conftest.c -lssl -lcrypto -lresolv -lm -ldl -lnsl

(i.e. -lcrypto after -lssl), the test compiles fine.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-10-03 00:27 UTC] sniper@php.net
Should really be fixed in CVS now. (fingers crossed :)

 [2003-10-03 05:34 UTC] elmicha@php.net
Yes, it works now, great!

FWIW, apparently the problem only happened with a static libcrypto.a/libssl.a, on systems with libcrypto.so/libssl.so the linker had no problem.

 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Tue Nov 29 07:05:52 2022 UTC