From mboxrd@z Thu Jan 1 00:00:00 1970 From: gsl-discuss@lists.thewrittenword.com To: gsl-discuss@sources.redhat.com Subject: HP-UX 11.00 patches for 0.9.3 Date: Wed, 19 Dec 2001 13:20:00 -0000 Message-id: <20011002180626.A90748@oolong.il.thewrittenword.com> X-SW-Source: 2001/msg00549.html HP-UX 11.00 has isinf() and isfinite() as a macro in . Also replaced the OS/2 hack with something hopefully better (untested). BTW, any plans to upgrade to autoconf 2.5x? -- albert chin (china@thewrittenword.com) -- snip snip --- acconfig.h.orig Tue Oct 2 10:56:05 2001 +++ acconfig.h Tue Oct 2 11:01:05 2001 @@ -108,7 +108,11 @@ #endif #ifndef HAVE_FINITE +#ifdef HAVE_ISFINITE +#define finite isfinite +#else #define finite gsl_finite +#endif #endif #ifdef __GNUC__ --- configure.in.orig Tue Oct 2 09:16:59 2001 +++ configure.in Tue Oct 2 12:14:33 2001 @@ -5,7 +5,6 @@ AM_CONFIG_HEADER(config.h) dnl things required by automake -AC_ARG_PROGRAM AC_PROG_MAKE_SET dnl Check for which system. @@ -106,19 +105,28 @@ AC_CHECK_FUNCS(acosh) AC_CHECK_FUNCS(asinh) AC_CHECK_FUNCS(atanh) -AC_CHECK_FUNCS(isinf) -AC_CHECK_FUNCS(finite) -case "$host" in - *-*-os2_emx) - AC_MSG_RESULT([os/2 assuming isnan is a macro]) - AC_DEFINE(HAVE_ISNAN,1) - AC_SUBST(HAVE_ISNAN) - ;; - *) - AC_CHECK_FUNCS(isnan) - ;; -esac +AC_CHECK_FUNCS(isinf, ,[ + AC_MSG_CHECKING([for isinf with ]) + AC_TRY_LINK([#include ], [float f = 0.0; isinf(f)],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_ISINF)], + AC_MSG_RESULT(no))]) + +AC_CHECK_FUNCS(finite, ,[ + AC_CHECK_FUNCS(isfinite, ,[ + AC_MSG_CHECKING([for isfinite with ]) + AC_TRY_LINK([#include ], [float f = 0.0; isfinite(f)],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_ISFINITE)], + AC_MSG_RESULT(no))])]) + +AC_CHECK_FUNCS(isnan, ,[ + AC_MSG_CHECKING([for isnan with ]) + AC_TRY_LINK([#include ], [float f = 0.0; isnan(f)],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_ISNAN)], + AC_MSG_RESULT(no))]) dnl OpenBSD has a broken implementation of log1p. case "$host" in