>From ef458c87188265ccd056376432f4a84ad4e965ad Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sat, 17 Dec 2016 20:32:14 +0100 Subject: [PATCH 13/20] log10l: Avoid redefinition error on MSVC. * m4/log10l.m4 (gl_FUNC_LOG10L): Set REPLACE_LOG10L to 1 if the function may be defined as an inline function. --- ChangeLog | 6 ++++++ m4/log10l.m4 | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 61b04bf..7886bd9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2016-12-17 Bruno Haible + log10l: Avoid redefinition error on MSVC. + * m4/log10l.m4 (gl_FUNC_LOG10L): Set REPLACE_LOG10L to 1 if the function + may be defined as an inline function. + +2016-12-17 Bruno Haible + log10f: Avoid redefinition error on MSVC. * m4/log10f.m4 (gl_FUNC_LOG10F): Set REPLACE_LOG10F to 1 if the function may be defined as an inline function. diff --git a/m4/log10l.m4 b/m4/log10l.m4 index 8ea35a7..a31f5cf 100644 --- a/m4/log10l.m4 +++ b/m4/log10l.m4 @@ -1,4 +1,4 @@ -# log10l.m4 serial 3 +# log10l.m4 serial 4 dnl Copyright (C) 2011-2016 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -35,6 +35,10 @@ AC_DEFUN([gl_FUNC_LOG10L], esac else HAVE_LOG10L=0 + dnl If the function is declared but does not appear to exist, it may be + dnl defined as an inline function. In order to avoid a conflict, we have + dnl to define rpl_log10l, not log10l. + AC_CHECK_DECLS([log10l], [REPLACE_LOG10L=1], , [[#include ]]) fi if test $HAVE_LOG10L = 0 || test $REPLACE_LOG10L = 1; then if test $HAVE_SAME_LONG_DOUBLE_AS_DOUBLE = 1; then -- 2.6.4