From: Tom Tromey Date: Fri, 4 Oct 1996 08:17:46 +0000 (+0000) Subject: Don't require -lm everywhere X-Git-Tag: Release-1-1f~8 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=04f3aeab9117f6dcdebaf458a5ef45b8440246a3;p=automake.git Don't require -lm everywhere --- diff --git a/m4/AM_FUNC_STRTOD.m4 b/m4/AM_FUNC_STRTOD.m4 index cb6e0887..d9e00857 100644 --- a/m4/AM_FUNC_STRTOD.m4 +++ b/m4/AM_FUNC_STRTOD.m4 @@ -1,14 +1,31 @@ -dnl From Jim Meyering. +## Copyright (C) 1996 Free Software Foundation, Inc. -# serial 1 +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2, or (at your option) +## any later version. -# @defmac AC_FUNC_STRTOD -# @maindex FUNC_STRTOD -# @ovindex LIBOBJS -# If the @code{strtod} function is not available, or does not work -# correctly (like the one on SunOS 5.4), add @samp{strtod.o} to output -# variable @code{LIBOBJS}. -# @end defmac +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. + +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA +## 02111-1307, USA. + +## From Jim Meyering. + +## serial 1 + +## @defmac AC_FUNC_STRTOD +## @maindex FUNC_STRTOD +## @ovindex LIBOBJS +## If the @code{strtod} function is not available, or does not work +## correctly (like the one on SunOS 5.4), add @samp{strtod.o} to output +## variable @code{LIBOBJS}. +## @end defmac AC_DEFUN(AM_FUNC_STRTOD, [AC_CACHE_CHECK(for working strtod, am_cv_func_strtod, @@ -41,10 +58,12 @@ main() ], am_cv_func_strtod=yes, am_cv_func_strtod=no, am_cv_func_strtod=no)]) test $am_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o" AC_SUBST(LIBOBJS)dnl +am_cv_func_strtod_needs_libm=no if test $am_cv_func_strtod = no; then AC_CHECK_FUNCS(pow) if test $am_cv_func_pow = no; then - AC_CHECK_LIB(m, pow) + AC_CHECK_LIB(m, pow, [am_cv_func_strtod_needs_libm=yes], + [AC_MSG_WARN(can't find library containing definition of pow)]) fi fi ])