[glom] Check of libdl instead of unconditionally linking with it.
- From: Jasper Lievisse Adriaanse <jasperla src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glom] Check of libdl instead of unconditionally linking with it.
- Date: Wed, 19 Oct 2011 21:14:10 +0000 (UTC)
commit b8693a503ac0bae9cf7d3feca3a99a8d121bacf5
Author: Jasper Lievisse Adriaanse <jasper humppa nl>
Date: Wed Oct 19 14:23:17 2011 +0200
Check of libdl instead of unconditionally linking with it.
https://bugzilla.gnome.org/show_bug.cgi?id=662143
ChangeLog | 8 ++++++++
Makefile_tests.am | 2 +-
configure.ac | 4 ++++
3 files changed, 13 insertions(+), 1 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index affbe1f..b5791d5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
1.19.15:
+2011-10-19 Jasper Lievisse Adriaanse <jasperla gnome org>
+
+ Don't unconditionally link with libdl to fix regress tests on
+ systems which don't need to link with -ldl for dlopen() etc.
+
+ * configure.ac:
+ * Makefile_tests.am: Check for -libdl.
+
2011-10-19 Murray Cumming <murrayc murrayc com>
SQL Injection Test: Try both kinds of quote characters.
diff --git a/Makefile_tests.am b/Makefile_tests.am
index 7a317af..3e4d428 100644
--- a/Makefile_tests.am
+++ b/Makefile_tests.am
@@ -90,7 +90,7 @@ tests_test_signal_reemit_LDADD = $(LIBGLOM_LIBS)
tests_test_signal_reemit_CPPFLAGS = $(tests_cppflags)
tests_python_test_load_python_library_SOURCES = tests/python/test_load_python_library.cc
-tests_python_test_load_python_library_LDADD = $(LIBGLOM_LIBS) -ldl
+tests_python_test_load_python_library_LDADD = $(LIBGLOM_LIBS) $(DL_LIB)
tests_python_test_load_python_library_CPPFLAGS = $(tests_cppflags)
tests_python_test_python_module_SOURCES = tests/python/test_python_module.cc
diff --git a/configure.ac b/configure.ac
index 767d80c..31dea26 100644
--- a/configure.ac
+++ b/configure.ac
@@ -69,6 +69,10 @@ AM_GNU_GETTEXT_VERSION([0.17])
AC_SUBST([GETTEXT_PACKAGE], [glom])
AC_DEFINE([GETTEXT_PACKAGE], [PACKAGE_TARNAME], [Define to the gettext package name.])
+# Linking with libdl isn't needed on various non-Linux platforms,
+# eventhough they do provide dlopen(3).
+AC_CHECK_LIB([dl], [dlopen], DL_LIB="-ldl")
+
AC_MSG_CHECKING([whether to enable Windows specific options])
AS_CASE([$host_os], [mingw*], [glom_host_win32=yes], [glom_host_win32=no])
AC_MSG_RESULT([$glom_host_win32])
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]