From a2e1dc0cce3f5c4b94123a5fd4de42ecc988ab14 Mon Sep 17 00:00:00 2001 From: Jon TURNEY Date: Fri, 8 Aug 2014 20:13:18 +0100 Subject: [PATCH] configure.ac: Use LIBS rather than LDFLAGS to add -ldl to dladdr check MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit ec8ebff "Check for dladdr()" erroneously uses LDFLAGS rather than LIBS to add -ldl to the dladdr check. Replace the workaround in 39a4cc4 of explicitly checking in libdl, with a more correct approach of using LIBS. Signed-off-by: Jon TURNEY Reviewed-by: Emil Velikov Tested-by: Pali Rohár Cc: "10.2" --- configure.ac | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index 818536c04a2..e8dd502977c 100644 --- a/configure.ac +++ b/configure.ac @@ -535,9 +535,10 @@ AC_CHECK_FUNC([dlopen], [DEFINES="$DEFINES -DHAVE_DLOPEN"], AC_SUBST([DLOPEN_LIBS]) dnl Check if that library also has dladdr -AC_CHECK_FUNC([dladdr], [DEFINES="$DEFINES -DHAVE_DLADDR"], - [AC_CHECK_LIB([dl], [dladdr], - [DEFINES="$DEFINES -DHAVE_DLADDR"])]) +save_LIBS="$LIBS" +LIBS="$LIBS $DLOPEN_LIBS" +AC_CHECK_FUNCS([dladdr]) +LIBS="$save_LIBS" case "$host_os" in darwin*|mingw*) -- 2.30.2