tiny tweaks for sane-toolchain and a cherry-pick
cover tiny tweaks for sane-toolchain and a cherry-pick
Hi,
The redo is a cherry-pick from that other ever growing to-send queue. The other 2 just trash my disc a bit less than before.
Bernhard Reutner-Fischer (3):
sane-toolchain-uclibc: use -pipe
sane-toolchain-uclinux-uclibc: use -pipe
gcc-svn: redo patch: Handle uClibc locale
conf/distro/include/sane-toolchain-uclibc.inc | 3 +- .../include/sane-toolchain-uclinux-uclibc.inc | 2 +- .../gcc-uclibc-locale-ctype_touplow_t.patch | 126 ++++++++++++++------ 3 files changed, 91 insertions(+), 40 deletions(-)
Signature · 1 line
1.7.2.3
PATCH 1/3 sane-toolchain-uclibc: use -pipe
Use -pipe for both BUILD_OPTIMIZATION and FULL_OPTIMIZATION
Signed-off-by Bernhard Reutner-Fischer <[email protected]>
--- conf/distro/include/sane-toolchain-uclibc.inc | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
conf/distro/include/sane-toolchain-uclibc.inc +2 -1
@@ -23,7 +23,8 @@ PREFERRED_VERSION_uclibc-cross-intermediate ?= "${PREFERRED_UCLIBC_VERSION}" #mess with compiler flags to use -Os instead of -O2 #Please see http://free-electrons.com/doc/embedded_linux_optimizations/img47.html for some more info -FULL_OPTIMIZATION = "-fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os" +FULL_OPTIMIZATION = "-fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os -pipe" +BUILD_OPTIMIZATION += "-pipe" #Gcc will die with 'internal consistency error when using the above optimizations #with gcc-4.2.1-atmel.1.0.3 (and probably most other avr32 gcc ports).
Signature · 1 line
1.7.2.3
PATCH 2/3 sane-toolchain-uclinux-uclibc: use -pipe
In reply to Bernhard Reutner-FischerUse -pipe for FULL_OPTIMIZATION
Signed-off-by Bernhard Reutner-Fischer <[email protected]>
--- .../include/sane-toolchain-uclinux-uclibc.inc | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
conf/distro/include/sane-toolchain-uclinux-uclibc.inc +1 -1
@@ -9,7 +9,7 @@ USE_NLS_gcc-cross = "no" #mess with compiler flags to use -Os instead of -O2 #Please see http://free-electrons.com/doc/embedded_linux_optimizations/img47.html for some more info -FULL_OPTIMIZATION = "-fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os" +FULL_OPTIMIZATION = "-fexpensive-optimizations -fomit-frame-pointer -frename-registers -Os -pipe" BUILD_OPTIMIZATION = "-Os" #Gcc will die with 'internal consistency error when using the above optimizations
Signature · 1 line
1.7.2.3
PATCH 3/3 gcc-svn: redo patch: Handle uClibc locale
In reply to Bernhard Reutner-FischerSigned-off-by Bernhard Reutner-Fischer <[email protected]>
--- .../gcc-uclibc-locale-ctype_touplow_t.patch | 126 ++++++++++++++------ 1 files changed, 88 insertions(+), 38 deletions(-)
recipes/gcc/gcc-svn/gcc-uclibc-locale-ctype_touplow_t.patch +88 -38
@@ -1,52 +1,102 @@ -Index: gcc-4.4.1/libstdc++-v3/config/locale/generic/c_locale.h -=================================================================== ---- gcc-4.4.1.orig/libstdc++-v3/config/locale/generic/c_locale.h 2009-08-06 23:38:32.398265633 -0700 -+++ gcc-4.4.1/libstdc++-v3/config/locale/generic/c_locale.h 2009-08-06 23:41:09.778242281 -0700 -@@ -41,12 +41,17 @@ - - #include <clocale> - #include <cstddef> -+#include <features.h> -+#include <ctype.h> - +From 66c29e5dc346d0ea5f426705f46d36f36e057a68 Mon Sep 17 00:00:00 2001 +From: Bernhard Reutner-Fischer <[email protected]> +Date: Tue, 4 Jan 2011 10:29:53 +0100 +Subject: [PATCH 19/20] libstdc++-v3: handle uClibc locale + +libstdc++-v3/ChangeLog: + +2010-01-03 Bernhard Reutner-Fischer <[email protected]> + + * config/locale/generic/c_locale.h: Handle uClibc locale. + * config/os/gnu-linux/ctype_base.h: Likewise. + * include/c/clocale: Include ctype.h for uClibc. + * include/c_global/clocale: Likewise. + * include/c_std/clocale: Likewise. + +Signed-off-by: Bernhard Reutner-Fischer <[email protected]> +--- + libstdc++-v3/config/locale/generic/c_locale.h | 5 ++++- + libstdc++-v3/config/os/gnu-linux/ctype_base.h | 4 ++++ + libstdc++-v3/include/c/clocale | 3 +++ + libstdc++-v3/include/c_global/clocale | 3 +++ + libstdc++-v3/include/c_std/clocale | 4 ++++ + 5 files changed, 18 insertions(+), 1 deletions(-) + +diff --git a/libstdc++-v3/config/locale/generic/c_locale.h b/libstdc++-v3/config/locale/generic/c_locale.h +index 7d685b8..4f69857 100644 +--- a/libstdc++-v3/config/locale/generic/c_locale.h ++++ b/libstdc++-v3/config/locale/generic/c_locale.h +@@ -44,8 +44,11 @@ #define _GLIBCXX_NUM_CATEGORIES 0 _GLIBCXX_BEGIN_NAMESPACE(std) - -- typedef int* __c_locale; -+#ifdef __UCLIBC__ -+ typedef __ctype_touplow_t* __c_locale; -+#else -+ typedef int* __c_locale; -+#endif ++#ifdef __UCLIBC__ ++ typedef __ctype_touplow_t* __c_locale; ++#else + typedef int* __c_locale; ++#endif // Convert numeric value of type double and long double to string and // return length of string. If vsnprintf is available use it, otherwise -Index: gcc-4.4.1/libstdc++-v3/config/os/gnu-linux/ctype_base.h -=================================================================== ---- gcc-4.4.1.orig/libstdc++-v3/config/os/gnu-linux/ctype_base.h 2009-08-06 23:42:27.402242608 -0700 -+++ gcc-4.4.1/libstdc++-v3/config/os/gnu-linux/ctype_base.h 2009-08-06 23:43:44.842241959 -0700 -@@ -33,14 +33,21 @@ - */ - - // Information as gleaned from /usr/include/ctype.h -- -+ -+#include <features.h> -+#include <ctype.h> -+ - _GLIBCXX_BEGIN_NAMESPACE(std) - - /// @brief Base class for ctype. +diff --git a/libstdc++-v3/config/os/gnu-linux/ctype_base.h b/libstdc++-v3/config/os/gnu-linux/ctype_base.h +index ff1f157..e88f569 100644 +--- a/libstdc++-v3/config/os/gnu-linux/ctype_base.h ++++ b/libstdc++-v3/config/os/gnu-linux/ctype_base.h +@@ -40,7 +40,11 @@ _GLIBCXX_BEGIN_NAMESPACE(std) struct ctype_base { // Non-standard typedefs. -- typedef const int* __to_type; -+#ifdef __UCLIBC__ -+ typedef const __ctype_touplow_t* __to_type; -+#else -+ typedef const int* __to_type; ++#ifdef __UCLIBC__ ++ typedef const __ctype_touplow_t* __to_type; ++#else + typedef const int* __to_type; +#endif // NB: Offsets into ctype<char>::_M_table force a particular size // on the mask type. Because of this, we don't use an enum. +diff --git a/libstdc++-v3/include/c/clocale b/libstdc++-v3/include/c/clocale +index 7ea60f0..619f128 100644 +--- a/libstdc++-v3/include/c/clocale ++++ b/libstdc++-v3/include/c/clocale +@@ -32,5 +32,8 @@ + #pragma GCC system_header + + #include_next <locale.h> ++#ifdef __UCLIBC__ ++#include <ctype.h> ++#endif + + #endif +diff --git a/libstdc++-v3/include/c_global/clocale b/libstdc++-v3/include/c_global/clocale +index 7cf42e2..cd9b37a 100644 +--- a/libstdc++-v3/include/c_global/clocale ++++ b/libstdc++-v3/include/c_global/clocale +@@ -42,6 +42,9 @@ + + #include <bits/c++config.h> + #include <locale.h> ++#ifdef __UCLIBC__ ++#include <ctype.h> ++#endif + + #ifndef _GLIBCXX_CLOCALE + #define _GLIBCXX_CLOCALE 1 +diff --git a/libstdc++-v3/include/c_std/clocale b/libstdc++-v3/include/c_std/clocale +index 36d8bd7..7905d5d 100644 +--- a/libstdc++-v3/include/c_std/clocale ++++ b/libstdc++-v3/include/c_std/clocale +@@ -45,6 +45,10 @@ + #include <bits/c++config.h> + #include <locale.h> + ++#ifdef __UCLIBC__ ++#include <ctype.h> ++#endif ++ + // Get rid of those macros defined in <locale.h> in lieu of real functions. + #undef setlocale + #undef localeconv +-- +1.7.2.3 +
Signature · 1 line
1.7.2.3