1*4882a593SmuzhiyunFrom b73b802282bf95d214c86ba943c5765ba6930bc1 Mon Sep 17 00:00:00 2001 2*4882a593SmuzhiyunFrom: Jim Somerville <Jim.Somerville@windriver.com> 3*4882a593SmuzhiyunDate: Mon, 21 Oct 2013 12:50:44 -0400 4*4882a593SmuzhiyunSubject: [PATCH] Fix flawed dynamic -ldb link test in configure 5*4882a593Smuzhiyun 6*4882a593SmuzhiyunThe test uses dbopen, but just ignores the fact 7*4882a593Smuzhiyunthat this function may not exist in the db version 8*4882a593Smuzhiyunused. This leads to the dynamic link test failing 9*4882a593Smuzhiyunand the configure script just making assumptions 10*4882a593Smuzhiyunabout why and setting the need for -ldb incorrectly. 11*4882a593Smuzhiyun 12*4882a593SmuzhiyunSigned-off-by: Jim Somerville <Jim.Somerville@windriver.com> 13*4882a593Smuzhiyun 14*4882a593Smuzhiyun--- 15*4882a593Smuzhiyun configure.ac | 10 ++++++++++ 16*4882a593Smuzhiyun 1 file changed, 10 insertions(+) 17*4882a593Smuzhiyun 18*4882a593Smuzhiyundiff --git a/configure.ac b/configure.ac 19*4882a593Smuzhiyunindex d2f7feb..c7ae568 100644 20*4882a593Smuzhiyun--- a/configure.ac 21*4882a593Smuzhiyun+++ b/configure.ac 22*4882a593Smuzhiyun@@ -3235,6 +3235,16 @@ case "$host" in 23*4882a593Smuzhiyun ;; 24*4882a593Smuzhiyun esac 25*4882a593Smuzhiyun 26*4882a593Smuzhiyun+if test "x$ac_cv_have_decl_dbopen" = "xyes"; then 27*4882a593Smuzhiyun+ dnl 1.85 28*4882a593Smuzhiyun+ SQUID_CHECK_DBOPEN_NEEDS_LIBDB 29*4882a593Smuzhiyun+else 30*4882a593Smuzhiyun+ # dbopen isn't there. So instead of running a compile/link test that 31*4882a593Smuzhiyun+ # uses it and is thus guaranteed to fail, we just assume that we will 32*4882a593Smuzhiyun+ # need to link in the db library, rather than fabricate some other 33*4882a593Smuzhiyun+ # dynamic compile/link test. 34*4882a593Smuzhiyun+ ac_cv_dbopen_libdb="yes" 35*4882a593Smuzhiyun+fi 36*4882a593Smuzhiyun dnl System-specific library modifications 37*4882a593Smuzhiyun dnl 38*4882a593Smuzhiyun case "$host" in 39