Re: [Patch 1/1] CLD: fix crash in __mutex_get_max (libdb-4.7.so) on F13

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 29 Nov 2009 20:38:45 -0500
Jeff Garzik <jeff@xxxxxxxxxx> wrote:

> Interesting...  I recall the root cause clearly, now:  /usr/include/db.h 
> always refers to the latest installed db4, even if compat-db{,45,46} is 
> installed.  Our configure recipe links with the most recent db4 listed 
> in configure.ac, combined with the installed /usr/include/db.h.  Thus, 
> each new db4 version produces a mismatch.

I solicited suggestions on a blog, and someone asked why we don't
use db without specific version. I assumed we do it so we don't
get linked with something ancient like db3. Is that so? If yes,
how about something like this:

--- a/configure.ac
+++ b/configure.ac
@@ -76,13 +76,11 @@ dnl -----------------------------
 AC_CHECK_LIB(pcre, pcre_compile, PCRE_LIBS=-lpcre)
 AC_CHECK_LIB(crypto, MD5_Init, CRYPTO_LIBS=-lcrypto)
 AC_CHECK_LIB(ssl, SSL_new, SSL_LIBS=-lssl)
-AC_CHECK_LIB(db-4.8, db_create, DB4_LIBS=-ldb-4.8,
-       AC_CHECK_LIB(db-4.7, db_create, DB4_LIBS=-ldb-4.7,
-       AC_CHECK_LIB(db-4.6, db_create, DB4_LIBS=-ldb-4.6,
-       AC_CHECK_LIB(db-4.5, db_create, DB4_LIBS=-ldb-4.5,
-       AC_CHECK_LIB(db-4.4, db_create, DB4_LIBS=-ldb-4.4,
-       AC_CHECK_LIB(db-4.3, db_create, DB4_LIBS=-ldb-4.3,
-  [AC_MSG_ERROR([Missing required libdb 4.x])]))))))
+
+AC_CHECK_HEADERS([db.h], [], [AC_MSG_ERROR(Missing required db.h)])
+dnl We do not use sequence objects. It is a trick to force db4.3 or later.
+AC_CHECK_LIB(db, db_sequence_create, DB4_LIBS=-ldb)
+
 AC_CHECK_LIB(event, event_base_new, EVENT_LIBS=-levent,
   [AC_MSG_ERROR([Missing required libevent])])
 AC_CHECK_LIB(argp, argp_parse, ARGP_LIBS=-largp)

(URL http://zaitcev.livejournal.com/195586.html)

-- Pete
--
To unsubscribe from this list: send the line "unsubscribe hail-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Fedora Clound]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux