php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #22616 Wrong order of -lssl and -lcrypto with IMAP
Submitted: 2003-03-09 14:27 UTC Modified: 2003-03-10 20:13 UTC
From: druid at mail dot cz Assigned:
Status: Closed Package: Compile Failure
PHP Version: 4.3.1 OS: Linux 2.4.20
Private report: No CVE-ID:
 [2003-03-09 14:27 UTC] druid at mail dot cz
./configure and Makefile sets a wrong order of loading -lssl and -lcrypto when --with-imap and --with-imap-ssl. I used imap-2002b. I had to change the order twice. First at ./configure and second at Makefile when linking sapi/cli/php.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-03-09 17:53 UTC] sniper@php.net
And what error did you get if you didn't change the order?
What version of openssl? What was the full configure line
you used for PHP?

 [2003-03-10 02:08 UTC] druid at mail dot cz
./configure --with-apxs2=/usr/local/apache/bin/apxs --with-zlib --enable-bcmath --with-bz2=shared --enable-calendar --enable-exif --enable-ftp --with-ttf --with-gettext=shared --with-gd --with-jpeg-dir --with-png-dir --with-freetype-dir --with-mysql=shared --with-mysql-sock=shared --with-recode=shared --with-imap --with-imap-ssl=/usr/local/ssl

OpenSSL 0.9.7a

First I got problem with checking whether IMAP is working (I compiled imap-2002b in /usr/src/imap-2002b and copied c-client.a to /usr/lib (symlinked to libc-client.a of course) and copied mail.h rfc822.h linkage.h to /usr/include). Btw., I don't know why is that, that the ./configure didn't resolve the correct path to OpenSSL in --with-imap-ssl I had to put --with-imap-ssl=/usr/local/ssl to ./configure. There were unresolved symbols in config.log caused by wrong order of -lssl -lcrypto at the beginning of gcc command. So I put "-lssl -lcrypto" at line 35415:

  LIBS="$TST_LIBS $LIBS -lssl -lcrypto"

The ./configure passed just fine.
Then there was problem at the end of compilation process with linking sapi/cli/php. The same wrong order. I had to copy the whole command to clipboard and run it manually with "-lssl -lcrypt" at the end of the line.

I've tried this once before but it generated sapi/cli/php which caused segmentation fault when executed. (Error occured in "make install": something like [install-pear-installer]: segmentation fault)
 [2003-03-10 20:13 UTC] sniper@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Mon Apr 21 02:02:11 2014 UTC