diff: fix bug in config test for dlopen

Fergus Henderson fjh at cs.mu.OZ.AU
Fri Mar 26 05:44:59 AEDT 1999


Estimated hours taken: 0.25

configure.in:
	Fix a bug with the test for dynamic loading support: it wasn't
	linking in -ldl when it was testing for dlopen() etc.

Index: configure.in
===================================================================
RCS file: /home/staff/zs/imp/mercury/configure.in,v
retrieving revision 1.154
diff -u -r1.154 configure.in
--- configure.in	1999/03/25 17:46:59	1.154
+++ configure.in	1999/03/25 18:34:06
@@ -247,7 +247,15 @@
 fi
 AC_CHECK_LIB(dl,dlopen,DL_LIBRARY="-ldl",DL_LIBRARY="")
 AC_SUBST(DL_LIBRARY)
+
+# temporarily add $DL_LIBRARY to LIBS while we check for dlopen etc.
+save_LIBS="$LIBS"
+LIBS="$LIBS $DL_LIBRARY"
+
 AC_HAVE_FUNCS(dlopen dlclose dlsym dlerror)
+
+# restore old value of LIBS
+LIBS="$save_LIBS"
 #-----------------------------------------------------------------------------#
 #
 # check the basics of sigaction

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh>  |  of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3        |     -- the last words of T. S. Garp.



More information about the developers mailing list