[m-dev.] diff: use AC_CHECK_LIB rather than AC_HAVE_LIBRARY

Fergus Henderson fjh at cs.mu.OZ.AU
Tue Oct 3 23:37:56 AEDT 2000


This diff addresses a review comment that someone (I forget who right
now) pointed out with regard to one of my previous changes.

----------

Estimated hours taken: 0.25

configure.in:
	Fix a problem in my previous fix for the `-lm' portability problem:
	we should use AC_CHECK_LIB rather than AC_HAVE_LIBRARY,
	since the latter is documented as being obsolete.

Workspace: /home/pgrad/fjh/ws/hg
Index: configure.in
===================================================================
RCS file: /home/mercury1/repository/mercury/configure.in,v
retrieving revision 1.228
diff -u -d -r1.228 configure.in
--- configure.in	2000/09/24 08:52:09	1.228
+++ configure.in	2000/09/26 05:28:14
@@ -224,7 +224,7 @@
 AC_RETSIGTYPE
 #-----------------------------------------------------------------------------#
 # Check for `-lm': some systems, e.g. MacOS X (Darwin), don't have it.
-AC_HAVE_LIBRARY(m,[MATH_LIB=-lm],[MATH_LIB=])
+AC_CHECK_LIB(m, sin, [MATH_LIB=-lm], [MATH_LIB=])
 AC_SUBST(MATH_LIB)
 #-----------------------------------------------------------------------------#
 AC_MSG_CHECKING(for use of a Microsoft compiler)

-- 
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.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list