[PATCH 04/12] configure: Use AC_CHECK_LIB() to find libdl
Philip Withnall
philip at tecnocode.co.uk
Fri Feb 15 04:56:39 PST 2013
This is necessary on FreeBSD.
Signed-off-by: Philip Withnall <philip at tecnocode.co.uk>
---
configure.ac | 4 ++++
tests/Makefile.am | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 3ad39ab..35b89c8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -52,6 +52,10 @@ AC_CHECK_HEADERS([sys/signalfd.h sys/timerfd.h])
# Credential support on FreeBSD.
AC_CHECK_HEADERS([sys/ucred.h])
+# dlopen()
+AC_CHECK_LIB([dl], [dlsym], [DL_LIBS=-ldl])
+AC_SUBST([DL_LIBS])
+
AC_ARG_ENABLE([scanner],
[AC_HELP_STRING([--disable-scanner],
[Disable compilation of wayland-scanner])],
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 54157bc..604996a 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -45,7 +45,7 @@ AM_CFLAGS = $(GCC_CFLAGS) $(FFI_CFLAGS)
LDADD = $(top_builddir)/src/libwayland-util.la \
$(top_builddir)/src/libwayland-client.la \
$(top_builddir)/src/libwayland-server.la \
- -lrt -ldl $(FFI_LIBS)
+ -lrt $(DL_LIBS) $(FFI_LIBS)
exec_fd_leak_checker_SOURCES = \
exec-fd-leak-checker.c \
--
1.7.11.7
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 230 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20130215/2eae0a26/attachment.pgp>
More information about the wayland-devel
mailing list