diff options
-rw-r--r-- | configure.ac | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index f311419d892..1f84f167e86 100644 --- a/configure.ac +++ b/configure.ac @@ -535,10 +535,9 @@ AC_CHECK_FUNC([dlopen], [DEFINES="$DEFINES -DHAVE_DLOPEN"], AC_SUBST([DLOPEN_LIBS]) dnl Check if that library also has dladdr -save_LDFLAGS="$LDFLAGS" -LDFLAGS="$LDFLAGS $DLOPEN_LIBS" -AC_CHECK_FUNCS([dladdr]) -LDFLAGS="$save_LDFLAGS" +AC_CHECK_FUNC([dladdr], [DEFINES="$DEFINES -DHAVE_DLADDR"], + [AC_CHECK_LIB([dl], [dladdr], + [DEFINES="$DEFINES -DHAVE_DLADDR"])]) case "$host_os" in darwin*|mingw*) |