From 51e17ea66608cfb85c2d5c6687df5fe83f191820 Mon Sep 17 00:00:00 2001 From: sebc Date: Sat, 17 Feb 2001 19:52:56 +0000 Subject: [PATCH] [project @ 2001-02-17 19:52:56 by sebc] Make LIBM be detected by autoconf. --- aclocal.m4 | 8 ++++---- configure.in | 4 ++++ ghc/utils/hp2ps/Makefile | 2 +- mk/config.mk.in | 3 +++ 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index a9d8e89..d62a3c5 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1,4 +1,4 @@ -dnl $Id: aclocal.m4,v 1.66 2001/01/30 11:13:26 simonmar Exp $ +dnl $Id: aclocal.m4,v 1.67 2001/02/17 19:52:56 sebc Exp $ dnl dnl Extra autoconf macros for the Glasgow fptools dnl @@ -861,7 +861,7 @@ dnl The variable LIBM (which is not an output variable by default) is dnl set to a value which is suitable for use in a Makefile (for example, dnl in make's LOADLIBES macro) provided you AC_SUBST it first. dnl -dnl @version 0.01 $Id: aclocal.m4,v 1.66 2001/01/30 11:13:26 simonmar Exp $ +dnl @version 0.01 $Id: aclocal.m4,v 1.67 2001/02/17 19:52:56 sebc Exp $ dnl @author Matthew D. Langston # FPTOOLS_CHECK_LIBM - check for math library @@ -869,7 +869,7 @@ AC_DEFUN(FPTOOLS_CHECK_LIBM, [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case "$host" in -*-*-beos* | *-*-cygwin*) +*-*-beos* | *-*-macosx*) # These system don't have libm ;; *-ncr-sysv4.3*) @@ -949,7 +949,7 @@ dnl Please note that as the ac_opengl macro and the toy example evolves, dnl the version number increases, so you may have to adjust the above dnl URL accordingly. dnl -dnl @version 0.01 $Id: aclocal.m4,v 1.66 2001/01/30 11:13:26 simonmar Exp $ +dnl @version 0.01 $Id: aclocal.m4,v 1.67 2001/02/17 19:52:56 sebc Exp $ dnl @author Matthew D. Langston AC_DEFUN(FPTOOLS_HAVE_OPENGL, diff --git a/configure.in b/configure.in index dbfe119..b852836 100644 --- a/configure.in +++ b/configure.in @@ -842,6 +842,10 @@ else fi AC_SUBST(LibsReadline) +dnl ** check for math library +FPTOOLS_CHECK_LIBM() +AC_SUBST(LIBM) + dnl ################################################################ dnl Check for libraries dnl ################################################################ diff --git a/ghc/utils/hp2ps/Makefile b/ghc/utils/hp2ps/Makefile index 521c2a8..5e11ed0 100644 --- a/ghc/utils/hp2ps/Makefile +++ b/ghc/utils/hp2ps/Makefile @@ -8,7 +8,7 @@ C_PROG = hp2ps INSTALL_PROGS += $(C_PROG) SRC_CC_OPTS += -O -LIBS = -lm +LIBS = $(LIBM) CLEAN_FILES += $(C_OBJS) $(C_PROG) diff --git a/mk/config.mk.in b/mk/config.mk.in index efb315b..b3f63e9 100644 --- a/mk/config.mk.in +++ b/mk/config.mk.in @@ -290,6 +290,9 @@ GhcLibsWithReadline=@HaveReadlineHeaders@ # Libraries needed for linking with readline LibsReadline=@LibsReadline@ +# Math library +LIBM=@LIBM@ + # Include path to readline.h # (no path == in standard include path) # -- 1.7.10.4