summaryrefslogtreecommitdiff
path: root/lib/logbf.c
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2012-04-03 04:44:59 +0200
committerBruno Haible <bruno@clisp.org>2012-04-03 14:01:40 +0200
commit6c8149d7e17e4cbc70c3a777b746ac42fb3f8d5c (patch)
tree5c89c9003ee5e6f92a3e6e1366d6b8089c122a38 /lib/logbf.c
parent36d2768bd34a963cf2b4604e3f54d904ed9f17dd (diff)
downloadgnulib-6c8149d7e17e4cbc70c3a777b746ac42fb3f8d5c.tar.gz
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.
Diffstat (limited to 'lib/logbf.c')
-rw-r--r--lib/logbf.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/lib/logbf.c b/lib/logbf.c
new file mode 100644
index 0000000000..910d652d61
--- /dev/null
+++ b/lib/logbf.c
@@ -0,0 +1,23 @@
+/* Floating-point exponent.
+ Copyright (C) 2012 Free Software Foundation, Inc.
+
+ 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 3 of the License, or
+ (at your option) any later version.
+
+ 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, see <http://www.gnu.org/licenses/>. */
+
+#include <config.h>
+
+/* Specification. */
+#include <math.h>
+
+#define USE_FLOAT
+#include "logb.c"