gcc: Add 4.3.0 from OE.dev (not default)
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4188 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
parent
1f8b96909c
commit
0b0cf026cf
|
@ -0,0 +1,53 @@
|
|||
# No uclibc, armeb and thumb patches - really needs checking
|
||||
DEFAULT_PREFERENCE = "-99"
|
||||
|
||||
require gcc-common.inc
|
||||
|
||||
DEPENDS = "mpfr gmp"
|
||||
|
||||
SRC_URI = "ftp://ftp.gnu.org/pub/gnu/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
|
||||
# file://100-uclibc-conf.patch;patch=1 \
|
||||
# file://103-uclibc-conf-noupstream.patch;patch=1 \
|
||||
# file://200-uclibc-locale.patch;patch=1 \
|
||||
# file://203-uclibc-locale-no__x.patch;patch=1 \
|
||||
# file://204-uclibc-locale-wchar_fix.patch;patch=1 \
|
||||
# file://205-uclibc-locale-update.patch;patch=1 \
|
||||
file://300-libstdc++-pic.patch;patch=1 \
|
||||
file://301-missing-execinfo_h.patch;patch=1 \
|
||||
# file://302-c99-snprintf.patch;patch=1 \
|
||||
# file://303-c99-complex-ugly-hack.patch;patch=1 \
|
||||
file://304-index_macro.patch;patch=1 \
|
||||
file://305-libmudflap-susv3-legacy.patch;patch=1 \
|
||||
# file://306-libstdc++-namespace.patch;patch=1 \
|
||||
# file://307-locale_facets.patch;patch=1 \
|
||||
# file://402-libbackend_dep_gcov-iov.h.patch;patch=1 \
|
||||
file://602-sdk-libstdc++-includes.patch;patch=1 \
|
||||
file://740-sh-pr24836.patch;patch=1 \
|
||||
# file://800-arm-bigendian.patch;patch=1 \
|
||||
# file://801-arm-bigendian-eabi.patch;patch=1 \
|
||||
file://904-flatten-switch-stmt-00.patch;patch=1 \
|
||||
file://arm-nolibfloat.patch;patch=1 \
|
||||
file://arm-softfloat.patch;patch=1 \
|
||||
# file://gcc41-configure.in.patch;patch=1 \
|
||||
# file://arm-thumb.patch;patch=1 \
|
||||
# file://arm-thumb-cache.patch;patch=1 \
|
||||
file://ldflags.patch;patch=1 \
|
||||
file://zecke-xgcc-cpp.patch;patch=1 \
|
||||
# file://unbreak-armv4t.patch;patch=1 \
|
||||
file://fix-ICE-in-arm_unwind_emit_set.diff;patch=1 \
|
||||
file://cache-amnesia.patch;patch=1 \
|
||||
file://gfortran.patch;patch=1 \
|
||||
# file://gcc-4.0.2-e300c2c3.patch;patch=1 \
|
||||
# file://pr34130.patch;patch=1 \
|
||||
# file://fortran-static-linking.patch;patch=1 \
|
||||
# file://intermask-bigendian.patch;patch=1 \
|
||||
"
|
||||
|
||||
SRC_URI_append_sh3 = " file://sh3-installfix-fixheaders.patch;patch=1 "
|
||||
|
||||
# Language Overrides
|
||||
FORTRAN = ""
|
||||
JAVA = ""
|
||||
|
||||
EXTRA_OECONF_BASE = " --disable-libssp --disable-bootstrap --disable-libgomp --disable-libmudflap"
|
||||
|
|
@ -0,0 +1,200 @@
|
|||
--- gcc/libgomp/configure
|
||||
+++ gcc/libgomp/configure
|
||||
@@ -3771,7 +3771,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/gcc/config/cris/linux.h
|
||||
+++ gcc/gcc/config/cris/linux.h
|
||||
@@ -74,7 +74,11 @@
|
||||
#define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG
|
||||
|
||||
#undef CRIS_SUBTARGET_VERSION
|
||||
-#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu"
|
||||
+#if UCLIBC_DEFAULT
|
||||
+# define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc"
|
||||
+#else
|
||||
+# define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu"
|
||||
+#endif
|
||||
|
||||
#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
|
||||
|
||||
--- gcc/libstdc++-v3/configure
|
||||
+++ gcc/libstdc++-v3/configure
|
||||
@@ -4276,7 +4276,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/zlib/configure
|
||||
+++ gcc/zlib/configure
|
||||
@@ -3422,7 +3422,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libobjc/configure
|
||||
+++ gcc/libobjc/configure
|
||||
@@ -3309,7 +3309,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libgfortran/configure
|
||||
+++ gcc/libgfortran/configure
|
||||
@@ -3695,7 +3695,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libmudflap/configure
|
||||
+++ gcc/libmudflap/configure
|
||||
@@ -5378,7 +5378,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/boehm-gc/configure
|
||||
+++ gcc/boehm-gc/configure
|
||||
@@ -4316,7 +4316,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libffi/configure
|
||||
+++ gcc/libffi/configure
|
||||
@@ -3453,7 +3453,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libssp/configure
|
||||
+++ gcc/libssp/configure
|
||||
@@ -4409,7 +4409,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/contrib/regression/objs-gcc.sh
|
||||
+++ gcc/contrib/regression/objs-gcc.sh
|
||||
@@ -105,6 +105,10 @@
|
||||
then
|
||||
make all-gdb all-dejagnu all-ld || exit 1
|
||||
make install-gdb install-dejagnu install-ld || exit 1
|
||||
+elif [ $H_REAL_TARGET = $H_REAL_HOST -a $H_REAL_TARGET = i686-pc-linux-uclibc ]
|
||||
+ then
|
||||
+ make all-gdb all-dejagnu all-ld || exit 1
|
||||
+ make install-gdb install-dejagnu install-ld || exit 1
|
||||
elif [ $H_REAL_TARGET = $H_REAL_HOST ] ; then
|
||||
make bootstrap || exit 1
|
||||
make install || exit 1
|
||||
--- gcc/libjava/classpath/ltconfig
|
||||
+++ gcc/libjava/classpath/ltconfig
|
||||
@@ -603,7 +603,7 @@
|
||||
|
||||
# Transform linux* to *-*-linux-gnu*, to support old configure scripts.
|
||||
case $host_os in
|
||||
-linux-gnu*) ;;
|
||||
+linux-gnu*|linux-uclibc*) ;;
|
||||
linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
|
||||
esac
|
||||
|
||||
@@ -1251,7 +1251,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
version_type=linux
|
||||
need_lib_prefix=no
|
||||
need_version=no
|
||||
--- gcc/libjava/classpath/configure
|
||||
+++ gcc/libjava/classpath/configure
|
||||
@@ -4665,7 +4665,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libjava/configure
|
||||
+++ gcc/libjava/configure
|
||||
@@ -5212,7 +5212,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/libtool.m4
|
||||
+++ gcc/libtool.m4
|
||||
@@ -739,7 +739,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
lt_cv_deplibs_check_method=pass_all
|
||||
;;
|
||||
|
||||
--- gcc/ltconfig
|
||||
+++ gcc/ltconfig
|
||||
@@ -603,7 +603,7 @@
|
||||
|
||||
# Transform linux* to *-*-linux-gnu*, to support old configure scripts.
|
||||
case $host_os in
|
||||
-linux-gnu*) ;;
|
||||
+linux-gnu*|linux-uclibc*) ;;
|
||||
linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
|
||||
esac
|
||||
|
||||
@@ -1251,7 +1251,7 @@
|
||||
;;
|
||||
|
||||
# This must be Linux ELF.
|
||||
-linux-gnu*)
|
||||
+linux*)
|
||||
version_type=linux
|
||||
need_lib_prefix=no
|
||||
need_version=no
|
|
@ -0,0 +1,11 @@
|
|||
--- gcc/gcc/config.gcc.uclibc100-sh~ 2006-03-06 20:46:56 +0100
|
||||
+++ gcc/gcc/config.gcc 2006-03-10 15:02:41 +0100
|
||||
@@ -1905,7 +1905,7 @@
|
||||
;;
|
||||
sh-*-elf* | sh[12346l]*-*-elf* | sh*-*-kaos* | \
|
||||
sh-*-symbianelf* | sh[12346l]*-*-symbianelf* | \
|
||||
- sh-*-linux* | sh[346lbe]*-*-linux* | \
|
||||
+ sh*-*-linux* | sh[346lbe]*-*-linux* | \
|
||||
sh-*-netbsdelf* | shl*-*-netbsdelf* | sh5-*-netbsd* | sh5l*-*-netbsd* | \
|
||||
sh64-*-netbsd* | sh64l*-*-netbsd*)
|
||||
tmake_file="${tmake_file} sh/t-sh sh/t-elf"
|
|
@ -0,0 +1,27 @@
|
|||
--- gcc-2005q3-1.orig/gcc/config.gcc 2005-10-31 19:02:54.000000000 +0300
|
||||
+++ gcc-2005q3-1/gcc/config.gcc 2006-01-27 01:09:09.000000000 +0300
|
||||
@@ -674,7 +674,7 @@
|
||||
tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h"
|
||||
tmake_file="t-slibgcc-elf-ver t-linux arm/t-arm"
|
||||
case ${target} in
|
||||
- arm*-*-linux-gnueabi)
|
||||
+ arm*-*-linux-gnueabi | arm*-*-linux-uclibcgnueabi)
|
||||
tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h"
|
||||
tmake_file="$tmake_file arm/t-arm-elf arm/t-bpabi arm/t-linux-eabi"
|
||||
# The BPABI long long divmod functions return a 128-bit value in
|
||||
|
||||
diff -urN gcc-2005q3-2/gcc/config/arm/linux-eabi.h gcc-2005q3-2.new/gcc/config/arm/linux-eabi.h
|
||||
--- gcc-2005q3-2/gcc/config/arm/linux-eabi.h 2005-12-07 23:14:16.000000000 +0300
|
||||
+++ gcc-2005q3-2.new/gcc/config/arm/linux-eabi.h 2006-03-29 19:02:34.000000000 +0400
|
||||
@@ -53,7 +53,11 @@
|
||||
/* Use ld-linux.so.3 so that it will be possible to run "classic"
|
||||
GNU/Linux binaries on an EABI system. */
|
||||
#undef LINUX_TARGET_INTERPRETER
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define LINUX_TARGET_INTERPRETER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
#define LINUX_TARGET_INTERPRETER "/lib/ld-linux.so.3"
|
||||
+#endif
|
||||
|
||||
/* At this point, bpabi.h will have clobbered LINK_SPEC. We want to
|
||||
use the GNU/Linux version, not the generic BPABI version. */
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,213 @@
|
|||
--- gcc/libstdc++-v3/config/locale/uclibc/c++locale_internal.h.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 2006-03-10 15:32:37 +0100
|
||||
@@ -60,4 +60,49 @@
|
||||
extern "C" __typeof(wctype_l) __wctype_l;
|
||||
#endif
|
||||
|
||||
+# define __nl_langinfo_l nl_langinfo_l
|
||||
+# define __strcoll_l strcoll_l
|
||||
+# define __strftime_l strftime_l
|
||||
+# define __strtod_l strtod_l
|
||||
+# define __strtof_l strtof_l
|
||||
+# define __strtold_l strtold_l
|
||||
+# define __strxfrm_l strxfrm_l
|
||||
+# define __newlocale newlocale
|
||||
+# define __freelocale freelocale
|
||||
+# define __duplocale duplocale
|
||||
+# define __uselocale uselocale
|
||||
+
|
||||
+# ifdef _GLIBCXX_USE_WCHAR_T
|
||||
+# define __iswctype_l iswctype_l
|
||||
+# define __towlower_l towlower_l
|
||||
+# define __towupper_l towupper_l
|
||||
+# define __wcscoll_l wcscoll_l
|
||||
+# define __wcsftime_l wcsftime_l
|
||||
+# define __wcsxfrm_l wcsxfrm_l
|
||||
+# define __wctype_l wctype_l
|
||||
+# endif
|
||||
+
|
||||
+#else
|
||||
+# define __nl_langinfo_l(N, L) nl_langinfo((N))
|
||||
+# define __strcoll_l(S1, S2, L) strcoll((S1), (S2))
|
||||
+# define __strtod_l(S, E, L) strtod((S), (E))
|
||||
+# define __strtof_l(S, E, L) strtof((S), (E))
|
||||
+# define __strtold_l(S, E, L) strtold((S), (E))
|
||||
+# define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N))
|
||||
+# warning should dummy __newlocale check for C|POSIX ?
|
||||
+# define __newlocale(a, b, c) NULL
|
||||
+# define __freelocale(a) ((void)0)
|
||||
+# define __duplocale(a) __c_locale()
|
||||
+//# define __uselocale ?
|
||||
+//
|
||||
+# ifdef _GLIBCXX_USE_WCHAR_T
|
||||
+# define __iswctype_l(C, M, L) iswctype((C), (M))
|
||||
+# define __towlower_l(C, L) towlower((C))
|
||||
+# define __towupper_l(C, L) towupper((C))
|
||||
+# define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2))
|
||||
+//# define __wcsftime_l(S, M, F, T, L) wcsftime((S), (M), (F), (T))
|
||||
+# define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N))
|
||||
+# define __wctype_l(S, L) wctype((S))
|
||||
+# endif
|
||||
+
|
||||
#endif // GLIBC 2.3 and later
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/c_locale.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/c_locale.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -39,20 +39,6 @@
|
||||
#include <langinfo.h>
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __strtol_l(S, E, B, L) strtol((S), (E), (B))
|
||||
-#define __strtoul_l(S, E, B, L) strtoul((S), (E), (B))
|
||||
-#define __strtoll_l(S, E, B, L) strtoll((S), (E), (B))
|
||||
-#define __strtoull_l(S, E, B, L) strtoull((S), (E), (B))
|
||||
-#define __strtof_l(S, E, L) strtof((S), (E))
|
||||
-#define __strtod_l(S, E, L) strtod((S), (E))
|
||||
-#define __strtold_l(S, E, L) strtold((S), (E))
|
||||
-#warning should dummy __newlocale check for C|POSIX ?
|
||||
-#define __newlocale(a, b, c) NULL
|
||||
-#define __freelocale(a) ((void)0)
|
||||
-#define __duplocale(a) __c_locale()
|
||||
-#endif
|
||||
-
|
||||
namespace std
|
||||
{
|
||||
template<>
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/collate_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/collate_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -36,13 +36,6 @@
|
||||
#include <locale>
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __strcoll_l(S1, S2, L) strcoll((S1), (S2))
|
||||
-#define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N))
|
||||
-#define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2))
|
||||
-#define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N))
|
||||
-#endif
|
||||
-
|
||||
namespace std
|
||||
{
|
||||
// These are basically extensions to char_traits, and perhaps should
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -43,10 +43,6 @@
|
||||
#warning tailor for stub locale support
|
||||
#endif
|
||||
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __nl_langinfo_l(N, L) nl_langinfo((N))
|
||||
-#endif
|
||||
-
|
||||
namespace std
|
||||
{
|
||||
// Construct and return valid pattern consisting of some combination of:
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -41,9 +41,6 @@
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning tailor for stub locale support
|
||||
#endif
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __nl_langinfo_l(N, L) nl_langinfo((N))
|
||||
-#endif
|
||||
|
||||
namespace std
|
||||
{
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/time_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/time_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -40,9 +40,6 @@
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning tailor for stub locale support
|
||||
#endif
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __nl_langinfo_l(N, L) nl_langinfo((N))
|
||||
-#endif
|
||||
|
||||
namespace std
|
||||
{
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/ctype_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -38,13 +38,6 @@
|
||||
#undef _LIBC
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
-#ifndef __UCLIBC_HAS_XLOCALE__
|
||||
-#define __wctype_l(S, L) wctype((S))
|
||||
-#define __towupper_l(C, L) towupper((C))
|
||||
-#define __towlower_l(C, L) towlower((C))
|
||||
-#define __iswctype_l(C, M, L) iswctype((C), (M))
|
||||
-#endif
|
||||
-
|
||||
namespace std
|
||||
{
|
||||
// NB: The other ctype<char> specializations are in src/locale.cc and
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/messages_members.cc.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/messages_members.cc 2006-03-10 15:32:37 +0100
|
||||
@@ -39,13 +39,10 @@
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning fix gettext stuff
|
||||
#endif
|
||||
-#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
|
||||
-extern "C" char *__dcgettext(const char *domainname,
|
||||
- const char *msgid, int category);
|
||||
#undef gettext
|
||||
-#define gettext(msgid) __dcgettext(NULL, msgid, LC_MESSAGES)
|
||||
+#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
|
||||
+#define gettext(msgid) dcgettext(NULL, msgid, LC_MESSAGES)
|
||||
#else
|
||||
-#undef gettext
|
||||
#define gettext(msgid) (msgid)
|
||||
#endif
|
||||
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/messages_members.h.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/messages_members.h 2006-03-10 15:32:37 +0100
|
||||
@@ -36,15 +36,11 @@
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning fix prototypes for *textdomain funcs
|
||||
#endif
|
||||
-#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
|
||||
-extern "C" char *__textdomain(const char *domainname);
|
||||
-extern "C" char *__bindtextdomain(const char *domainname,
|
||||
- const char *dirname);
|
||||
-#else
|
||||
-#undef __textdomain
|
||||
-#undef __bindtextdomain
|
||||
-#define __textdomain(D) ((void)0)
|
||||
-#define __bindtextdomain(D,P) ((void)0)
|
||||
+#ifndef __UCLIBC_HAS_GETTEXT_AWARENESS__
|
||||
+#undef textdomain
|
||||
+#undef bindtextdomain
|
||||
+#define textdomain(D) ((void)0)
|
||||
+#define bindtextdomain(D,P) ((void)0)
|
||||
#endif
|
||||
|
||||
// Non-virtual member functions.
|
||||
@@ -70,7 +66,7 @@
|
||||
messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
|
||||
const char* __dir) const
|
||||
{
|
||||
- __bindtextdomain(__s.c_str(), __dir);
|
||||
+ bindtextdomain(__s.c_str(), __dir);
|
||||
return this->do_open(__s, __loc);
|
||||
}
|
||||
|
||||
@@ -90,7 +86,7 @@
|
||||
{
|
||||
// No error checking is done, assume the catalog exists and can
|
||||
// be used.
|
||||
- __textdomain(__s.c_str());
|
||||
+ textdomain(__s.c_str());
|
||||
return 0;
|
||||
}
|
||||
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/c_locale.h.uclibc200no__x~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/c_locale.h 2006-03-10 15:32:37 +0100
|
||||
@@ -68,6 +68,7 @@
|
||||
{
|
||||
extern "C" __typeof(uselocale) __uselocale;
|
||||
}
|
||||
+#define __uselocale uselocale
|
||||
#endif
|
||||
|
||||
namespace std
|
|
@ -0,0 +1,48 @@
|
|||
--- gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc.uclibc200_wchar~ 2006-03-10 15:32:37 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2006-03-10 15:37:27 +0100
|
||||
@@ -401,7 +401,7 @@
|
||||
# ifdef __UCLIBC_HAS_XLOCALE__
|
||||
_M_data->_M_decimal_point = __cloc->decimal_point_wc;
|
||||
_M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
|
||||
-# else
|
||||
+# elif defined __UCLIBC_HAS_LOCALE__
|
||||
_M_data->_M_decimal_point = __global_locale->decimal_point_wc;
|
||||
_M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
|
||||
# endif
|
||||
@@ -556,7 +556,7 @@
|
||||
# ifdef __UCLIBC_HAS_XLOCALE__
|
||||
_M_data->_M_decimal_point = __cloc->decimal_point_wc;
|
||||
_M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
|
||||
-# else
|
||||
+# elif defined __UCLIBC_HAS_LOCALE__
|
||||
_M_data->_M_decimal_point = __global_locale->decimal_point_wc;
|
||||
_M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
|
||||
# endif
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc.uclibc200_wchar~ 2006-03-10 15:32:37 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2006-03-10 15:37:27 +0100
|
||||
@@ -127,12 +127,25 @@
|
||||
{
|
||||
// Named locale.
|
||||
// NB: In the GNU model wchar_t is always 32 bit wide.
|
||||
+#ifdef __UCLIBC_MJN3_ONLY__
|
||||
+#warning fix this... should be numeric
|
||||
+#endif
|
||||
+#ifdef __UCLIBC__
|
||||
+# ifdef __UCLIBC_HAS_XLOCALE__
|
||||
+ _M_data->_M_decimal_point = __cloc->decimal_point_wc;
|
||||
+ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
|
||||
+# elif defined __UCLIBC_HAS_LOCALE__
|
||||
+ _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
|
||||
+ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
|
||||
+# endif
|
||||
+#else
|
||||
union { char *__s; wchar_t __w; } __u;
|
||||
__u.__s = __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc);
|
||||
_M_data->_M_decimal_point = __u.__w;
|
||||
|
||||
__u.__s = __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc);
|
||||
_M_data->_M_thousands_sep = __u.__w;
|
||||
+#endif
|
||||
|
||||
if (_M_data->_M_thousands_sep == L'\0')
|
||||
_M_data->_M_grouping = "";
|
|
@ -0,0 +1,347 @@
|
|||
--- gcc/libstdc++-v3/config/locale/uclibc/c_locale.cc.uclibc200_update~ 2006-03-10 15:32:37 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/c_locale.cc 2006-03-10 15:39:14 +0100
|
||||
@@ -46,16 +47,13 @@
|
||||
__convert_to_v(const char* __s, float& __v, ios_base::iostate& __err,
|
||||
const __c_locale& __cloc)
|
||||
{
|
||||
- if (!(__err & ios_base::failbit))
|
||||
- {
|
||||
- char* __sanity;
|
||||
- errno = 0;
|
||||
- float __f = __strtof_l(__s, &__sanity, __cloc);
|
||||
- if (__sanity != __s && errno != ERANGE)
|
||||
- __v = __f;
|
||||
- else
|
||||
- __err |= ios_base::failbit;
|
||||
- }
|
||||
+ char* __sanity;
|
||||
+ errno = 0;
|
||||
+ float __f = __strtof_l(__s, &__sanity, __cloc);
|
||||
+ if (__sanity != __s && errno != ERANGE)
|
||||
+ __v = __f;
|
||||
+ else
|
||||
+ __err |= ios_base::failbit;
|
||||
}
|
||||
|
||||
template<>
|
||||
@@ -63,16 +61,13 @@
|
||||
__convert_to_v(const char* __s, double& __v, ios_base::iostate& __err,
|
||||
const __c_locale& __cloc)
|
||||
{
|
||||
- if (!(__err & ios_base::failbit))
|
||||
- {
|
||||
- char* __sanity;
|
||||
- errno = 0;
|
||||
- double __d = __strtod_l(__s, &__sanity, __cloc);
|
||||
- if (__sanity != __s && errno != ERANGE)
|
||||
- __v = __d;
|
||||
- else
|
||||
- __err |= ios_base::failbit;
|
||||
- }
|
||||
+ char* __sanity;
|
||||
+ errno = 0;
|
||||
+ double __d = __strtod_l(__s, &__sanity, __cloc);
|
||||
+ if (__sanity != __s && errno != ERANGE)
|
||||
+ __v = __d;
|
||||
+ else
|
||||
+ __err |= ios_base::failbit;
|
||||
}
|
||||
|
||||
template<>
|
||||
@@ -80,16 +75,13 @@
|
||||
__convert_to_v(const char* __s, long double& __v, ios_base::iostate& __err,
|
||||
const __c_locale& __cloc)
|
||||
{
|
||||
- if (!(__err & ios_base::failbit))
|
||||
- {
|
||||
- char* __sanity;
|
||||
- errno = 0;
|
||||
- long double __ld = __strtold_l(__s, &__sanity, __cloc);
|
||||
- if (__sanity != __s && errno != ERANGE)
|
||||
- __v = __ld;
|
||||
- else
|
||||
- __err |= ios_base::failbit;
|
||||
- }
|
||||
+ char* __sanity;
|
||||
+ errno = 0;
|
||||
+ long double __ld = __strtold_l(__s, &__sanity, __cloc);
|
||||
+ if (__sanity != __s && errno != ERANGE)
|
||||
+ __v = __ld;
|
||||
+ else
|
||||
+ __err |= ios_base::failbit;
|
||||
}
|
||||
|
||||
void
|
||||
@@ -110,7 +102,7 @@
|
||||
void
|
||||
locale::facet::_S_destroy_c_locale(__c_locale& __cloc)
|
||||
{
|
||||
- if (_S_get_c_locale() != __cloc)
|
||||
+ if (__cloc && _S_get_c_locale() != __cloc)
|
||||
__freelocale(__cloc);
|
||||
}
|
||||
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/ctype_members.cc.uclibc200_update~ 2006-03-10 15:32:37 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2006-03-10 15:39:14 +0100
|
||||
@@ -33,9 +33,14 @@
|
||||
|
||||
// Written by Benjamin Kosnik <bkoz@redhat.com>
|
||||
|
||||
+#include <features.h>
|
||||
+#ifdef __UCLIBC_HAS_LOCALE__
|
||||
#define _LIBC
|
||||
#include <locale>
|
||||
#undef _LIBC
|
||||
+#else
|
||||
+#include <locale>
|
||||
+#endif
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
namespace std
|
||||
@@ -138,20 +143,34 @@
|
||||
ctype<wchar_t>::
|
||||
do_is(mask __m, wchar_t __c) const
|
||||
{
|
||||
- // Highest bitmask in ctype_base == 10, but extra in "C"
|
||||
- // library for blank.
|
||||
+ // The case of __m == ctype_base::space is particularly important,
|
||||
+ // due to its use in many istream functions. Therefore we deal with
|
||||
+ // it first, exploiting the knowledge that on GNU systems _M_bit[5]
|
||||
+ // is the mask corresponding to ctype_base::space. NB: an encoding
|
||||
+ // change would not affect correctness!
|
||||
bool __ret = false;
|
||||
- const size_t __bitmasksize = 11;
|
||||
- for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
|
||||
- if (__m & _M_bit[__bitcur]
|
||||
- && __iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype))
|
||||
- {
|
||||
- __ret = true;
|
||||
- break;
|
||||
- }
|
||||
+ if (__m == _M_bit[5])
|
||||
+ __ret = __iswctype_l(__c, _M_wmask[5], _M_c_locale_ctype);
|
||||
+ else
|
||||
+ {
|
||||
+ // Highest bitmask in ctype_base == 10, but extra in "C"
|
||||
+ // library for blank.
|
||||
+ const size_t __bitmasksize = 11;
|
||||
+ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
|
||||
+ if (__m & _M_bit[__bitcur])
|
||||
+ {
|
||||
+ if (__iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype))
|
||||
+ {
|
||||
+ __ret = true;
|
||||
+ break;
|
||||
+ }
|
||||
+ else if (__m == _M_bit[__bitcur])
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
return __ret;
|
||||
}
|
||||
-
|
||||
+
|
||||
const wchar_t*
|
||||
ctype<wchar_t>::
|
||||
do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/messages_members.h.uclibc200_update~ 2006-03-10 15:32:37 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/messages_members.h 2006-03-10 15:39:14 +0100
|
||||
@@ -47,18 +47,21 @@
|
||||
template<typename _CharT>
|
||||
messages<_CharT>::messages(size_t __refs)
|
||||
: facet(__refs), _M_c_locale_messages(_S_get_c_locale()),
|
||||
- _M_name_messages(_S_get_c_name())
|
||||
+ _M_name_messages(_S_get_c_name())
|
||||
{ }
|
||||
|
||||
template<typename _CharT>
|
||||
messages<_CharT>::messages(__c_locale __cloc, const char* __s,
|
||||
size_t __refs)
|
||||
- : facet(__refs), _M_c_locale_messages(_S_clone_c_locale(__cloc)),
|
||||
- _M_name_messages(__s)
|
||||
+ : facet(__refs), _M_c_locale_messages(NULL), _M_name_messages(NULL)
|
||||
{
|
||||
- char* __tmp = new char[std::strlen(__s) + 1];
|
||||
- std::strcpy(__tmp, __s);
|
||||
+ const size_t __len = std::strlen(__s) + 1;
|
||||
+ char* __tmp = new char[__len];
|
||||
+ std::memcpy(__tmp, __s, __len);
|
||||
_M_name_messages = __tmp;
|
||||
+
|
||||
+ // Last to avoid leaking memory if new throws.
|
||||
+ _M_c_locale_messages = _S_clone_c_locale(__cloc);
|
||||
}
|
||||
|
||||
template<typename _CharT>
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc.uclibc200_update~ 2006-03-10 15:37:27 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2006-03-10 15:39:14 +0100
|
||||
@@ -33,9 +33,14 @@
|
||||
|
||||
// Written by Benjamin Kosnik <bkoz@redhat.com>
|
||||
|
||||
+#include <features.h>
|
||||
+#ifdef __UCLIBC_HAS_LOCALE__
|
||||
#define _LIBC
|
||||
#include <locale>
|
||||
#undef _LIBC
|
||||
+#else
|
||||
+#include <locale>
|
||||
+#endif
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
@@ -206,7 +211,7 @@
|
||||
}
|
||||
break;
|
||||
default:
|
||||
- ;
|
||||
+ __ret = pattern();
|
||||
}
|
||||
return __ret;
|
||||
}
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc.uclibc200_update~ 2006-03-10 15:37:27 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2006-03-10 15:39:14 +0100
|
||||
@@ -33,9 +33,14 @@
|
||||
|
||||
// Written by Benjamin Kosnik <bkoz@redhat.com>
|
||||
|
||||
+#include <features.h>
|
||||
+#ifdef __UCLIBC_HAS_LOCALE__
|
||||
#define _LIBC
|
||||
#include <locale>
|
||||
#undef _LIBC
|
||||
+#else
|
||||
+#include <locale>
|
||||
+#endif
|
||||
#include <bits/c++locale_internal.h>
|
||||
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
--- gcc/libstdc++-v3/config/locale/uclibc/time_members.h.uclibc200_update~ 2006-03-10 15:06:17 +0100
|
||||
+++ gcc/libstdc++-v3/config/locale/uclibc/time_members.h 2006-03-10 15:39:14 +0100
|
||||
@@ -37,25 +37,33 @@
|
||||
template<typename _CharT>
|
||||
__timepunct<_CharT>::__timepunct(size_t __refs)
|
||||
: facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL),
|
||||
- _M_name_timepunct(_S_get_c_name())
|
||||
+ _M_name_timepunct(_S_get_c_name())
|
||||
{ _M_initialize_timepunct(); }
|
||||
|
||||
template<typename _CharT>
|
||||
__timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs)
|
||||
: facet(__refs), _M_data(__cache), _M_c_locale_timepunct(NULL),
|
||||
- _M_name_timepunct(_S_get_c_name())
|
||||
+ _M_name_timepunct(_S_get_c_name())
|
||||
{ _M_initialize_timepunct(); }
|
||||
|
||||
template<typename _CharT>
|
||||
__timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s,
|
||||
size_t __refs)
|
||||
: facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL),
|
||||
- _M_name_timepunct(__s)
|
||||
+ _M_name_timepunct(NULL)
|
||||
{
|
||||
- char* __tmp = new char[std::strlen(__s) + 1];
|
||||
- std::strcpy(__tmp, __s);
|
||||
+ const size_t __len = std::strlen(__s) + 1;
|
||||
+ char* __tmp = new char[__len];
|
||||
+ std::memcpy(__tmp, __s, __len);
|
||||
_M_name_timepunct = __tmp;
|
||||
- _M_initialize_timepunct(__cloc);
|
||||
+
|
||||
+ try
|
||||
+ { _M_initialize_timepunct(__cloc); }
|
||||
+ catch(...)
|
||||
+ {
|
||||
+ delete [] _M_name_timepunct;
|
||||
+ __throw_exception_again;
|
||||
+ }
|
||||
}
|
||||
|
||||
template<typename _CharT>
|
||||
--- gcc-4.2/libstdc++-v3/config/locale/uclibc/c_locale.h.old 2006-09-28 11:39:00.000000000 +0200
|
||||
+++ gcc-4.2/libstdc++-v3/config/locale/uclibc/c_locale.h 2006-09-28 12:10:41.000000000 +0200
|
||||
@@ -39,21 +39,23 @@
|
||||
#pragma GCC system_header
|
||||
|
||||
#include <cstring> // get std::strlen
|
||||
-#include <cstdio> // get std::snprintf or std::sprintf
|
||||
+#include <cstdio> // get std::vsnprintf or std::vsprintf
|
||||
#include <clocale>
|
||||
#include <langinfo.h> // For codecvt
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning fix this
|
||||
#endif
|
||||
-#ifdef __UCLIBC_HAS_LOCALE__
|
||||
+#ifdef _GLIBCXX_USE_ICONV
|
||||
#include <iconv.h> // For codecvt using iconv, iconv_t
|
||||
#endif
|
||||
-#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
|
||||
-#include <libintl.h> // For messages
|
||||
+#ifdef HAVE_LIBINTL_H
|
||||
+#include <libintl.h> // For messages
|
||||
#endif
|
||||
+#include <cstdarg>
|
||||
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning what is _GLIBCXX_C_LOCALE_GNU for
|
||||
+// psm: used in os/gnu-linux/ctype_noninline.h
|
||||
#endif
|
||||
#define _GLIBCXX_C_LOCALE_GNU 1
|
||||
|
||||
@@ -62,7 +64,7 @@
|
||||
#endif
|
||||
// #define _GLIBCXX_NUM_CATEGORIES 6
|
||||
#define _GLIBCXX_NUM_CATEGORIES 0
|
||||
-
|
||||
+
|
||||
#ifdef __UCLIBC_HAS_XLOCALE__
|
||||
namespace __gnu_cxx
|
||||
{
|
||||
@@ -79,22 +81,24 @@
|
||||
typedef int* __c_locale;
|
||||
#endif
|
||||
|
||||
- // Convert numeric value of type _Tv to string and return length of
|
||||
- // string. If snprintf is available use it, otherwise fall back to
|
||||
- // the unsafe sprintf which, in general, can be dangerous and should
|
||||
+ // Convert numeric value of type double to string and return length of
|
||||
+ // string. If vsnprintf is available use it, otherwise fall back to
|
||||
+ // the unsafe vsprintf which, in general, can be dangerous and should
|
||||
// be avoided.
|
||||
- template<typename _Tv>
|
||||
- int
|
||||
- __convert_from_v(char* __out,
|
||||
- const int __size __attribute__ ((__unused__)),
|
||||
- const char* __fmt,
|
||||
-#ifdef __UCLIBC_HAS_XCLOCALE__
|
||||
- _Tv __v, const __c_locale& __cloc, int __prec)
|
||||
+ inline int
|
||||
+ __convert_from_v(const __c_locale&
|
||||
+#ifndef __UCLIBC_HAS_XCLOCALE__
|
||||
+ __cloc __attribute__ ((__unused__))
|
||||
+#endif
|
||||
+ ,
|
||||
+ char* __out,
|
||||
+ const int __size,
|
||||
+ const char* __fmt, ...)
|
||||
{
|
||||
+ va_list __args;
|
||||
+#ifdef __UCLIBC_HAS_XCLOCALE__
|
||||
__c_locale __old = __gnu_cxx::__uselocale(__cloc);
|
||||
#else
|
||||
- _Tv __v, const __c_locale&, int __prec)
|
||||
- {
|
||||
# ifdef __UCLIBC_HAS_LOCALE__
|
||||
char* __old = std::setlocale(LC_ALL, NULL);
|
||||
char* __sav = new char[std::strlen(__old) + 1];
|
||||
@@ -103,7 +107,9 @@
|
||||
# endif
|
||||
#endif
|
||||
|
||||
- const int __ret = std::snprintf(__out, __size, __fmt, __prec, __v);
|
||||
+ va_start(__args, __fmt);
|
||||
+ const int __ret = std::vsnprintf(__out, __size, __fmt, __args);
|
||||
+ va_end(__args);
|
||||
|
||||
#ifdef __UCLIBC_HAS_XCLOCALE__
|
||||
__gnu_cxx::__uselocale(__old);
|
|
@ -0,0 +1,46 @@
|
|||
# DP: Build and install libstdc++_pic.a library.
|
||||
|
||||
--- gcc-4.1.0/libstdc++-v3/src/Makefile.am 2004-11-15 17:33:05.000000000 -0600
|
||||
+++ gcc-4.1.0-patched/libstdc++-v3/src/Makefile.am 2005-04-25 20:05:59.186930896 -0500
|
||||
@@ -214,6 +214,10 @@
|
||||
$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LDFLAGS) -o $@
|
||||
|
||||
|
||||
+install-exec-local:
|
||||
+ $(AR) cru libstdc++_pic.a .libs/*.o $(top_builddir)/libsupc++/*.o
|
||||
+ $(INSTALL_DATA) libstdc++_pic.a $(DESTDIR)$(toolexeclibdir)
|
||||
+
|
||||
# Added bits to build debug library.
|
||||
if GLIBCXX_BUILD_DEBUG
|
||||
all-local: build_debug
|
||||
--- gcc-4.1.0/libstdc++-v3/src/Makefile.in 2005-04-11 19:13:08.000000000 -0500
|
||||
+++ gcc-4.1.0-patched/libstdc++-v3/src/Makefile.in 2005-04-25 20:12:33.284316275 -0500
|
||||
@@ -627,7 +627,7 @@
|
||||
|
||||
install-data-am: install-data-local
|
||||
|
||||
-install-exec-am: install-toolexeclibLTLIBRARIES
|
||||
+install-exec-am: install-toolexeclibLTLIBRARIES install-exec-local
|
||||
|
||||
install-info: install-info-am
|
||||
|
||||
@@ -660,6 +660,7 @@
|
||||
distclean-libtool distclean-tags distdir dvi dvi-am html \
|
||||
html-am info info-am install install-am install-data \
|
||||
install-data-am install-data-local install-exec \
|
||||
+ install-exec-local \
|
||||
install-exec-am install-info install-info-am install-man \
|
||||
install-strip install-toolexeclibLTLIBRARIES installcheck \
|
||||
installcheck-am installdirs maintainer-clean \
|
||||
@@ -745,6 +746,11 @@
|
||||
install_debug:
|
||||
(cd ${debugdir} && $(MAKE) \
|
||||
toolexeclibdir=$(glibcxx_toolexeclibdir)/debug install)
|
||||
+
|
||||
+install-exec-local:
|
||||
+ $(AR) cru libstdc++_pic.a .libs/*.o $(top_builddir)/libsupc++/*.o
|
||||
+ $(INSTALL_DATA) libstdc++_pic.a $(DESTDIR)$(toolexeclibdir)
|
||||
+
|
||||
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||
.NOEXPORT:
|
|
@ -0,0 +1,11 @@
|
|||
--- gcc-4.0.0/boehm-gc/include/gc.h-orig 2005-04-28 22:28:57.000000000 -0500
|
||||
+++ gcc-4.0.0/boehm-gc/include/gc.h 2005-04-28 22:30:38.000000000 -0500
|
||||
@@ -500,7 +500,7 @@
|
||||
#ifdef __linux__
|
||||
# include <features.h>
|
||||
# if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \
|
||||
- && !defined(__ia64__)
|
||||
+ && !defined(__ia64__) && !defined(__UCLIBC__)
|
||||
# ifndef GC_HAVE_BUILTIN_BACKTRACE
|
||||
# define GC_HAVE_BUILTIN_BACKTRACE
|
||||
# endif
|
|
@ -0,0 +1,11 @@
|
|||
--- gcc-4.0.0/libstdc++-v3/include/c_std/std_cstdio.h-orig 2005-04-29 00:08:41.000000000 -0500
|
||||
+++ gcc-4.0.0/libstdc++-v3/include/c_std/std_cstdio.h 2005-04-29 00:08:45.000000000 -0500
|
||||
@@ -142,7 +142,7 @@
|
||||
using ::vsprintf;
|
||||
}
|
||||
|
||||
-#if _GLIBCXX_USE_C99
|
||||
+#if _GLIBCXX_USE_C99 || defined(__UCLIBC__)
|
||||
|
||||
#undef snprintf
|
||||
#undef vfscanf
|
|
@ -0,0 +1,12 @@
|
|||
--- gcc-4.0.0/libstdc++-v3/configure-old 2005-04-30 22:04:48.061603912 -0500
|
||||
+++ gcc-4.0.0/libstdc++-v3/configure 2005-04-30 22:06:13.678588152 -0500
|
||||
@@ -7194,6 +7194,9 @@
|
||||
cat >>conftest.$ac_ext <<_ACEOF
|
||||
/* end confdefs.h. */
|
||||
#include <complex.h>
|
||||
+#ifdef __UCLIBC__
|
||||
+#error ugly hack to make sure configure test fails here for cross until uClibc supports the complex funcs
|
||||
+#endif
|
||||
int
|
||||
main ()
|
||||
{
|
|
@ -0,0 +1,24 @@
|
|||
--- gcc-4.1.0/libstdc++-v3/include/ext/rope.mps 2006-03-24 01:49:51 +0100
|
||||
+++ gcc-4.1.0/libstdc++-v3/include/ext/rope 2006-03-24 01:49:37 +0100
|
||||
@@ -59,6 +59,9 @@
|
||||
#include <bits/allocator.h>
|
||||
#include <ext/hash_fun.h>
|
||||
|
||||
+/* cope w/ index defined as macro, SuSv3 proposal */
|
||||
+#undef index
|
||||
+
|
||||
# ifdef __GC
|
||||
# define __GC_CONST const
|
||||
# else
|
||||
--- gcc-4.1.0/libstdc++-v3/include/ext/ropeimpl.h.mps 2006-03-24 01:50:04 +0100
|
||||
+++ gcc-4.1.0/libstdc++-v3/include/ext/ropeimpl.h 2006-03-24 01:50:28 +0100
|
||||
@@ -53,6 +53,9 @@
|
||||
#include <ext/memory> // For uninitialized_copy_n
|
||||
#include <ext/numeric> // For power
|
||||
|
||||
+/* cope w/ index defined as macro, SuSv3 proposal */
|
||||
+#undef index
|
||||
+
|
||||
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
|
||||
|
||||
using std::size_t;
|
|
@ -0,0 +1,49 @@
|
|||
Index: gcc-4.2/libmudflap/mf-hooks2.c
|
||||
===================================================================
|
||||
--- gcc-4.2/libmudflap/mf-hooks2.c (revision 119834)
|
||||
+++ gcc-4.2/libmudflap/mf-hooks2.c (working copy)
|
||||
@@ -427,7 +427,7 @@
|
||||
{
|
||||
TRACE ("%s\n", __PRETTY_FUNCTION__);
|
||||
MF_VALIDATE_EXTENT(s, n, __MF_CHECK_WRITE, "bzero region");
|
||||
- bzero (s, n);
|
||||
+ memset (s, 0, n);
|
||||
}
|
||||
|
||||
|
||||
@@ -437,7 +437,7 @@
|
||||
TRACE ("%s\n", __PRETTY_FUNCTION__);
|
||||
MF_VALIDATE_EXTENT(src, n, __MF_CHECK_READ, "bcopy src");
|
||||
MF_VALIDATE_EXTENT(dest, n, __MF_CHECK_WRITE, "bcopy dest");
|
||||
- bcopy (src, dest, n);
|
||||
+ memmove (dest, src, n);
|
||||
}
|
||||
|
||||
|
||||
@@ -447,7 +447,7 @@
|
||||
TRACE ("%s\n", __PRETTY_FUNCTION__);
|
||||
MF_VALIDATE_EXTENT(s1, n, __MF_CHECK_READ, "bcmp 1st arg");
|
||||
MF_VALIDATE_EXTENT(s2, n, __MF_CHECK_READ, "bcmp 2nd arg");
|
||||
- return bcmp (s1, s2, n);
|
||||
+ return n == 0 ? 0 : memcmp (s1, s2, n);
|
||||
}
|
||||
|
||||
|
||||
@@ -456,7 +456,7 @@
|
||||
size_t n = strlen (s);
|
||||
TRACE ("%s\n", __PRETTY_FUNCTION__);
|
||||
MF_VALIDATE_EXTENT(s, CLAMPADD(n, 1), __MF_CHECK_READ, "index region");
|
||||
- return index (s, c);
|
||||
+ return strchr (s, c);
|
||||
}
|
||||
|
||||
|
||||
@@ -465,7 +465,7 @@
|
||||
size_t n = strlen (s);
|
||||
TRACE ("%s\n", __PRETTY_FUNCTION__);
|
||||
MF_VALIDATE_EXTENT(s, CLAMPADD(n, 1), __MF_CHECK_READ, "rindex region");
|
||||
- return rindex (s, c);
|
||||
+ return strrchr (s, c);
|
||||
}
|
||||
|
||||
/* XXX: stpcpy, memccpy */
|
|
@ -0,0 +1,36 @@
|
|||
diff -rup gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-4.2/libstdc++-v3/config/locale/uclibc/messages_members.h
|
||||
--- gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/messages_members.h 2006-12-22 13:06:56.000000000 +0100
|
||||
+++ gcc-4.2/libstdc++-v3/config/locale/uclibc/messages_members.h 2006-12-22 15:23:41.000000000 +0100
|
||||
@@ -32,7 +32,8 @@
|
||||
//
|
||||
|
||||
// Written by Benjamin Kosnik <bkoz@redhat.com>
|
||||
-
|
||||
+namespace std
|
||||
+{
|
||||
#ifdef __UCLIBC_MJN3_ONLY__
|
||||
#warning fix prototypes for *textdomain funcs
|
||||
#endif
|
||||
@@ -115,3 +116,4 @@
|
||||
this->_S_create_c_locale(this->_M_c_locale_messages, __s);
|
||||
}
|
||||
}
|
||||
+}
|
||||
diff -rup gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/time_members.h gcc-4.2/libstdc++-v3/config/locale/uclibc/time_members.h
|
||||
--- gcc-4.2.orig/libstdc++-v3/config/locale/uclibc/time_members.h 2006-12-22 13:06:56.000000000 +0100
|
||||
+++ gcc-4.2/libstdc++-v3/config/locale/uclibc/time_members.h 2006-12-22 15:20:31.000000000 +0100
|
||||
@@ -33,7 +33,8 @@
|
||||
//
|
||||
|
||||
// Written by Benjamin Kosnik <bkoz@redhat.com>
|
||||
-
|
||||
+namespace std
|
||||
+{
|
||||
template<typename _CharT>
|
||||
__timepunct<_CharT>::__timepunct(size_t __refs)
|
||||
: facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL),
|
||||
@@ -74,3 +75,4 @@
|
||||
delete _M_data;
|
||||
_S_destroy_c_locale(_M_c_locale_timepunct);
|
||||
}
|
||||
+}
|
|
@ -0,0 +1,26 @@
|
|||
This patch fixes a bug into ostream::operator<<(double) due to the wrong size
|
||||
passed into the __convert_from_v method. The wrong size is then passed to
|
||||
std::snprintf function, that, on uClibc, doens't handle sized 0 buffer.
|
||||
|
||||
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
||||
|
||||
--- gcc-4.2.1/libstdc++-v3/include/bits/locale_facets.tcc 2006-10-17 18:43:47.000000000 +0200
|
||||
+++ gcc-4.2.1-st/libstdc++-v3/include/bits/locale_facets.tcc 2007-08-22 18:54:23.000000000 +0200
|
||||
@@ -1143,7 +1143,7 @@ _GLIBCXX_BEGIN_LDBL_NAMESPACE
|
||||
const int __cs_size = __fixed ? __max_exp + __prec + 4
|
||||
: __max_digits * 2 + __prec;
|
||||
char* __cs = static_cast<char*>(__builtin_alloca(__cs_size));
|
||||
- __len = std::__convert_from_v(_S_get_c_locale(), __cs, 0, __fbuf,
|
||||
+ __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, __fbuf,
|
||||
__prec, __v);
|
||||
#endif
|
||||
|
||||
@@ -1777,7 +1777,7 @@ _GLIBCXX_BEGIN_LDBL_NAMESPACE
|
||||
// max_exponent10 + 1 for the integer part, + 2 for sign and '\0'.
|
||||
const int __cs_size = numeric_limits<long double>::max_exponent10 + 3;
|
||||
char* __cs = static_cast<char*>(__builtin_alloca(__cs_size));
|
||||
- int __len = std::__convert_from_v(_S_get_c_locale(), __cs, 0, "%.*Lf",
|
||||
+ int __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, "%.*Lf",
|
||||
0, __units);
|
||||
#endif
|
||||
string_type __digits(__len, char_type());
|
|
@ -0,0 +1,13 @@
|
|||
Index: gcc-4.2/gcc/Makefile.in
|
||||
===================================================================
|
||||
--- gcc-4.2/gcc/Makefile.in (revision 121758)
|
||||
+++ gcc-4.2/gcc/Makefile.in (working copy)
|
||||
@@ -2658,7 +2658,7 @@ mips-tdump.o : mips-tdump.c $(CONFIG_H)
|
||||
# FIXME: writing proper dependencies for this is a *LOT* of work.
|
||||
libbackend.o : $(OBJS-common:.o=.c) $(out_file) \
|
||||
insn-config.h insn-flags.h insn-codes.h insn-constants.h \
|
||||
- insn-attr.h $(DATESTAMP) $(BASEVER) $(DEVPHASE)
|
||||
+ insn-attr.h $(DATESTAMP) $(BASEVER) $(DEVPHASE) gcov-iov.h
|
||||
$(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) \
|
||||
-DTARGET_NAME=\"$(target_noncanonical)\" \
|
||||
-DLOCALEDIR=\"$(localedir)\" \
|
|
@ -0,0 +1,20 @@
|
|||
--- gcc-4.1.0/libstdc++-v3/fragment.am 2005-03-21 11:40:14.000000000 -0600
|
||||
+++ gcc-4.1.0-patched/libstdc++-v3/fragment.am 2005-04-25 20:14:39.856251785 -0500
|
||||
@@ -21,5 +21,5 @@
|
||||
$(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once
|
||||
|
||||
# -I/-D flags to pass when compiling.
|
||||
-AM_CPPFLAGS = $(GLIBCXX_INCLUDES)
|
||||
+AM_CPPFLAGS = $(GLIBCXX_INCLUDES) -I$(toplevel_srcdir)/include
|
||||
|
||||
--- gcc-4.1.0/libstdc++-v3/libmath/Makefile.am 2005-03-21 11:40:18.000000000 -0600
|
||||
+++ gcc-4.1.0-patched/libstdc++-v3/libmath/Makefile.am 2005-04-25 20:14:39.682280735 -0500
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
libmath_la_SOURCES = stubs.c
|
||||
|
||||
-AM_CPPFLAGS = $(CANADIAN_INCLUDES)
|
||||
+AM_CPPFLAGS = $(CANADIAN_INCLUDES) -I$(toplevel_srcdir)/include
|
||||
|
||||
# Only compiling "C" sources in this directory.
|
||||
LIBTOOL = @LIBTOOL@ --tag CC
|
|
@ -0,0 +1,25 @@
|
|||
http://sourceforge.net/mailarchive/forum.php?thread_id=8959304&forum_id=5348
|
||||
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24836
|
||||
|
||||
--- gcc/gcc/configure.ac (revision 106699)
|
||||
+++ gcc/gcc/configure.ac (working copy)
|
||||
@@ -2446,7 +2446,7 @@
|
||||
tls_first_minor=14
|
||||
tls_as_opt="-m64 -Aesame --fatal-warnings"
|
||||
;;
|
||||
- sh-*-* | sh[34]-*-*)
|
||||
+ sh-*-* | sh[34]*-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
foo: .long 25
|
||||
--- gcc/gcc/configure
|
||||
+++ gcc/gcc/configure
|
||||
@@ -14846,7 +14846,7 @@
|
||||
tls_first_minor=14
|
||||
tls_as_opt="-m64 -Aesame --fatal-warnings"
|
||||
;;
|
||||
- sh-*-* | sh[34]-*-*)
|
||||
+ sh-*-* | sh[34]*-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
foo: .long 25
|
|
@ -0,0 +1,67 @@
|
|||
By Lennert Buytenhek <buytenh@wantstofly.org>
|
||||
Adds support for arm*b-linux* big-endian ARM targets
|
||||
|
||||
See http://gcc.gnu.org/PR16350
|
||||
|
||||
--- gcc-4.2.0/gcc/config/arm/linux-elf.h
|
||||
+++ gcc-4.2.0/gcc/config/arm/linux-elf.h
|
||||
@@ -28,19 +28,33 @@
|
||||
#undef TARGET_VERSION
|
||||
#define TARGET_VERSION fputs (" (ARM GNU/Linux with ELF)", stderr);
|
||||
|
||||
+/*
|
||||
+ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-*
|
||||
+ * (big endian) configurations.
|
||||
+ */
|
||||
+#if TARGET_BIG_ENDIAN_DEFAULT
|
||||
+#define TARGET_ENDIAN_DEFAULT MASK_BIG_END
|
||||
+#define TARGET_ENDIAN_OPTION "mbig-endian"
|
||||
+#define TARGET_LINKER_EMULATION "armelfb_linux"
|
||||
+#else
|
||||
+#define TARGET_ENDIAN_DEFAULT 0
|
||||
+#define TARGET_ENDIAN_OPTION "mlittle-endian"
|
||||
+#define TARGET_LINKER_EMULATION "armelf_linux"
|
||||
+#endif
|
||||
+
|
||||
#undef TARGET_DEFAULT_FLOAT_ABI
|
||||
#define TARGET_DEFAULT_FLOAT_ABI ARM_FLOAT_ABI_HARD
|
||||
|
||||
#undef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT (0)
|
||||
+#define TARGET_DEFAULT (TARGET_ENDIAN_DEFAULT)
|
||||
|
||||
#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6
|
||||
|
||||
-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux -p"
|
||||
+#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION " -p"
|
||||
|
||||
#undef MULTILIB_DEFAULTS
|
||||
#define MULTILIB_DEFAULTS \
|
||||
- { "marm", "mlittle-endian", "mhard-float", "mno-thumb-interwork" }
|
||||
+ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mno-thumb-interwork" }
|
||||
|
||||
/* Now we define the strings used to build the spec file. */
|
||||
#undef LIB_SPEC
|
||||
@@ -61,7 +75,7 @@
|
||||
%{rdynamic:-export-dynamic} \
|
||||
%{!dynamic-linker:-dynamic-linker " LINUX_DYNAMIC_LINKER "} \
|
||||
-X \
|
||||
- %{mbig-endian:-EB}" \
|
||||
+ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \
|
||||
SUBTARGET_EXTRA_LINK_SPEC
|
||||
|
||||
#undef LINK_SPEC
|
||||
--- gcc-4.2.0/gcc/config.gcc.orig 2006-09-22 14:53:41.000000000 +0200
|
||||
+++ gcc-4.2.0/gcc/config.gcc 2006-09-25 10:45:21.000000000 +0200
|
||||
@@ -696,6 +696,11 @@
|
||||
tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h"
|
||||
tmake_file="${tmake_file} t-linux arm/t-arm"
|
||||
case ${target} in
|
||||
+ arm*b-*)
|
||||
+ tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
|
||||
+ ;;
|
||||
+ esac
|
||||
+ case ${target} in
|
||||
arm*-*-linux-*eabi)
|
||||
tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h"
|
||||
tmake_file="$tmake_file arm/t-arm-elf arm/t-bpabi arm/t-linux-eabi"
|
|
@ -0,0 +1,14 @@
|
|||
Index: gcc-4.1.1/gcc/config/arm/linux-eabi.h
|
||||
===================================================================
|
||||
--- gcc-4.1.1.orig/gcc/config/arm/linux-eabi.h 2007-02-20 14:51:33.416193250 +0100
|
||||
+++ gcc-4.1.1/gcc/config/arm/linux-eabi.h 2007-02-20 14:52:11.622581000 +0100
|
||||
@@ -48,7 +48,8 @@
|
||||
#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm9tdmi
|
||||
|
||||
#undef SUBTARGET_EXTRA_LINK_SPEC
|
||||
-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux_eabi"
|
||||
+#define SUBTARGET_EXTRA_LINK_SPEC \
|
||||
+ " %{mbig-endian:-m armelfb_linux_eabi} %{mlittle-endian:-m armelf_linux_eabi} "
|
||||
|
||||
/* Use ld-linux.so.3 so that it will be possible to run "classic"
|
||||
GNU/Linux binaries on an EABI system. */
|
|
@ -0,0 +1,153 @@
|
|||
Hi,
|
||||
|
||||
The attached patch makes sure that we create smaller object code for
|
||||
simple switch statements. We just make sure to flatten the switch
|
||||
statement into an if-else chain, basically.
|
||||
|
||||
This fixes a size-regression as compared to gcc-3.4, as can be seen
|
||||
below.
|
||||
|
||||
2007-04-15 Bernhard Fischer <..>
|
||||
|
||||
* stmt.c (expand_case): Do not create a complex binary tree when
|
||||
optimizing for size but rather use the simple ordered list.
|
||||
(emit_case_nodes): do not emit jumps to the default_label when
|
||||
optimizing for size.
|
||||
|
||||
Not regtested so far.
|
||||
Comments?
|
||||
|
||||
Attached is the test switch.c mentioned below.
|
||||
|
||||
$ for i in 2.95 3.3 3.4 4.0 4.1 4.2.orig-HEAD 4.3.orig-HEAD 4.3-HEAD;do
|
||||
gcc-$i -DCHAIN -Os -o switch-CHAIN-$i.o -c switch.c ;done
|
||||
$ for i in 2.95 3.3 3.4 4.0 4.1 4.2.orig-HEAD 4.3.orig-HEAD 4.3-HEAD;do
|
||||
gcc-$i -UCHAIN -Os -o switch-$i.o -c switch.c ;done
|
||||
|
||||
$ size switch-*.o
|
||||
text data bss dec hex filename
|
||||
169 0 0 169 a9 switch-2.95.o
|
||||
115 0 0 115 73 switch-3.3.o
|
||||
103 0 0 103 67 switch-3.4.o
|
||||
124 0 0 124 7c switch-4.0.o
|
||||
124 0 0 124 7c switch-4.1.o
|
||||
124 0 0 124 7c switch-4.2.orig-HEAD.o
|
||||
95 0 0 95 5f switch-4.3-HEAD.o
|
||||
124 0 0 124 7c switch-4.3.orig-HEAD.o
|
||||
166 0 0 166 a6 switch-CHAIN-2.95.o
|
||||
111 0 0 111 6f switch-CHAIN-3.3.o
|
||||
95 0 0 95 5f switch-CHAIN-3.4.o
|
||||
95 0 0 95 5f switch-CHAIN-4.0.o
|
||||
95 0 0 95 5f switch-CHAIN-4.1.o
|
||||
95 0 0 95 5f switch-CHAIN-4.2.orig-HEAD.o
|
||||
95 0 0 95 5f switch-CHAIN-4.3-HEAD.o
|
||||
95 0 0 95 5f switch-CHAIN-4.3.orig-HEAD.o
|
||||
|
||||
|
||||
Content-Type: text/x-diff; charset=us-ascii
|
||||
Content-Disposition: attachment; filename="gcc-4.3.gcc-flatten-switch-stmt.00.diff"
|
||||
|
||||
Index: gcc-4.2.0/gcc/stmt.c
|
||||
===================================================================
|
||||
--- gcc-4.2.0.orig/gcc/stmt.c (revision 123843)
|
||||
+++ gcc-4.2.0/gcc/stmt.c (working copy)
|
||||
@@ -2517,7 +2517,11 @@ expand_case (tree exp)
|
||||
use_cost_table
|
||||
= (TREE_CODE (orig_type) != ENUMERAL_TYPE
|
||||
&& estimate_case_costs (case_list));
|
||||
- balance_case_nodes (&case_list, NULL);
|
||||
+ /* When optimizing for size, we want a straight list to avoid
|
||||
+ jumps as much as possible. This basically creates an if-else
|
||||
+ chain. */
|
||||
+ if (!optimize_size)
|
||||
+ balance_case_nodes (&case_list, NULL);
|
||||
emit_case_nodes (index, case_list, default_label, index_type);
|
||||
emit_jump (default_label);
|
||||
}
|
||||
@@ -3075,6 +3079,7 @@ emit_case_nodes (rtx index, case_node_pt
|
||||
{
|
||||
if (!node_has_low_bound (node, index_type))
|
||||
{
|
||||
+ if (!optimize_size) /* don't jl to the .default_label. */
|
||||
emit_cmp_and_jump_insns (index,
|
||||
convert_modes
|
||||
(mode, imode,
|
||||
|
||||
|
||||
Content-Type: text/x-csrc; charset=us-ascii
|
||||
Content-Disposition: attachment; filename="switch.c"
|
||||
|
||||
int
|
||||
commutative_tree_code (int code)
|
||||
{
|
||||
#define CASE(val, ret) case val:/* __asm__("# val="#val ",ret="#ret);*/ return ret;
|
||||
#ifndef CHAIN
|
||||
switch (code)
|
||||
{
|
||||
# if 1
|
||||
CASE(1,3)
|
||||
CASE(3,2)
|
||||
CASE(5,8)
|
||||
CASE(7,1)
|
||||
CASE(33,4)
|
||||
CASE(44,9)
|
||||
CASE(55,10)
|
||||
CASE(66,-1)
|
||||
CASE(77,99)
|
||||
CASE(666,0)
|
||||
# else
|
||||
case 1:
|
||||
return 3;
|
||||
case 3:
|
||||
return 2;
|
||||
case 5:
|
||||
return 8;
|
||||
case 7:
|
||||
return 1;
|
||||
case 33:
|
||||
return 4;
|
||||
case 44:
|
||||
return 9;
|
||||
case 55:
|
||||
return 10;
|
||||
case 66:
|
||||
return -1;
|
||||
case 77:
|
||||
return 99;
|
||||
case 666:
|
||||
return 0;
|
||||
# endif
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return 4711;
|
||||
|
||||
#else
|
||||
if (code == 1)
|
||||
return 3;
|
||||
else if (code == 3)
|
||||
return 2;
|
||||
else if (code == 5)
|
||||
return 8;
|
||||
else if (code == 7)
|
||||
return 1;
|
||||
else if (code == 33)
|
||||
return 4;
|
||||
else if (code == 44)
|
||||
return 9;
|
||||
else if (code == 55)
|
||||
return 10;
|
||||
else if (code == 66)
|
||||
return -1;
|
||||
else if (code == 77)
|
||||
return 99;
|
||||
else if (code == 666)
|
||||
return 0;
|
||||
else
|
||||
return 4711;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
--AhhlLboLdkugWU4S--
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
# Dimitry Andric <dimitry@andric.com>, 2004-05-01
|
||||
#
|
||||
# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed
|
||||
# anymore. (The required functions are now in libgcc.)
|
||||
#
|
||||
# Fixes errors like
|
||||
# arm-softfloat-linux-gnu/3.4.0/../../../../arm-softfloat-linux-gnu/bin/ld: cannot find -lfloat
|
||||
# collect2: ld returned 1 exit status
|
||||
# make[2]: *** [arm-softfloat-linux-gnu/gcc-3.4.0-glibc-2.3.2/build-glibc/iconvdata/ISO8859-1.so] Error 1
|
||||
# when building glibc-2.3.3 with gcc-3.4.0 for arm-softfloat
|
||||
|
||||
Index: gcc-4.0.2/gcc/config/arm/linux-elf.h
|
||||
===================================================================
|
||||
--- gcc-4.0.2.orig/gcc/config/arm/linux-elf.h 2005-03-04 16:14:01.000000000 +0000
|
||||
+++ gcc-4.0.2/gcc/config/arm/linux-elf.h 2005-11-11 18:02:54.000000000 +0000
|
||||
@@ -56,7 +56,7 @@
|
||||
%{shared:-lc} \
|
||||
%{!shared:%{profile:-lc_p}%{!profile:-lc}}"
|
||||
|
||||
-#define LIBGCC_SPEC "%{msoft-float:-lfloat} %{mfloat-abi=soft*:-lfloat} -lgcc"
|
||||
+#define LIBGCC_SPEC "-lgcc"
|
||||
|
||||
/* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add
|
||||
the GNU/Linux magical crtbegin.o file (see crtstuff.c) which
|
|
@ -0,0 +1,16 @@
|
|||
Index: gcc-4.0.2/gcc/config/arm/t-linux
|
||||
===================================================================
|
||||
--- gcc-4.0.2.orig/gcc/config/arm/t-linux 2004-05-15 12:41:35.000000000 +0000
|
||||
+++ gcc-4.0.2/gcc/config/arm/t-linux 2005-11-11 16:07:53.000000000 +0000
|
||||
@@ -4,7 +4,10 @@
|
||||
LIBGCC2_DEBUG_CFLAGS = -g0
|
||||
|
||||
LIB1ASMSRC = arm/lib1funcs.asm
|
||||
-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx
|
||||
+LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \
|
||||
+ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \
|
||||
+ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \
|
||||
+ _fixsfsi _fixunssfsi _floatdidf _floatdisf _floatundisf _floatundidf
|
||||
|
||||
# MULTILIB_OPTIONS = mhard-float/msoft-float
|
||||
# MULTILIB_DIRNAMES = hard-float soft-float
|
|
@ -0,0 +1,29 @@
|
|||
--- gcc-4.1.1/gcc/config/arm/linux-gas.h- 2005-06-25 03:22:41.000000000 +0200
|
||||
+++ gcc-4.1.1/gcc/config/arm/linux-gas.h 2006-06-18 10:23:46.000000000 +0200
|
||||
@@ -44,6 +44,7 @@
|
||||
|
||||
/* Clear the instruction cache from `beg' to `end'. This makes an
|
||||
inline system call to SYS_cacheflush. */
|
||||
+#if !defined(__thumb__)
|
||||
#define CLEAR_INSN_CACHE(BEG, END) \
|
||||
{ \
|
||||
register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \
|
||||
@@ -53,3 +54,18 @@
|
||||
: "=r" (_beg) \
|
||||
: "0" (_beg), "r" (_end), "r" (_flg)); \
|
||||
}
|
||||
+#else
|
||||
+#define CLEAR_INSN_CACHE(BEG, END) \
|
||||
+{ \
|
||||
+ register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \
|
||||
+ register unsigned long _end __asm ("a2") = (unsigned long) (END); \
|
||||
+ register unsigned long _flg __asm ("a3") = 0; \
|
||||
+ register unsigned long _swi __asm ("a4") = 0xf0002; \
|
||||
+ __asm __volatile ("push {r7}\n" \
|
||||
+ " mov r7,a4\n" \
|
||||
+ " swi 0 @ sys_cacheflush\n" \
|
||||
+ " pop {r7}\n" \
|
||||
+ : "=r" (_beg) \
|
||||
+ : "0" (_beg), "r" (_end), "r" (_flg), "r" (_swi)); \
|
||||
+}
|
||||
+#endif
|
|
@ -0,0 +1,64 @@
|
|||
|
||||
#
|
||||
# Patch managed by http://www.holgerschurig.de/patcher.html
|
||||
#
|
||||
|
||||
--- gcc-4.1.1/gcc/config/arm/lib1funcs.asm~gcc
|
||||
+++ gcc-4.1.1/gcc/config/arm/lib1funcs.asm
|
||||
@@ -995,10 +995,24 @@
|
||||
.code 32
|
||||
FUNC_START div0
|
||||
|
||||
+#if ! defined __thumb__
|
||||
stmfd sp!, {r1, lr}
|
||||
mov r0, #SIGFPE
|
||||
bl SYM(raise) __PLT__
|
||||
RETLDM r1
|
||||
+#else
|
||||
+ push {r1, lr}
|
||||
+ mov r0, #SIGFPE
|
||||
+ bl SYM(raise) __PLT__
|
||||
+#if __ARM_ARCH__ > 4
|
||||
+ pop {r1, pc}
|
||||
+#else
|
||||
+ @ on 4T that won't work
|
||||
+ pop {r1}
|
||||
+ pop {r3}
|
||||
+ bx r3
|
||||
+#endif
|
||||
+#endif
|
||||
|
||||
FUNC_END div0
|
||||
|
||||
@@ -1141,11 +1155,12 @@
|
||||
code here switches to the correct mode before executing the function. */
|
||||
|
||||
.text
|
||||
- .align 0
|
||||
+ .align 1
|
||||
.force_thumb
|
||||
|
||||
.macro call_via register
|
||||
THUMB_FUNC_START _call_via_\register
|
||||
+ .hidden SYM (_call_via_\register)
|
||||
|
||||
bx \register
|
||||
nop
|
||||
@@ -1242,6 +1257,7 @@
|
||||
.code 16
|
||||
|
||||
THUMB_FUNC_START _interwork_call_via_\register
|
||||
+ .hidden SYM (_interwork_call_via_\register)
|
||||
|
||||
bx pc
|
||||
nop
|
||||
--- gcc-4.1.1/gcc/config/arm/t-linux~gcc
|
||||
+++ gcc-4.1.1/gcc/config/arm/t-linux
|
||||
@@ -7,6 +7,7 @@
|
||||
LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \
|
||||
_negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \
|
||||
_truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \
|
||||
+ _call_via_rX \
|
||||
_fixsfsi _fixunssfsi _floatdidf _floatdisf _floatundisf _floatundidf
|
||||
|
||||
# MULTILIB_OPTIONS = mhard-float/msoft-float
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/gcc/configure b/gcc/configure
|
||||
index 44620ab..6e1830c 100755
|
||||
--- a/gcc/configure
|
||||
+++ b/gcc/configure
|
||||
@@ -12272,7 +12272,7 @@ else
|
||||
esac
|
||||
saved_CFLAGS="${CFLAGS}"
|
||||
CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
|
||||
- ${realsrcdir}/configure \
|
||||
+ CONFIG_SITE= ${realsrcdir}/configure --cache-file=./other.cache \
|
||||
--enable-languages=${enable_languages-all} \
|
||||
--target=$target_alias --host=$build_alias --build=$build_alias
|
||||
CFLAGS="${saved_CFLAGS}"
|
|
@ -0,0 +1,28 @@
|
|||
--- /tmp/arm.c 2008-03-17 14:24:39.590464969 +0100
|
||||
+++ gcc-4.3.0/gcc/config/arm/arm.c 2008-03-17 14:12:21.614701982 +0100
|
||||
@@ -15959,6 +15959,9 @@
|
||||
int regno;
|
||||
int lo_mask = mask & 0xFF;
|
||||
int pushed_words = 0;
|
||||
+ rtx e0;
|
||||
+ rtx e1;
|
||||
+ unsigned reg;
|
||||
|
||||
gcc_assert (mask);
|
||||
|
||||
@@ -16025,6 +16028,15 @@
|
||||
|
||||
return;
|
||||
}
|
||||
+ else if (GET_CODE (e1) == PLUS
|
||||
+ && GET_CODE (XEXP (e1, 0)) == REG
|
||||
+ && REGNO (XEXP (e1, 0)) == SP_REGNUM
|
||||
+ && GET_CODE (XEXP (e1, 1)) == CONST_INT)
|
||||
+ {
|
||||
+ /* Set reg to offset from sp. */
|
||||
+ asm_fprintf (asm_out_file, "\t.movsp %r, #%d\n",
|
||||
+ REGNO (e0), (int)INTVAL(XEXP (e1, 1)));
|
||||
+ }
|
||||
else
|
||||
{
|
||||
if (mask & 0xFF)
|
|
@ -0,0 +1,30 @@
|
|||
* Fortran would have searched for arm-angstrom-gnueabi-gfortran but would have used
|
||||
used gfortan. For gcc_4.2.2.bb we want to use the gfortran compiler from our cross
|
||||
directory.
|
||||
|
||||
diff --git a/libgfortran/configure b/libgfortran/configure
|
||||
index f7d86fb..d0966ec 100755
|
||||
--- a/libgfortran/configure
|
||||
+++ b/libgfortran/configure
|
||||
@@ -4475,6 +4475,6 @@ exec 5>>./config.log
|
||||
|
||||
# We need gfortran to compile parts of the library
|
||||
#AC_PROG_FC(gfortran)
|
||||
-FC="$GFORTRAN"
|
||||
+#FC="$GFORTRAN"
|
||||
ac_ext=${FC_SRCEXT-f}
|
||||
ac_compile='$FC -c $FCFLAGS $FCFLAGS_SRCEXT conftest.$ac_ext >&5'
|
||||
\ No newline at end of file
|
||||
diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
|
||||
index 4661306..9f83e55 100644
|
||||
--- a/libgfortran/configure.ac
|
||||
+++ b/libgfortran/configure.ac
|
||||
@@ -140,7 +140,7 @@ AC_SUBST(enable_static)
|
||||
|
||||
# We need gfortran to compile parts of the library
|
||||
#AC_PROG_FC(gfortran)
|
||||
-FC="$GFORTRAN"
|
||||
+#FC="$GFORTRAN"
|
||||
AC_PROG_FC(gfortran)
|
||||
|
||||
# extra LD Flags which are required for targets
|
|
@ -0,0 +1,48 @@
|
|||
f951 (fortran) links to MPFR and GMP of our staging area but when executing
|
||||
the command the libs can not be found. Use rpath like all the other apps in
|
||||
our staging bin/ directory.
|
||||
|
||||
Patch the configure to avoid the regeneration...
|
||||
|
||||
Index: gcc-4.2.2/configure
|
||||
===================================================================
|
||||
--- gcc-4.2.2.orig/configure 2008-01-15 23:23:41.000000000 +0100
|
||||
+++ gcc-4.2.2/configure 2008-01-15 23:25:20.000000000 +0100
|
||||
@@ -2278,14 +2278,14 @@
|
||||
|
||||
|
||||
if test "x$with_mpfr" != x; then
|
||||
- gmplibs="-L$with_mpfr/lib $gmplibs"
|
||||
+ gmplibs="-static -L$with_mpfr/lib $gmplibs"
|
||||
gmpinc="-I$with_mpfr/include"
|
||||
fi
|
||||
if test "x$with_mpfr_include" != x; then
|
||||
gmpinc="-I$with_mpfr_include"
|
||||
fi
|
||||
if test "x$with_mpfr_lib" != x; then
|
||||
- gmplibs="-L$with_mpfr_lib $gmplibs"
|
||||
+ gmplibs="-static -L$with_mpfr_lib $gmplibs"
|
||||
fi
|
||||
|
||||
# Specify a location for gmp
|
||||
Index: gcc-4.2.2/configure.in
|
||||
===================================================================
|
||||
--- gcc-4.2.2.orig/configure.in 2008-01-15 23:23:41.000000000 +0100
|
||||
+++ gcc-4.2.2/configure.in 2008-01-15 23:24:36.000000000 +0100
|
||||
@@ -1066,14 +1066,14 @@
|
||||
AC_ARG_WITH(mpfr_lib, [ --with-mpfr-lib=PATH Specify the directory for the installed MPFR library])
|
||||
|
||||
if test "x$with_mpfr" != x; then
|
||||
- gmplibs="-L$with_mpfr/lib $gmplibs"
|
||||
+ gmplibs="-static -L$with_mpfr/lib $gmplibs"
|
||||
gmpinc="-I$with_mpfr/include"
|
||||
fi
|
||||
if test "x$with_mpfr_include" != x; then
|
||||
gmpinc="-I$with_mpfr_include"
|
||||
fi
|
||||
if test "x$with_mpfr_lib" != x; then
|
||||
- gmplibs="-L$with_mpfr_lib $gmplibs"
|
||||
+ gmplibs="-static -L$with_mpfr_lib $gmplibs"
|
||||
fi
|
||||
|
||||
# Specify a location for gmp
|
|
@ -0,0 +1,311 @@
|
|||
Adds support for Freescale Power architecture e300c2 and e300c3 cores.
|
||||
http://www.bitshrine.org/gpp/tc-fsl-x86lnx-e300c3-nptl-4.0.2-2.src.rpm
|
||||
|
||||
Leon Woestenberg <leonw@mailcan.com>
|
||||
|
||||
Index: gcc-4.1.2/gcc/config/rs6000/e300c2c3.md
|
||||
===================================================================
|
||||
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
+++ gcc-4.1.2/gcc/config/rs6000/e300c2c3.md 2007-10-18 15:32:51.000000000 +0200
|
||||
@@ -0,0 +1,189 @@
|
||||
+;; Pipeline description for Motorola PowerPC e300c3 core.
|
||||
+;; Copyright (C) 2003 Free Software Foundation, Inc.
|
||||
+;;
|
||||
+;; This file is part of GCC.
|
||||
+
|
||||
+;; GCC is free software; you can redistribute it and/or modify it
|
||||
+;; under the terms of the GNU General Public License as published
|
||||
+;; by the Free Software Foundation; either version 2, or (at your
|
||||
+;; option) any later version.
|
||||
+
|
||||
+;; GCC is distributed in the hope that it will be useful, but WITHOUT
|
||||
+;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||
+;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
|
||||
+;; License for more details.
|
||||
+
|
||||
+;; You should have received a copy of the GNU General Public License
|
||||
+;; along with GCC; see the file COPYING. If not, write to the
|
||||
+;; Free Software Foundation, 59 Temple Place - Suite 330, Boston,
|
||||
+;; MA 02111-1307, USA.
|
||||
+
|
||||
+(define_automaton "ppce300c3_most,ppce300c3_long,ppce300c3_retire")
|
||||
+(define_cpu_unit "ppce300c3_decode_0,ppce300c3_decode_1" "ppce300c3_most")
|
||||
+
|
||||
+;; We don't simulate general issue queue (GIC). If we have SU insn
|
||||
+;; and then SU1 insn, they can not be issued on the same cycle
|
||||
+;; (although SU1 insn and then SU insn can be issued) because the SU
|
||||
+;; insn will go to SU1 from GIC0 entry. Fortunately, the first cycle
|
||||
+;; multipass insn scheduling will find the situation and issue the SU1
|
||||
+;; insn and then the SU insn.
|
||||
+(define_cpu_unit "ppce300c3_issue_0,ppce300c3_issue_1" "ppce300c3_most")
|
||||
+
|
||||
+;; We could describe completion buffers slots in combination with the
|
||||
+;; retirement units and the order of completion but the result
|
||||
+;; automaton would behave in the same way because we can not describe
|
||||
+;; real latency time with taking in order completion into account.
|
||||
+;; Actually we could define the real latency time by querying reserved
|
||||
+;; automaton units but the current scheduler uses latency time before
|
||||
+;; issuing insns and making any reservations.
|
||||
+;;
|
||||
+;; So our description is aimed to achieve a insn schedule in which the
|
||||
+;; insns would not wait in the completion buffer.
|
||||
+(define_cpu_unit "ppce300c3_retire_0,ppce300c3_retire_1" "ppce300c3_retire")
|
||||
+
|
||||
+;; Branch unit:
|
||||
+(define_cpu_unit "ppce300c3_bu" "ppce300c3_most")
|
||||
+
|
||||
+;; IU:
|
||||
+(define_cpu_unit "ppce300c3_iu0_stage0,ppce300c3_iu1_stage0" "ppce300c3_most")
|
||||
+
|
||||
+;; IU: This used to describe non-pipelined division.
|
||||
+(define_cpu_unit "ppce300c3_mu_div" "ppce300c3_long")
|
||||
+
|
||||
+;; SRU:
|
||||
+(define_cpu_unit "ppce300c3_sru_stage0" "ppce300c3_most")
|
||||
+
|
||||
+;; Here we simplified LSU unit description not describing the stages.
|
||||
+(define_cpu_unit "ppce300c3_lsu" "ppce300c3_most")
|
||||
+
|
||||
+;; FPU:
|
||||
+(define_cpu_unit "ppce300c3_fpu" "ppce300c3_most")
|
||||
+
|
||||
+;; The following units are used to make automata deterministic
|
||||
+(define_cpu_unit "present_ppce300c3_decode_0" "ppce300c3_most")
|
||||
+(define_cpu_unit "present_ppce300c3_issue_0" "ppce300c3_most")
|
||||
+(define_cpu_unit "present_ppce300c3_retire_0" "ppce300c3_retire")
|
||||
+(define_cpu_unit "present_ppce300c3_iu0_stage0" "ppce300c3_most")
|
||||
+
|
||||
+;; The following sets to make automata deterministic when option ndfa is used.
|
||||
+(presence_set "present_ppce300c3_decode_0" "ppce300c3_decode_0")
|
||||
+(presence_set "present_ppce300c3_issue_0" "ppce300c3_issue_0")
|
||||
+(presence_set "present_ppce300c3_retire_0" "ppce300c3_retire_0")
|
||||
+(presence_set "present_ppce300c3_iu0_stage0" "ppce300c3_iu0_stage0")
|
||||
+
|
||||
+;; Some useful abbreviations.
|
||||
+(define_reservation "ppce300c3_decode"
|
||||
+ "ppce300c3_decode_0|ppce300c3_decode_1+present_ppce300c3_decode_0")
|
||||
+(define_reservation "ppce300c3_issue"
|
||||
+ "ppce300c3_issue_0|ppce300c3_issue_1+present_ppce300c3_issue_0")
|
||||
+(define_reservation "ppce300c3_retire"
|
||||
+ "ppce300c3_retire_0|ppce300c3_retire_1+present_ppce300c3_retire_0")
|
||||
+(define_reservation "ppce300c3_iu_stage0"
|
||||
+ "ppce300c3_iu0_stage0|ppce300c3_iu1_stage0+present_ppce300c3_iu0_stage0")
|
||||
+
|
||||
+;; Compares can be executed either one of the IU or SRU
|
||||
+(define_insn_reservation "ppce300c3_cmp" 1
|
||||
+ (and (eq_attr "type" "cmp,compare,delayed_compare,fast_compare")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+(ppce300c3_iu_stage0|ppce300c3_sru_stage0) \
|
||||
+ +ppce300c3_retire")
|
||||
+
|
||||
+;; Other one cycle IU insns
|
||||
+(define_insn_reservation "ppce300c3_iu" 1
|
||||
+ (and (eq_attr "type" "integer,insert_word")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_iu_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Branch. Actually this latency time is not used by the scheduler.
|
||||
+(define_insn_reservation "ppce300c3_branch" 1
|
||||
+ (and (eq_attr "type" "jmpreg,branch")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_bu,ppce300c3_retire")
|
||||
+
|
||||
+;; Multiply is non-pipelined but can be executed in any IU
|
||||
+(define_insn_reservation "ppce300c3_multiply" 2
|
||||
+ (and (eq_attr "type" "imul,imul2,imul3,imul_compare")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_iu_stage0, \
|
||||
+ ppce300c3_iu_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Divide. We use the average latency time here. We omit reserving a
|
||||
+;; retire unit because of the result automata will be huge.
|
||||
+(define_insn_reservation "ppce300c3_divide" 20
|
||||
+ (and (eq_attr "type" "idiv")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_iu_stage0+ppce300c3_mu_div,\
|
||||
+ ppce300c3_mu_div*19")
|
||||
+
|
||||
+;; CR logical
|
||||
+(define_insn_reservation "ppce300c3_cr_logical" 1
|
||||
+ (and (eq_attr "type" "cr_logical,delayed_cr")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_sru_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Mfcr
|
||||
+(define_insn_reservation "ppce300c3_mfcr" 1
|
||||
+ (and (eq_attr "type" "mfcr")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_sru_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Mtcrf
|
||||
+(define_insn_reservation "ppce300c3_mtcrf" 1
|
||||
+ (and (eq_attr "type" "mtcr")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_sru_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Mtjmpr
|
||||
+(define_insn_reservation "ppce300c3_mtjmpr" 1
|
||||
+ (and (eq_attr "type" "mtjmpr,mfjmpr")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_sru_stage0+ppce300c3_retire")
|
||||
+
|
||||
+;; Float point instructions
|
||||
+(define_insn_reservation "ppce300c3_fpcompare" 3
|
||||
+ (and (eq_attr "type" "fpcompare")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_fpu,nothing,ppce300c3_retire")
|
||||
+
|
||||
+(define_insn_reservation "ppce300c3_fp" 3
|
||||
+ (and (eq_attr "type" "fp")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_fpu,nothing,ppce300c3_retire")
|
||||
+
|
||||
+(define_insn_reservation "ppce300c3_dmul" 4
|
||||
+ (and (eq_attr "type" "dmul")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_fpu,ppce300c3_fpu,nothing,ppce300c3_retire")
|
||||
+
|
||||
+; Divides are not pipelined
|
||||
+(define_insn_reservation "ppce300c3_sdiv" 18
|
||||
+ (and (eq_attr "type" "sdiv")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_fpu,ppce300c3_fpu*17")
|
||||
+
|
||||
+(define_insn_reservation "ppce300c3_ddiv" 33
|
||||
+ (and (eq_attr "type" "ddiv")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_fpu,ppce300c3_fpu*32")
|
||||
+
|
||||
+;; Loads
|
||||
+(define_insn_reservation "ppce300c3_load" 2
|
||||
+ (and (eq_attr "type" "load,load_ext,load_ext_u,load_ext_ux,load_ux,load_u")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_lsu,ppce300c3_retire")
|
||||
+
|
||||
+(define_insn_reservation "ppce300c3_fpload" 2
|
||||
+ (and (eq_attr "type" "fpload,fpload_ux,fpload_u")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_lsu,ppce300c3_retire")
|
||||
+
|
||||
+;; Stores.
|
||||
+(define_insn_reservation "ppce300c3_store" 2
|
||||
+ (and (eq_attr "type" "store,store_ux,store_u")
|
||||
+ (ior (eq_attr "cpu" "ppce300c2") (eq_attr "cpu" "ppce300c3")))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_lsu,ppce300c3_retire")
|
||||
+
|
||||
+(define_insn_reservation "ppce300c3_fpstore" 2
|
||||
+ (and (eq_attr "type" "fpstore,fpstore_ux,fpstore_u")
|
||||
+ (eq_attr "cpu" "ppce300c3"))
|
||||
+ "ppce300c3_decode,ppce300c3_issue+ppce300c3_lsu,ppce300c3_retire")
|
||||
Index: gcc-4.1.2/gcc/config/rs6000/rs6000.c
|
||||
===================================================================
|
||||
--- gcc-4.1.2.orig/gcc/config/rs6000/rs6000.c 2006-12-16 20:24:56.000000000 +0100
|
||||
+++ gcc-4.1.2/gcc/config/rs6000/rs6000.c 2007-10-18 15:34:26.000000000 +0200
|
||||
@@ -557,6 +557,21 @@
|
||||
COSTS_N_INSNS (29), /* ddiv */
|
||||
};
|
||||
|
||||
+/* Instruction costs on E300C2 and E300C3 cores. */
|
||||
+static const
|
||||
+struct processor_costs ppce300c2c3_cost = {
|
||||
+ COSTS_N_INSNS (4), /* mulsi */
|
||||
+ COSTS_N_INSNS (4), /* mulsi_const */
|
||||
+ COSTS_N_INSNS (4), /* mulsi_const9 */
|
||||
+ COSTS_N_INSNS (4), /* muldi */
|
||||
+ COSTS_N_INSNS (19), /* divsi */
|
||||
+ COSTS_N_INSNS (19), /* divdi */
|
||||
+ COSTS_N_INSNS (3), /* fp */
|
||||
+ COSTS_N_INSNS (4), /* dmul */
|
||||
+ COSTS_N_INSNS (18), /* sdiv */
|
||||
+ COSTS_N_INSNS (33), /* ddiv */
|
||||
+};
|
||||
+
|
||||
/* Instruction costs on POWER4 and POWER5 processors. */
|
||||
static const
|
||||
struct processor_costs power4_cost = {
|
||||
@@ -1140,6 +1155,8 @@
|
||||
/* 8548 has a dummy entry for now. */
|
||||
{"8548", PROCESSOR_PPC8540,
|
||||
POWERPC_BASE_MASK | MASK_PPC_GFXOPT | MASK_STRICT_ALIGN},
|
||||
+ {"e300c2", PROCESSOR_PPCE300C2, POWERPC_BASE_MASK | MASK_SOFT_FLOAT},
|
||||
+ {"e300c3", PROCESSOR_PPCE300C3, POWERPC_BASE_MASK},
|
||||
{"860", PROCESSOR_MPCCORE, POWERPC_BASE_MASK | MASK_SOFT_FLOAT},
|
||||
{"970", PROCESSOR_POWER4,
|
||||
POWERPC_7400_MASK | MASK_PPC_GPOPT | MASK_MFCRF | MASK_POWERPC64},
|
||||
@@ -1529,6 +1546,11 @@
|
||||
rs6000_cost = &ppc8540_cost;
|
||||
break;
|
||||
|
||||
+ case PROCESSOR_PPCE300C2:
|
||||
+ case PROCESSOR_PPCE300C3:
|
||||
+ rs6000_cost = &ppce300c2c3_cost;
|
||||
+ break;
|
||||
+
|
||||
case PROCESSOR_POWER4:
|
||||
case PROCESSOR_POWER5:
|
||||
rs6000_cost = &power4_cost;
|
||||
@@ -16647,6 +16669,8 @@
|
||||
case CPU_PPC750:
|
||||
case CPU_PPC7400:
|
||||
case CPU_PPC8540:
|
||||
+ case CPU_PPCE300C2:
|
||||
+ case CPU_PPCE300C3:
|
||||
return 2;
|
||||
case CPU_RIOS2:
|
||||
case CPU_PPC604:
|
||||
Index: gcc-4.1.2/gcc/config/rs6000/rs6000.h
|
||||
===================================================================
|
||||
--- gcc-4.1.2.orig/gcc/config/rs6000/rs6000.h 2006-11-18 01:25:49.000000000 +0100
|
||||
+++ gcc-4.1.2/gcc/config/rs6000/rs6000.h 2007-10-18 15:32:51.000000000 +0200
|
||||
@@ -111,6 +111,8 @@
|
||||
%{mcpu=970: -mpower4 -maltivec} \
|
||||
%{mcpu=G5: -mpower4 -maltivec} \
|
||||
%{mcpu=8540: -me500} \
|
||||
+%{mcpu=e300c2: -mppc} \
|
||||
+%{mcpu=e300c3: -mppc -mpmr} \
|
||||
%{maltivec: -maltivec} \
|
||||
-many"
|
||||
|
||||
@@ -211,6 +213,8 @@
|
||||
PROCESSOR_PPC7400,
|
||||
PROCESSOR_PPC7450,
|
||||
PROCESSOR_PPC8540,
|
||||
+ PROCESSOR_PPCE300C2,
|
||||
+ PROCESSOR_PPCE300C3,
|
||||
PROCESSOR_POWER4,
|
||||
PROCESSOR_POWER5
|
||||
};
|
||||
Index: gcc-4.1.2/gcc/config/rs6000/rs6000.md
|
||||
===================================================================
|
||||
--- gcc-4.1.2.orig/gcc/config/rs6000/rs6000.md 2006-12-16 20:24:56.000000000 +0100
|
||||
+++ gcc-4.1.2/gcc/config/rs6000/rs6000.md 2007-10-18 15:32:51.000000000 +0200
|
||||
@@ -103,7 +103,7 @@
|
||||
;; Processor type -- this attribute must exactly match the processor_type
|
||||
;; enumeration in rs6000.h.
|
||||
|
||||
-(define_attr "cpu" "rios1,rios2,rs64a,mpccore,ppc403,ppc405,ppc440,ppc601,ppc603,ppc604,ppc604e,ppc620,ppc630,ppc750,ppc7400,ppc7450,ppc8540,power4,power5"
|
||||
+(define_attr "cpu" "rios1,rios2,rs64a,mpccore,ppc403,ppc405,ppc440,ppc601,ppc603,ppc604,ppc604e,ppc620,ppc630,ppc750,ppc7400,ppc7450,ppc8540,ppce300c2,ppce300c3,power4,power5"
|
||||
(const (symbol_ref "rs6000_cpu_attr")))
|
||||
|
||||
(automata_option "ndfa")
|
||||
@@ -119,6 +119,7 @@
|
||||
(include "7xx.md")
|
||||
(include "7450.md")
|
||||
(include "8540.md")
|
||||
+(include "e300c2c3.md")
|
||||
(include "power4.md")
|
||||
(include "power5.md")
|
||||
|
||||
Index: gcc-4.1.2/gcc/config.gcc
|
||||
===================================================================
|
||||
--- gcc-4.1.2.orig/gcc/config.gcc 2007-10-18 15:26:23.000000000 +0200
|
||||
+++ gcc-4.1.2/gcc/config.gcc 2007-10-18 15:32:51.000000000 +0200
|
||||
@@ -2710,7 +2710,7 @@
|
||||
| rios | rios1 | rios2 | rsc | rsc1 | rs64a \
|
||||
| 401 | 403 | 405 | 405fp | 440 | 440fp | 505 \
|
||||
| 601 | 602 | 603 | 603e | ec603e | 604 \
|
||||
- | 604e | 620 | 630 | 740 | 750 | 7400 | 7450 \
|
||||
+ | 604e | 620 | 630 | 740 | 750 | 7400 | 7450 | e300c[23] \
|
||||
| 854[08] | 801 | 821 | 823 | 860 | 970 | G3 | G4 | G5)
|
||||
# OK
|
||||
;;
|
|
@ -0,0 +1,22 @@
|
|||
--- gcc-3.4.4/configure.in.orig 2005-08-09 19:57:51.504323183 -0700
|
||||
+++ gcc-3.4.4/configure.in 2005-08-09 20:00:12.073168623 -0700
|
||||
@@ -1907,7 +1907,7 @@
|
||||
*) gxx_include_dir=${with_gxx_include_dir} ;;
|
||||
esac
|
||||
|
||||
-FLAGS_FOR_TARGET=
|
||||
+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
|
||||
case " $target_configdirs " in
|
||||
*" newlib "*)
|
||||
case " $target_configargs " in
|
||||
--- gcc-3.4.4/configure.orig 2005-08-09 21:02:29.668360660 -0700
|
||||
+++ gcc-3.4.4/configure 2005-08-09 21:02:50.157649970 -0700
|
||||
@@ -2669,7 +2669,7 @@
|
||||
*) gxx_include_dir=${with_gxx_include_dir} ;;
|
||||
esac
|
||||
|
||||
-FLAGS_FOR_TARGET=
|
||||
+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
|
||||
case " $target_configdirs " in
|
||||
*" newlib "*)
|
||||
case " $target_configargs " in
|
|
@ -0,0 +1,24 @@
|
|||
--- gcc-4.2.0/gcc/config/arm/bpabi.h
|
||||
+++ gcc-4.2.0/gcc/config/arm/bpabi.h
|
||||
@@ -33,9 +33,19 @@
|
||||
#undef FPUTYPE_DEFAULT
|
||||
#define FPUTYPE_DEFAULT FPUTYPE_VFP
|
||||
|
||||
+/*
|
||||
+ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-*
|
||||
+ * (big endian) configurations.
|
||||
+ */
|
||||
+#if TARGET_BIG_ENDIAN_DEFAULT
|
||||
+#define TARGET_ENDIAN_DEFAULT MASK_BIG_END
|
||||
+#else
|
||||
+#define TARGET_ENDIAN_DEFAULT 0
|
||||
+#endif
|
||||
+
|
||||
/* EABI targets should enable interworking by default. */
|
||||
#undef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT MASK_INTERWORK
|
||||
+#define TARGET_DEFAULT (MASK_INTERWORK | TARGET_ENDIAN_DEFAULT)
|
||||
|
||||
/* The ARM BPABI functions return a boolean; they use no special
|
||||
calling convention. */
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
--- /tmp/Makefile.in 2006-02-23 20:56:01.399758728 +0100
|
||||
+++ gcc-4.1-20060217/Makefile.in 2006-02-23 20:56:16.874406224 +0100
|
||||
@@ -334,7 +334,7 @@
|
||||
CXXFLAGS_FOR_TARGET = $(CXXFLAGS) $(SYSROOT_CFLAGS_FOR_TARGET)
|
||||
LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
|
||||
LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
|
||||
-LDFLAGS_FOR_TARGET =
|
||||
+LDFLAGS_FOR_TARGET = @LDFLAGS@
|
||||
PICFLAG_FOR_TARGET =
|
||||
|
||||
# ------------------------------------
|
||||
--- /tmp/Makefile.tpl 2006-02-23 20:50:34.077519272 +0100
|
||||
+++ gcc-4.1-20060217/Makefile.tpl 2006-02-23 21:04:31.092273688 +0100
|
||||
@@ -337,7 +337,7 @@
|
||||
CXXFLAGS_FOR_TARGET = $(CXXFLAGS) $(SYSROOT_CFLAGS_FOR_TARGET)
|
||||
LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
|
||||
LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
|
||||
-LDFLAGS_FOR_TARGET =
|
||||
+LDFLAGS_FOR_TARGET = @LDFLAGS@
|
||||
PICFLAG_FOR_TARGET =
|
||||
|
||||
# ------------------------------------
|
|
@ -0,0 +1,16 @@
|
|||
Index: gcc-4.1.2/gcc/fold-const.c
|
||||
===================================================================
|
||||
--- gcc-4.1.2.orig/gcc/fold-const.c 2007-11-21 18:53:42.000000000 +0100
|
||||
+++ gcc-4.1.2/gcc/fold-const.c 2007-11-21 18:56:26.000000000 +0100
|
||||
@@ -5339,7 +5339,10 @@
|
||||
}
|
||||
break;
|
||||
}
|
||||
- /* FALLTHROUGH */
|
||||
+ /* If the constant is negative, we cannot simplify this. */
|
||||
+ if (tree_int_cst_sgn (c) == -1)
|
||||
+ break;
|
||||
+ /* FALLTHROUGH */
|
||||
case NEGATE_EXPR:
|
||||
if ((t1 = extract_muldiv (op0, c, code, wide_type)) != 0)
|
||||
return fold_build1 (tcode, ctype, fold_convert (ctype, t1));
|
|
@ -0,0 +1,22 @@
|
|||
--- gcc-3.4.1/libstdc++-v3/libmath/Makefile.am~ 2003-08-27 22:29:42.000000000 +0100
|
||||
+++ gcc-3.4.1/libstdc++-v3/libmath/Makefile.am 2004-07-22 16:41:45.152130128 +0100
|
||||
@@ -32,7 +32,7 @@
|
||||
|
||||
libmath_la_SOURCES = stubs.c
|
||||
|
||||
-AM_CPPFLAGS = $(CANADIAN_INCLUDES)
|
||||
+AM_CPPFLAGS = $(CANADIAN_INCLUDES) -I$(toplevel_srcdir)/include
|
||||
|
||||
# Only compiling "C" sources in this directory.
|
||||
LIBTOOL = @LIBTOOL@ --tag CC
|
||||
--- gcc-3.4.1/libstdc++-v3/fragment.am.old 2004-07-22 18:24:58.024083656 +0100
|
||||
+++ gcc-3.4.1/libstdc++-v3/fragment.am 2004-07-22 18:24:59.019932264 +0100
|
||||
@@ -18,7 +18,7 @@
|
||||
$(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once
|
||||
|
||||
# -I/-D flags to pass when compiling.
|
||||
-AM_CPPFLAGS = $(GLIBCXX_INCLUDES)
|
||||
+AM_CPPFLAGS = $(GLIBCXX_INCLUDES) -I$(toplevel_srcdir)/include
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
--- gcc-4.1.1/gcc/Makefile.in_orig 2007-01-31 21:24:23.000000000 +0000
|
||||
+++ gcc-4.1.1/gcc/Makefile.in 2007-01-31 21:24:43.000000000 +0000
|
||||
@@ -3772,8 +3772,6 @@
|
||||
$(INSTALL_SCRIPT) $(mkinstalldirs) \
|
||||
$(DESTDIR)$(itoolsdir)/mkinstalldirs ; \
|
||||
$(INSTALL_SCRIPT) $(srcdir)/fixproto $(DESTDIR)$(itoolsdir)/fixproto ; \
|
||||
- $(INSTALL_PROGRAM) build/fix-header$(build_exeext) \
|
||||
- $(DESTDIR)$(itoolsdir)/fix-header$(build_exeext) ; \
|
||||
else :; fi
|
||||
echo 'SYSTEM_HEADER_DIR="'"$(SYSTEM_HEADER_DIR)"'"' \
|
||||
> $(DESTDIR)$(itoolsdatadir)/mkheaders.conf
|
|
@ -0,0 +1,12 @@
|
|||
diff -urN gcc-4.1.1/gcc/config/arm/linux-eabi.h gcc-4.1.1-arm9tdmi/gcc/config/arm/linux-eabi.h
|
||||
--- gcc-4.1.1/gcc/config/arm/linux-eabi.h 2006-10-22 11:11:49.000000000 -0700
|
||||
+++ gcc-4.1.1-arm9tdmi/gcc/config/arm/linux-eabi.h 2006-10-24 21:34:01.000000000 -0700
|
||||
@@ -45,7 +45,7 @@
|
||||
The ARM10TDMI core is the default for armv5t, so set
|
||||
SUBTARGET_CPU_DEFAULT to achieve this. */
|
||||
#undef SUBTARGET_CPU_DEFAULT
|
||||
-#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm10tdmi
|
||||
+#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm9tdmi
|
||||
|
||||
#undef SUBTARGET_EXTRA_LINK_SPEC
|
||||
#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux_eabi"
|
|
@ -0,0 +1,31 @@
|
|||
Index: gcc-4.0.2/gcc/c-incpath.c
|
||||
===================================================================
|
||||
--- gcc-4.0.2.orig/gcc/c-incpath.c 2005-01-23 16:05:27.000000000 +0100
|
||||
+++ gcc-4.0.2/gcc/c-incpath.c 2006-05-15 21:23:02.000000000 +0200
|
||||
@@ -350,6 +350,26 @@
|
||||
p->construct = 0;
|
||||
p->user_supplied_p = user_supplied_p;
|
||||
|
||||
+#ifdef CROSS_COMPILE
|
||||
+ /* A common error when cross compiling is including
|
||||
+ host headers. This code below will try to fail fast
|
||||
+ for cross compiling. Currently we consider /usr/include,
|
||||
+ /opt/include and /sw/include as harmful. */
|
||||
+ {
|
||||
+ /* printf("Adding Path: %s\n", p->name ); */
|
||||
+ if( strstr(p->name, "/usr/include" ) == p->name ) {
|
||||
+ fprintf(stderr, _("CROSS COMPILE Badness: /usr/include in INCLUDEPATH: %s\n"), p->name);
|
||||
+ abort();
|
||||
+ } else if( strstr(p->name, "/sw/include") == p->name ) {
|
||||
+ fprintf(stderr, _("CROSS COMPILE Badness: /sw/include in INCLUDEPATH: %s\n"), p->name);
|
||||
+ abort();
|
||||
+ } else if( strstr(p->name, "/opt/include") == p->name ) {
|
||||
+ fprintf(stderr, _("CROSS COMPILE Badness: /opt/include in INCLUDEPATH: %s\n"), p->name);
|
||||
+ abort();
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
+
|
||||
add_cpp_dir_path (p, chain);
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
upstream: n/a
|
||||
comment: Use the preprocessor we have just compiled instead the one of
|
||||
the system. There might be incompabilities between us and them.
|
||||
|
||||
Index: gcc-4.1.1/Makefile.in
|
||||
===================================================================
|
||||
--- gcc-4.1.1.orig/Makefile.in 2006-08-06 13:32:44.000000000 +0200
|
||||
+++ gcc-4.1.1/Makefile.in 2006-08-06 13:32:46.000000000 +0200
|
||||
@@ -194,6 +194,7 @@
|
||||
AS="$(COMPILER_AS_FOR_TARGET)"; export AS; \
|
||||
CC="$(CC_FOR_TARGET)"; export CC; \
|
||||
CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
|
||||
+ CPP="$(CC_FOR_TARGET) -E"; export CCP; \
|
||||
CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
|
||||
CPPFLAGS="$(CPPFLAGS_FOR_TARGET)"; export CPPFLAGS; \
|
||||
CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
|
|
@ -0,0 +1,5 @@
|
|||
require gcc-cross_${PV}.bb
|
||||
require gcc-cross-initial.inc
|
||||
|
||||
EXTRA_OECONF += "--disable-libmudflap --disable-libgomp \
|
||||
--disable-libssp"
|
|
@ -0,0 +1,14 @@
|
|||
PR = "r4"
|
||||
|
||||
inherit sdk
|
||||
|
||||
require gcc-${PV}.inc
|
||||
require gcc-cross-sdk.inc
|
||||
require gcc-configure-sdk.inc
|
||||
require gcc-package-sdk.inc
|
||||
|
||||
DEPENDS += "gmp-native mpfr-native"
|
||||
|
||||
EXTRA_OECONF += "--disable-libunwind-exceptions --disable-libssp \
|
||||
--disable-libgomp --disable-libmudflap \
|
||||
--with-mpfr=${STAGING_DIR_NATIVE}${layout_exec_prefix}"
|
|
@ -0,0 +1,12 @@
|
|||
PR = "r1"
|
||||
|
||||
require gcc-${PV}.inc
|
||||
require gcc-cross4.inc
|
||||
require gcc-configure-cross.inc
|
||||
require gcc-package-cross.inc
|
||||
|
||||
SRC_URI_append_fail-fast = " file://zecke-no-host-includes.patch;patch=1 "
|
||||
|
||||
EXTRA_OECONF += "--disable-libunwind-exceptions --with-mpfr=${STAGING_DIR_NATIVE}${layout_exec_prefix}"
|
||||
|
||||
ARCH_FLAGS_FOR_TARGET += "-isystem${STAGING_DIR_TARGET}${layout_includedir}"
|
|
@ -0,0 +1,10 @@
|
|||
PR = "r1"
|
||||
|
||||
require gcc-${PV}.inc
|
||||
require gcc-configure-target.inc
|
||||
require gcc-package-target.inc
|
||||
|
||||
SRC_URI_append = "file://fortran-cross-compile-hack.patch;patch=1"
|
||||
|
||||
ARCH_FLAGS_FOR_TARGET += "-isystem${STAGING_INCDIR}"
|
||||
|
Loading…
Reference in New Issue