This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Work around conflicting declarations of math functions


On 11/09/2015 05:24 PM, Joseph Myers wrote:
> On Mon, 9 Nov 2015, Florian Weimer wrote:
> 
>> On 11/05/2015 01:49 AM, Joseph Myers wrote:
>>> bits/math-finite.h declares -ffinite-math-only variants of various
>>> functions under conditions not matching those under which the normal
>>> versions are declared.
>>
>> Joseph,
>>
>> I may be seeing build failures related to this change, on armhfp (which
>> is, I think, ARMv7 with hardware floating point).  Specifically, this:
> 
> I think this comes from -D_Mlong_double_=double in math-CPPFLAGS, in which 
> case undefining _Mlong_double_ in test-signgam-finite-c99.c ought to allow 
> the test to build OK

I can confirm that the attached patch fixes the build issue on armhfp I
was seeing.  Thanks!

I need some help with the commit message, though.

Florian

Work around conflicting declarations of math functions

This restores compilation on architectures such as armhfp which
alias acos and acosl because double and long double are the same.

2015-11-09  Florian Weimer  <fweimer@redhat.com>

	* math/test-signgam-finite-c99.c (_Mlong_double_): Undefine.

diff --git a/math/test-signgam-finite-c99.c b/math/test-signgam-finite-c99.c
index fd9cdd3..bd3bdca 100644
--- a/math/test-signgam-finite-c99.c
+++ b/math/test-signgam-finite-c99.c
@@ -18,6 +18,7 @@
 
 #undef _LIBC
 #undef _GNU_SOURCE
+#undef _Mlong_double_
 #define _ISOMAC
 
 #include <math.h>

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]