7b0c243e70
Fix bug in -ldl check on NetBSD
25 lines
552 B
Text
25 lines
552 B
Text
$NetBSD: patch-aa,v 1.3 2007/06/02 19:18:51 airhead Exp $
|
|
|
|
--- configure.in.orig 2007-03-27 20:11:57.000000000 +0200
|
|
+++ configure.in
|
|
@@ -92,7 +92,19 @@ AC_TRY_LINK(,
|
|
LDL=-ldld
|
|
AC_DEFINE(HAVE_SHL_LOAD, 1, [ Define if we have shl_load() ]),
|
|
AC_MSG_RESULT(no);
|
|
- LDL=-ldl
|
|
+ LDL=
|
|
+ LIBS=$olibs)
|
|
+
|
|
+AC_MSG_CHECKING([for dlopen() in -ldl])
|
|
+olibs=$LIBS
|
|
+LIBS="$LIBS -ldl"
|
|
+AC_TRY_LINK(,
|
|
+ [ extern void* dlopen(); dlopen(); ],
|
|
+ AC_MSG_RESULT(yes);
|
|
+ LIBS=$olibs;
|
|
+ LDL=-ldl,
|
|
+ AC_MSG_RESULT(no);
|
|
+ LDL=
|
|
LIBS=$olibs)
|
|
|
|
AC_SUBST(LDL)
|