aboutsummaryrefslogtreecommitdiff
path: root/dlfcn/sdladdr.c
diff options
context:
space:
mode:
authorRomain Naour <romain.naour@gmail.com>2017-10-16 23:21:56 +0200
committerGabriel F. T. Gomes <gabriel@inconstante.eti.br>2017-10-17 12:06:44 -0200
commit386e1c26ac473d6863133ab9cbe3bbda16c15816 (patch)
tree7c645ee0d6c11960740cd05edbcd840db4eae6ea /dlfcn/sdladdr.c
parent3d265601358974c9be8264e53dadd8f9aea5690c (diff)
downloadglibc-386e1c26ac473d6863133ab9cbe3bbda16c15816.zip
glibc-386e1c26ac473d6863133ab9cbe3bbda16c15816.tar.gz
glibc-386e1c26ac473d6863133ab9cbe3bbda16c15816.tar.bz2
Let signbit use the builtin in C++ mode with gcc < 6.x (bug 22296)
When using gcc < 6.x, signbit does not use the type-generic __builtin_signbit builtin, instead it uses __MATH_TG. However, when library support for float128 is available, __MATH_TG uses __builtin_types_compatible_p, which is not available in C++ mode. On the other hand, libstdc++ undefines (in cmath) many macros from math.h, including signbit, so that it can provide its own functions. However, during its configure tests, libstdc++ just tests for the availability of the macros (it does not undefine them, nor does it provide its own functions). Finally, libstdc++ configure tests include math.h and get the definition of signbit that uses __MATH_TG (and __builtin_types_compatible_p). Since libstdc++ does not undefine the macros during its configure tests, they fail. This patch lets signbit use the builtin in C++ mode when gcc < 6.x is used. This allows the configure test in libstdc++ to work. Tested for x86_64. [BZ #22296] * math/math.h: Let signbit use the builtin in C++ mode with gcc < 6.x Cc: Gabriel F. T. Gomes <gftg@linux.vnet.ibm.com> Cc: Joseph Myers <joseph@codesourcery.com>
Diffstat (limited to 'dlfcn/sdladdr.c')
0 files changed, 0 insertions, 0 deletions