summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2012-04-01 14:29:37 +0200
committerBruno Haible <bruno@clisp.org>2012-04-01 16:37:09 +0200
commitac05a13b444792260deaadfeb15f5c137ba9072b (patch)
tree8072d6ce2006718c8d06a15574dedf1469c4d5ac /modules
parent54be6af60f46a82b2d9051cd939169cd288ed52c (diff)
downloadgnulib-ac05a13b444792260deaadfeb15f5c137ba9072b.tar.gz
log10f: Work around OSF/1 5.1 bug.
* lib/math.in.h (log10f): Override if REPLACE_LOG10F is 1. * lib/log10f.c (log10f): If logf exists, use it and provide just the workaround. * m4/log10f.m4 (gl_FUNC_LOG10F_WORKS): New macro. (gl_FUNC_LOG10F): Invoke it. Set REPLACE_LOG10F. * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG10F. * modules/math (Makefile.am): Substitute REPLACE_LOG10F. * modules/log10f (configure.ac): Consider REPLACE_LOG10F. (Depends-on): Update conditions. * doc/posix-functions/log10f.texi: Mention the OSF/1 5.1 problem.
Diffstat (limited to 'modules')
-rw-r--r--modules/log10f4
-rw-r--r--modules/math1
2 files changed, 3 insertions, 2 deletions
diff --git a/modules/log10f b/modules/log10f
index abcbaa64aa..5826be9f0b 100644
--- a/modules/log10f
+++ b/modules/log10f
@@ -8,11 +8,11 @@ m4/log10f.m4
Depends-on:
math
extensions
-log10 [test $HAVE_LOG10F = 0]
+log10 [test $HAVE_LOG10F = 0 || test $REPLACE_LOG10F = 1]
configure.ac:
gl_FUNC_LOG10F
-if test $HAVE_LOG10F = 0; then
+if test $HAVE_LOG10F = 0 || test $REPLACE_LOG10F = 1; then
AC_LIBOBJ([log10f])
fi
gl_MATH_MODULE_INDICATOR([log10f])
diff --git a/modules/math b/modules/math
index ceb77884af..cb81a7dd41 100644
--- a/modules/math
+++ b/modules/math
@@ -246,6 +246,7 @@ math.h: math.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H) $(
-e 's|@''REPLACE_LOGF''@|$(REPLACE_LOGF)|g' \
-e 's|@''REPLACE_LOGL''@|$(REPLACE_LOGL)|g' \
-e 's|@''REPLACE_LOG10''@|$(REPLACE_LOG10)|g' \
+ -e 's|@''REPLACE_LOG10F''@|$(REPLACE_LOG10F)|g' \
-e 's|@''REPLACE_LOG1P''@|$(REPLACE_LOG1P)|g' \
-e 's|@''REPLACE_LOG1PF''@|$(REPLACE_LOG1PF)|g' \
-e 's|@''REPLACE_LOG1PL''@|$(REPLACE_LOG1PL)|g' \