diff options
author | Alexey Neyman <stilor@att.net> | 2017-05-14 16:51:28 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-14 16:51:28 (GMT) |
commit | ef762bfe8e1ec9063d645b1745dc8843997b7767 (patch) | |
tree | b0a2fecc4e9b70316b134cb6202644824599f08f /patches/uClibc-ng/1.0.23/700-features.h-c11.patch | |
parent | 968b6918a2e00134077a2603f33451cfa617f44d (diff) | |
parent | 842915db44b2a41486dc5ea0212ddfc19093fe32 (diff) |
Merge pull request #716 from stilor/gcc7
Add GCC 7.1.0
Diffstat (limited to 'patches/uClibc-ng/1.0.23/700-features.h-c11.patch')
-rw-r--r-- | patches/uClibc-ng/1.0.23/700-features.h-c11.patch | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/patches/uClibc-ng/1.0.23/700-features.h-c11.patch b/patches/uClibc-ng/1.0.23/700-features.h-c11.patch new file mode 100644 index 0000000..cb1d2a8 --- /dev/null +++ b/patches/uClibc-ng/1.0.23/700-features.h-c11.patch @@ -0,0 +1,61 @@ +From 5b0f49037e8ea8500b05c8f31ee88529ccac4cee Mon Sep 17 00:00:00 2001 +From: Waldemar Brodkorb <wbx@openadk.org> +Date: Sun, 7 May 2017 16:28:14 +0200 +Subject: sync features.h with GNU C library, fixes gcc 7.1 toolchain creation + +--- + include/features.h | 17 ++++++++++++----- + 1 file changed, 12 insertions(+), 5 deletions(-) + +diff --git a/include/features.h b/include/features.h +index e76bbba..f982079 100644 +--- a/include/features.h ++++ b/include/features.h +@@ -55,6 +55,7 @@ + These are defined by this file and are used by the + header files to decide what to declare or define: + ++ __USE_ISOC11 Define ISO C11 things. + __USE_ISOC99 Define ISO C99 things. + __USE_ISOC95 Define ISO C90 AMD1 (C95) things. + __USE_POSIX Define IEEE Std 1003.1 things. +@@ -91,6 +92,7 @@ + + + /* Undefine everything, so we get a clean slate. */ ++#undef __USE_ISOC11 + #undef __USE_ISOC99 + #undef __USE_ISOC95 + #undef __USE_POSIX +@@ -151,6 +153,8 @@ + #ifdef _GNU_SOURCE + # undef _ISOC99_SOURCE + # define _ISOC99_SOURCE 1 ++# undef _ISOC11_SOURCE ++# define _ISOC11_SOURCE 1 + # undef _POSIX_SOURCE + # define _POSIX_SOURCE 1 + # undef _POSIX_C_SOURCE +@@ -223,11 +227,14 @@ + # define _SVID_SOURCE 1 + #endif + +-/* This is to enable the ISO C99 extension. Also recognize the old macro +- which was used prior to the standard acceptance. This macro will +- eventually go away and the features enabled by default once the ISO C99 +- standard is widely adopted. */ +-#if (defined _ISOC99_SOURCE || defined _ISOC9X_SOURCE \ ++/* This is to enable the ISO C11 extension. */ ++#if (defined _ISOC11_SOURCE \ ++ || (defined __STDC_VERSION__ && __STDC_VERSION__ >= 201112L)) ++# define __USE_ISOC11 1 ++#endif ++ ++/* This is to enable the ISO C99 extension. */ ++#if (defined _ISOC99_SOURCE || defined _ISOC11_SOURCE \ + || (defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L)) + # define __USE_ISOC99 1 + #endif +-- +cgit v0.11.2-3-g2eb4 + |