From 6c8149d7e17e4cbc70c3a777b746ac42fb3f8d5c Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Tue, 3 Apr 2012 04:44:59 +0200 Subject: New module 'logbf'. * lib/math.in.h (logbf): New declaration. * lib/logbf.c: New file. * m4/logbf.m4: New file. * m4/math_h.m4 (gl_MATH_H): Test whether logbf is declared. (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBF, HAVE_LOGBF, REPLACE_LOGBF. * modules/math (Makefile.am): Substitute GNULIB_LOGBF, HAVE_LOGBF, REPLACE_LOGBF. * modules/logbf: New file. * tests/test-math-c++.cc: Check the declaration of logbf. * doc/posix-functions/logbf.texi: Mention the new module. --- lib/math.in.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'lib/math.in.h') diff --git a/lib/math.in.h b/lib/math.in.h index 40983a9640..247c64417c 100644 --- a/lib/math.in.h +++ b/lib/math.in.h @@ -1388,6 +1388,29 @@ _GL_WARN_ON_USE (log2l, "log2l is unportable - " #endif +#if @GNULIB_LOGBF@ +# if @REPLACE_LOGBF@ +# if !(defined __cplusplus && defined GNULIB_NAMESPACE) +# undef logbf +# define logbf rpl_logbf +# endif +_GL_FUNCDECL_RPL (logbf, float, (float x)); +_GL_CXXALIAS_RPL (logbf, float, (float x)); +# else +# if !@HAVE_LOGBF@ +_GL_FUNCDECL_SYS (logbf, float, (float x)); +# endif +_GL_CXXALIAS_SYS (logbf, float, (float x)); +# endif +_GL_CXXALIASWARN (logbf); +#elif defined GNULIB_POSIXCHECK +# undef logbf +# if HAVE_RAW_DECL_LOGBF +_GL_WARN_ON_USE (logbf, "logbf is unportable - " + "use gnulib module logbf for portability"); +# endif +#endif + #if @GNULIB_LOGB@ # if @REPLACE_LOGB@ # if !(defined __cplusplus && defined GNULIB_NAMESPACE) -- cgit v1.2.1