From d08c2e8e026990a66a798d52b375cdd4c683f91f Mon Sep 17 00:00:00 2001 From: Szabolcs Nagy Date: Sun, 6 Nov 2016 20:16:09 +0000 Subject: [PATCH] fix gcc-5.* build with a recent gcc https://gcc.gnu.org/ml/gcc-patches/2016-01/msg00044.html --- patches/gcc-5.2.0/0010-cfns-inline-fix.diff | 24 +++++++++++++++++++++ patches/gcc-5.3.0/0010-cfns-inline-fix.diff | 24 +++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 patches/gcc-5.2.0/0010-cfns-inline-fix.diff create mode 100644 patches/gcc-5.3.0/0010-cfns-inline-fix.diff diff --git a/patches/gcc-5.2.0/0010-cfns-inline-fix.diff b/patches/gcc-5.2.0/0010-cfns-inline-fix.diff new file mode 100644 index 0000000..8f21223 --- /dev/null +++ b/patches/gcc-5.2.0/0010-cfns-inline-fix.diff @@ -0,0 +1,24 @@ +diff --git a/gcc/cp/cfns.h b/gcc/cp/cfns.h +index 1c6665d..69699c4 100644 +--- a/gcc/cp/cfns.h ++++ b/gcc/cp/cfns.h +@@ -54,6 +54,7 @@ static unsigned int hash (const char *, unsigned int); + #ifdef __GNUC__ + __inline + #endif ++static + const char * libc_name_p (const char *, unsigned int); + /* maximum key range = 391, duplicates = 0 */ + +@@ -124,10 +125,8 @@ hash (register const char *str, register unsigned int len) + + #ifdef __GNUC__ + __inline +-#ifdef __GNUC_STDC_INLINE__ +-__attribute__ ((__gnu_inline__)) +-#endif + #endif ++static + const char * + libc_name_p (register const char *str, register unsigned int len) + { diff --git a/patches/gcc-5.3.0/0010-cfns-inline-fix.diff b/patches/gcc-5.3.0/0010-cfns-inline-fix.diff new file mode 100644 index 0000000..8f21223 --- /dev/null +++ b/patches/gcc-5.3.0/0010-cfns-inline-fix.diff @@ -0,0 +1,24 @@ +diff --git a/gcc/cp/cfns.h b/gcc/cp/cfns.h +index 1c6665d..69699c4 100644 +--- a/gcc/cp/cfns.h ++++ b/gcc/cp/cfns.h +@@ -54,6 +54,7 @@ static unsigned int hash (const char *, unsigned int); + #ifdef __GNUC__ + __inline + #endif ++static + const char * libc_name_p (const char *, unsigned int); + /* maximum key range = 391, duplicates = 0 */ + +@@ -124,10 +125,8 @@ hash (register const char *str, register unsigned int len) + + #ifdef __GNUC__ + __inline +-#ifdef __GNUC_STDC_INLINE__ +-__attribute__ ((__gnu_inline__)) +-#endif + #endif ++static + const char * + libc_name_p (register const char *str, register unsigned int len) + {