diff options
author | Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> | 2016-11-21 16:09:47 +0000 |
---|---|---|
committer | Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> | 2016-11-21 16:09:47 +0000 |
commit | da2427670800303d2b062f3e1b72d079423d1357 (patch) | |
tree | 8f502695fd5b7d4aade9b6b924f17b355a3f0403 /fixincludes/fixincl.x | |
parent | be54ffa3fc8f854d4fcd1fdd01b673b002d72724 (diff) |
Don't define libstdc++-internal macros in Solaris 10+ <math.h>
libstdc++-v3:
* acinclude.m4 (GLIBCXX_CHECK_MATH11_PROTO): Update comments.
(__CORRECT_ISO_CPP11_MATH_H_PROTO): Rename to ...
(__CORRECT_ISO_CPP11_MATH_H_PROTO_FP): ... this.
Add test for C++11 <math.h> integral overloads.
* configure: Regenerate.
* config.h.in: Regenerate.
* include/c_global/cmath [__cplusplus >= 201103L]: Reflect
__CORRECT_ISO_CPP11_MATH_H_PROTO to
__CORRECT_ISO_CPP11_MATH_H_PROTO_FP rename.
* include/c_global/cmath [_GLIBCXX_USE_C99_MATH &&
!_GLIBCXX_USE_C99_FP_MACROS_DYNAMIC && __cplusplus >= 201103L]
(std::fpclassify): Wrap in !__CORRECT_ISO_CPP11_MATH_H_PROTO_INT.
(std::isfinite): Likewise.
(std::isinf): Likewise.
(std::isnan): Likewise.
(std::isnormal): Likewise.
(std::signbit): Likewise.
(std::isgreater): Likewise.
(std::isgreaterequal): Likewise.
(std::isless): Likewise.
(std::islessequal): Likewise.
(std::islessgreater): Likewise.
(std::isunordered): Likewise.
[__cplusplus >= 201103L && _GLIBCXX_USE_C99_MATH_TR1]
(std::acosh): Likewise.
(std::asinh): Likewise.
(std::atanh): Likewise.
(std::cbrt): Likewise.
(std::copysign): Likewise.
(std::erf): Likewise.
(std::erfc): Likewise.
(std::exp2): Likewise.
(std::expm1): Likewise.
(std::fdim): Likewise.
(std::fma): Likewise.
(std::fmax): Likewise.
(std::fmin): Likewise.
(std::hypot): Likewise.
(std::ilogb): Likewise.
(std::lgamma): Likewise.
(std::llrint): Likewise.
(std::llround): Likewise.
(std::log1p): Likewise.
(std::log2): Likewise.
(std::logb): Likewise.
(std::lrint): Likewise.
(std::lround): Likewise.
(std::nearbyint): Likewise.
(std::nextafter): Likewise.
(std::nexttoward): Likewise.
(std::remainder): Likewise.
(std::remquo): Likewise.
(std::rint): Likewise.
(std::round): Likewise.
(std::scalbln): Likewise.
(std::scalbn): Likewise.
(std::tgamma): Likewise.
(std::trunc): Likewise.
* include/tr1/cmath [_GLIBCXX_USE_C99_MATH_TR1 && __cplusplus >=
201103L]: Reflect __CORRECT_ISO_CPP11_MATH_H_PROTO to
__CORRECT_ISO_CPP11_MATH_H_PROTO_FP rename.
fixincludes:
* inclhack.def (solaris_math_12): New fix.
(hpux11_fabsf): Replace bypass by *-hp-hpux11* mach selector.
* fixincl.x: Regenerate.
* tests/base/math.h [SOLARIS_MATH_12_CHECK]: New test.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@242671 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'fixincludes/fixincl.x')
-rw-r--r-- | fixincludes/fixincl.x | 63 |
1 files changed, 50 insertions, 13 deletions
diff --git a/fixincludes/fixincl.x b/fixincludes/fixincl.x index 00d03be8ffe..b0eeef9dfdf 100644 --- a/fixincludes/fixincl.x +++ b/fixincludes/fixincl.x @@ -2,11 +2,11 @@ * * DO NOT EDIT THIS FILE (fixincl.x) * - * It has been AutoGen-ed November 20, 2016 at 11:44:36 AM by AutoGen 5.16.2 + * It has been AutoGen-ed November 20, 2016 at 12:02:46 PM by AutoGen 5.16.2 * From the definitions inclhack.def * and the template file fixincl */ -/* DO NOT SVN-MERGE THIS FILE, EITHER Sun Nov 20 11:44:37 MET 2016 +/* DO NOT SVN-MERGE THIS FILE, EITHER Sun Nov 20 12:02:47 MET 2016 * * You must regenerate it. Use the ./genfixes script. * @@ -15,7 +15,7 @@ * certain ANSI-incompatible system header files which are fixed to work * correctly with ANSI C and placed in a directory that GNU C will search. * - * This file contains 241 fixup descriptions. + * This file contains 242 fixup descriptions. * * See README for more information. * @@ -4507,7 +4507,9 @@ tSCC zHpux11_FabsfList[] = /* * Machine/OS name selection pattern */ -#define apzHpux11_FabsfMachs (const char**)NULL +tSCC* apzHpux11_FabsfMachs[] = { + "*-hp-hpux11*", + (const char*)NULL }; /* * content selection pattern - do fix if pattern found @@ -4515,15 +4517,8 @@ tSCC zHpux11_FabsfList[] = tSCC zHpux11_FabsfSelect0[] = "^[ \t]*#[ \t]*define[ \t]+fabsf\\(.*"; -/* - * content bypass pattern - skip fix if pattern found - */ -tSCC zHpux11_FabsfBypass0[] = - "__cplusplus"; - -#define HPUX11_FABSF_TEST_CT 2 +#define HPUX11_FABSF_TEST_CT 1 static tTestDesc aHpux11_FabsfTests[] = { - { TT_NEGREP, zHpux11_FabsfBypass0, (regex_t*)NULL }, { TT_EGREP, zHpux11_FabsfSelect0, (regex_t*)NULL }, }; /* @@ -7583,6 +7578,42 @@ static const char* apzSolaris_Math_11Patch[] = { /* * * * * * * * * * * * * * * * * * * * * * * * * * * + * Description of Solaris_Math_12 fix + */ +tSCC zSolaris_Math_12Name[] = + "solaris_math_12"; + +/* + * File name selection pattern + */ +tSCC zSolaris_Math_12List[] = + "math.h\0"; +/* + * Machine/OS name selection pattern + */ +tSCC* apzSolaris_Math_12Machs[] = { + "*-*-solaris2*", + (const char*)NULL }; + +/* + * content selection pattern - do fix if pattern found + */ +tSCC zSolaris_Math_12Select0[] = + "#undef.*_GLIBCXX_USE_C99_MATH"; + +#define SOLARIS_MATH_12_TEST_CT 1 +static tTestDesc aSolaris_Math_12Tests[] = { + { TT_EGREP, zSolaris_Math_12Select0, (regex_t*)NULL }, }; + +/* + * Fix Command Arguments for Solaris_Math_12 + */ +static const char* apzSolaris_Math_12Patch[] = { sed_cmd_z, + "-e", "/#undef[ \t]*_GLIBCXX_USE_C99_MATH/d", + (char*)NULL }; + +/* * * * * * * * * * * * * * * * * * * * * * * * * * + * * Description of Solaris_Once_Init_1 fix */ tSCC zSolaris_Once_Init_1Name[] = @@ -9879,7 +9910,7 @@ static const char* apzX11_SprintfPatch[] = { */ #define REGEX_COUNT 279 #define MACH_LIST_SIZE_LIMIT 187 -#define FIX_COUNT 241 +#define FIX_COUNT 242 /* * Enumerate the fixes @@ -10068,6 +10099,7 @@ typedef enum { SOLARIS_MATH_8_FIXIDX, SOLARIS_MATH_9_FIXIDX, SOLARIS_MATH_11_FIXIDX, + SOLARIS_MATH_12_FIXIDX, SOLARIS_ONCE_INIT_1_FIXIDX, SOLARIS_POSIX_SPAWN_RESTRICT_FIXIDX, SOLARIS_POW_INT_OVERLOAD_FIXIDX, @@ -11044,6 +11076,11 @@ tFixDesc fixDescList[ FIX_COUNT ] = { SOLARIS_MATH_11_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE, aSolaris_Math_11Tests, apzSolaris_Math_11Patch, 0 }, + { zSolaris_Math_12Name, zSolaris_Math_12List, + apzSolaris_Math_12Machs, + SOLARIS_MATH_12_TEST_CT, FD_MACH_ONLY, + aSolaris_Math_12Tests, apzSolaris_Math_12Patch, 0 }, + { zSolaris_Once_Init_1Name, zSolaris_Once_Init_1List, apzSolaris_Once_Init_1Machs, SOLARIS_ONCE_INIT_1_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE, |