diff lib/math.in.h @ 16755:5320f2305736

New module 'logbl'. * lib/math.in.h (logbl): New declaration. * lib/logbl.c: New file. * m4/logbl.m4: New file. * m4/math_h.m4 (gl_MATH_H): Test whether logbl is declared. (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBL, HAVE_LOGBL, REPLACE_LOGBL. * modules/math (Makefile.am): Substitute GNULIB_LOGBL, HAVE_LOGBL, REPLACE_LOGBL. * modules/logbl: New file. * tests/test-math-c++.cc: Check the declaration of logbl. * doc/posix-functions/logbl.texi: Mention the new module.
author Bruno Haible <bruno@clisp.org>
date Tue, 03 Apr 2012 12:53:31 +0200
parents 0f9a8ebc12c1
children a56cad559c24
line wrap: on
line diff
--- a/lib/math.in.h
+++ b/lib/math.in.h
@@ -1434,6 +1434,29 @@
 # endif
 #endif
 
+#if @GNULIB_LOGBL@
+# if @REPLACE_LOGBL@
+#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
+#   undef logbl
+#   define logbl rpl_logbl
+#  endif
+_GL_FUNCDECL_RPL (logbl, long double, (long double x));
+_GL_CXXALIAS_RPL (logbl, long double, (long double x));
+# else
+#  if !@HAVE_LOGBL@
+_GL_FUNCDECL_SYS (logbl, long double, (long double x));
+#  endif
+_GL_CXXALIAS_SYS (logbl, long double, (long double x));
+# endif
+_GL_CXXALIASWARN (logbl);
+#elif defined GNULIB_POSIXCHECK
+# undef logbl
+# if HAVE_RAW_DECL_LOGBL
+_GL_WARN_ON_USE (logbl, "logbl is unportable - "
+                 "use gnulib module logbl for portability");
+# endif
+#endif
+
 
 #if @GNULIB_MODFF@
 # if @REPLACE_MODFF@