Bug #22912 bogus openssl.m4
Submitted: 2 Oct 2006 23:56 Modified: 3 Oct 2006 17:54
Reporter: Jens Elkner Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:5.0.24a OS:Solaris (Solaris 10)
Assigned to: CPU Architecture:Any

[2 Oct 2006 23:56] Jens Elkner
Description:
./configure \
        --with-openssl \
        --with-openssl-includes=/usr/sfw/include \
        --with-openssl-libs=/usr/sfw/lib/sparcv9 \

fails with "checking for OpenSSL... Could not find an installation of OpenSSL"
Cause is the use of a wrong variable ($d instead of $libs).

How to repeat:
see description

Suggested fix:
--- mysql-5.0.24a/config/ac-macros/openssl.m4.orig      Fri Aug 25 23:12:29 2006
+++ mysql-5.0.24a/config/ac-macros/openssl.m4   Tue Oct  3 01:49:15 2006
@@ -30,8 +30,8 @@
         OPENSSL_INCLUDE=-I$incs
       fi
       # Test for libssl using all known library file endings
-      if test -f $d/libssl.a || test -f $d/libssl.so || \
-         test -f $d/libssl.sl || test -f $d/libssl.dylib ; then
+      if test -f $libs/libssl.a || test -f $libs/libssl.so || \
+         test -f $libs/libssl.sl || test -f $libs/libssl.dylib ; then
         OPENSSL_LIB=$libs
       fi
       ;;

Or even better: 
===============
Use pkg-config to determine the right flags to use instead of creating your own bogus checks (openssl proviodes the approriate openssl.pc since years!!!) ...
[3 Oct 2006 6:49] Sveta Smirnova
Please do not submit the same bug more than once. An existing bug report already describes this very problem. Even if you feel that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments to the original bug instead.

Thank you for your interest in MySQL.

Duplicates bug #21327.
[3 Oct 2006 17:54] Jens Elkner
Sorry, but indeed I've tried to find an appropriate bug report before posting this one. Hmmm, perhaps I'm not compatible to the bug report system ... ;-)