diff options
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-7.1/0003-gcc-uclibc-locale-ctype_touplow_t.patch')
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-7.1/0003-gcc-uclibc-locale-ctype_touplow_t.patch | 87 |
1 files changed, 0 insertions, 87 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-7.1/0003-gcc-uclibc-locale-ctype_touplow_t.patch b/meta/recipes-devtools/gcc/gcc-7.1/0003-gcc-uclibc-locale-ctype_touplow_t.patch deleted file mode 100644 index bd9eddc4d6..0000000000 --- a/meta/recipes-devtools/gcc/gcc-7.1/0003-gcc-uclibc-locale-ctype_touplow_t.patch +++ /dev/null | |||
@@ -1,87 +0,0 @@ | |||
1 | From e53fb4bcf1e584413ca7207511757287a0156147 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Fri, 29 Mar 2013 08:40:12 +0400 | ||
4 | Subject: [PATCH 03/47] gcc-uclibc-locale-ctype_touplow_t | ||
5 | |||
6 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
7 | |||
8 | Upstream-Status: Pending | ||
9 | --- | ||
10 | libstdc++-v3/config/locale/generic/c_locale.cc | 5 +++++ | ||
11 | libstdc++-v3/config/locale/generic/c_locale.h | 9 +++++++++ | ||
12 | libstdc++-v3/config/os/gnu-linux/ctype_base.h | 9 +++++++++ | ||
13 | 3 files changed, 23 insertions(+) | ||
14 | |||
15 | diff --git a/libstdc++-v3/config/locale/generic/c_locale.cc b/libstdc++-v3/config/locale/generic/c_locale.cc | ||
16 | index bd311e300f8..3190973d164 100644 | ||
17 | --- a/libstdc++-v3/config/locale/generic/c_locale.cc | ||
18 | +++ b/libstdc++-v3/config/locale/generic/c_locale.cc | ||
19 | @@ -273,5 +273,10 @@ _GLIBCXX_END_NAMESPACE_VERSION | ||
20 | #ifdef _GLIBCXX_LONG_DOUBLE_COMPAT | ||
21 | #define _GLIBCXX_LDBL_COMPAT(dbl, ldbl) \ | ||
22 | extern "C" void ldbl (void) __attribute__ ((alias (#dbl))) | ||
23 | +#ifdef __UCLIBC__ | ||
24 | +// This is because __c_locale is of type __ctype_touplow_t* which is short on uclibc. for glibc its int* | ||
25 | +_GLIBCXX_LDBL_COMPAT(_ZSt14__convert_to_vIdEvPKcRT_RSt12_Ios_IostateRKPs, _ZSt14__convert_to_vIeEvPKcRT_RSt12_Ios_IostateRKPs); | ||
26 | +#else | ||
27 | _GLIBCXX_LDBL_COMPAT(_ZSt14__convert_to_vIdEvPKcRT_RSt12_Ios_IostateRKPi, _ZSt14__convert_to_vIeEvPKcRT_RSt12_Ios_IostateRKPi); | ||
28 | +#endif | ||
29 | #endif // _GLIBCXX_LONG_DOUBLE_COMPAT | ||
30 | diff --git a/libstdc++-v3/config/locale/generic/c_locale.h b/libstdc++-v3/config/locale/generic/c_locale.h | ||
31 | index ce9fbb80d76..54211bee314 100644 | ||
32 | --- a/libstdc++-v3/config/locale/generic/c_locale.h | ||
33 | +++ b/libstdc++-v3/config/locale/generic/c_locale.h | ||
34 | @@ -40,13 +40,22 @@ | ||
35 | |||
36 | #include <clocale> | ||
37 | |||
38 | +#ifdef __UCLIBC__ | ||
39 | +#include <features.h> | ||
40 | +#include <ctype.h> | ||
41 | +#endif | ||
42 | + | ||
43 | #define _GLIBCXX_NUM_CATEGORIES 0 | ||
44 | |||
45 | namespace std _GLIBCXX_VISIBILITY(default) | ||
46 | { | ||
47 | _GLIBCXX_BEGIN_NAMESPACE_VERSION | ||
48 | |||
49 | +#ifdef __UCLIBC__ | ||
50 | + typedef __ctype_touplow_t* __c_locale; | ||
51 | +#else | ||
52 | typedef int* __c_locale; | ||
53 | +#endif | ||
54 | |||
55 | // Convert numeric value of type double and long double to string and | ||
56 | // return length of string. If vsnprintf is available use it, otherwise | ||
57 | diff --git a/libstdc++-v3/config/os/gnu-linux/ctype_base.h b/libstdc++-v3/config/os/gnu-linux/ctype_base.h | ||
58 | index 6ee1debdc2a..94bf3cf00aa 100644 | ||
59 | --- a/libstdc++-v3/config/os/gnu-linux/ctype_base.h | ||
60 | +++ b/libstdc++-v3/config/os/gnu-linux/ctype_base.h | ||
61 | @@ -33,6 +33,11 @@ | ||
62 | |||
63 | // Information as gleaned from /usr/include/ctype.h | ||
64 | |||
65 | +#ifdef __UCLIBC__ | ||
66 | +#include <features.h> | ||
67 | +#include <ctype.h> | ||
68 | +#endif | ||
69 | + | ||
70 | namespace std _GLIBCXX_VISIBILITY(default) | ||
71 | { | ||
72 | _GLIBCXX_BEGIN_NAMESPACE_VERSION | ||
73 | @@ -41,7 +46,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION | ||
74 | struct ctype_base | ||
75 | { | ||
76 | // Non-standard typedefs. | ||
77 | +#ifdef __UCLIBC__ | ||
78 | + typedef const __ctype_touplow_t* __to_type; | ||
79 | +#else | ||
80 | typedef const int* __to_type; | ||
81 | +#endif | ||
82 | |||
83 | // NB: Offsets into ctype<char>::_M_table force a particular size | ||
84 | // on the mask type. Because of this, we don't use an enum. | ||
85 | -- | ||
86 | 2.12.2 | ||
87 | |||