mirror of
https://github.com/crosstool-ng/crosstool-ng.git
synced 2025-04-18 00:06:04 +00:00
Add patches against gcc-3.4.6. Untested.
This commit is contained in:
parent
5b7672f931
commit
7af2ee399f
492
patches/gcc/3.4.6/100-uclibc-conf.patch
Normal file
492
patches/gcc/3.4.6/100-uclibc-conf.patch
Normal file
@ -0,0 +1,492 @@
|
||||
diff -durN gcc-3.4.6.orig/boehm-gc/configure gcc-3.4.6/boehm-gc/configure
|
||||
--- gcc-3.4.6.orig/boehm-gc/configure 2006-03-06 04:55:49.000000000 +0100
|
||||
+++ gcc-3.4.6/boehm-gc/configure 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -1947,6 +1947,11 @@
|
||||
lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
|
||||
;;
|
||||
|
||||
+linux-uclibc*)
|
||||
+ lt_cv_deplibs_check_method=pass_all
|
||||
+ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
|
||||
+ ;;
|
||||
+
|
||||
netbsd*)
|
||||
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
|
||||
lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
|
||||
diff -durN gcc-3.4.6.orig/boehm-gc/ltconfig gcc-3.4.6/boehm-gc/ltconfig
|
||||
--- gcc-3.4.6.orig/boehm-gc/ltconfig 2002-11-20 16:59:07.000000000 +0100
|
||||
+++ gcc-3.4.6/boehm-gc/ltconfig 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -1981,6 +1981,23 @@
|
||||
fi
|
||||
;;
|
||||
|
||||
+linux-uclibc*)
|
||||
+ version_type=linux
|
||||
+ need_lib_prefix=no
|
||||
+ need_version=no
|
||||
+ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
||||
+ soname_spec='${libname}${release}.so$major'
|
||||
+ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
|
||||
+ shlibpath_var=LD_LIBRARY_PATH
|
||||
+ shlibpath_overrides_runpath=no
|
||||
+ deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
|
||||
+ file_magic_cmd=/usr/bin/file
|
||||
+ file_magic_test_file=`echo /lib/libuClibc-*.so`
|
||||
+
|
||||
+ # Assume using the uClibc dynamic linker.
|
||||
+ dynamic_linker="uClibc ld.so"
|
||||
+ ;;
|
||||
+
|
||||
netbsd*)
|
||||
version_type=sunos
|
||||
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/alpha/linux-elf.h gcc-3.4.6/gcc/config/alpha/linux-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/alpha/linux-elf.h 2003-09-27 06:48:30.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/alpha/linux-elf.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -27,7 +27,11 @@
|
||||
#define SUBTARGET_EXTRA_SPECS \
|
||||
{ "elf_dynamic_linker", ELF_DYNAMIC_LINKER },
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
|
||||
#define LINK_SPEC "-m elf64alpha %{G*} %{relax:-relax} \
|
||||
%{O*:-O3} %{!O*:-O1} \
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/linux-elf.h gcc-3.4.6/gcc/config/arm/linux-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:40.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/arm/linux-elf.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -80,6 +80,11 @@
|
||||
#define ENDFILE_SPEC \
|
||||
"%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s"
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC "%{h*} %{version:-v} \
|
||||
%{b} %{Wl,*:%*} \
|
||||
@@ -87,7 +92,7 @@
|
||||
%{shared:-shared} \
|
||||
%{symbolic:-Bsymbolic} \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "} \
|
||||
-X \
|
||||
%{mbig-endian:-EB}" \
|
||||
SUBTARGET_EXTRA_LINK_SPEC
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/cris/linux.h gcc-3.4.6/gcc/config/cris/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/cris/linux.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/cris/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -79,6 +79,25 @@
|
||||
#undef CRIS_DEFAULT_CPU_VERSION
|
||||
#define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+
|
||||
+#undef CRIS_SUBTARGET_VERSION
|
||||
+#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc"
|
||||
+
|
||||
+#undef CRIS_LINK_SUBTARGET_SPEC
|
||||
+#define CRIS_LINK_SUBTARGET_SPEC \
|
||||
+ "-mcrislinux\
|
||||
+ -rpath-link include/asm/../..%s\
|
||||
+ %{shared} %{static}\
|
||||
+ %{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\
|
||||
+ %{!shared: \
|
||||
+ %{!static: \
|
||||
+ %{rdynamic:-export-dynamic} \
|
||||
+ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}} \
|
||||
+ %{!r:%{O2|O3: --gc-sections}}"
|
||||
+
|
||||
+#else /* USE_UCLIBC */
|
||||
+
|
||||
#undef CRIS_SUBTARGET_VERSION
|
||||
#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu"
|
||||
|
||||
@@ -93,6 +112,8 @@
|
||||
%{!shared:%{!static:%{rdynamic:-export-dynamic}}}\
|
||||
%{!r:%{O2|O3: --gc-sections}}"
|
||||
|
||||
+#endif /* USE_UCLIBC */
|
||||
+
|
||||
|
||||
/* Node: Run-time Target */
|
||||
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/i386/linux64.h gcc-3.4.6/gcc/config/i386/linux64.h
|
||||
--- gcc-3.4.6.orig/gcc/config/i386/linux64.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/i386/linux64.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -54,14 +54,21 @@
|
||||
When the -shared link option is used a final link is not being
|
||||
done. */
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF32_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#define ELF64_DYNAMIC_LINKER "/lib/ld64-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF32_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#define ELF64_DYNAMIC_LINKER "/lib64/ld-linux-x86-64.so.2"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC "%{!m32:-m elf_x86_64} %{m32:-m elf_i386} \
|
||||
%{shared:-shared} \
|
||||
%{!shared: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{m32:%{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
|
||||
- %{!m32:%{!dynamic-linker:-dynamic-linker /lib64/ld-linux-x86-64.so.2}}} \
|
||||
+ %{m32:%{!dynamic-linker:-dynamic-linker " ELF32_DYNAMIC_LINKER "}} \
|
||||
+ %{!m32:%{!dynamic-linker:-dynamic-linker " ELF64_DYNAMIC_LINKER "}}} \
|
||||
%{static:-static}}"
|
||||
|
||||
#define MULTILIB_DEFAULTS { "m64" }
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/i386/linux.h gcc-3.4.6/gcc/config/i386/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/i386/linux.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/i386/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -110,22 +110,21 @@
|
||||
|
||||
#undef LINK_SPEC
|
||||
#ifdef USE_GNULIBC_1
|
||||
-#define LINK_SPEC "-m elf_i386 %{shared:-shared} \
|
||||
- %{!shared: \
|
||||
- %{!ibcs: \
|
||||
- %{!static: \
|
||||
- %{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.1}} \
|
||||
- %{static:-static}}}"
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.1"
|
||||
#else
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
+#endif
|
||||
#define LINK_SPEC "-m elf_i386 %{shared:-shared} \
|
||||
%{!shared: \
|
||||
%{!ibcs: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}}"
|
||||
-#endif
|
||||
|
||||
/* A C statement (sans semicolon) to output to the stdio stream
|
||||
FILE the assembler definition of uninitialized global DECL named
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/ia64/linux.h gcc-3.4.6/gcc/config/ia64/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/ia64/linux.h 2004-02-07 08:56:17.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/ia64/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -37,13 +37,18 @@
|
||||
/* Define this for shared library support because it isn't in the main
|
||||
linux.h file. */
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC "\
|
||||
%{shared:-shared} \
|
||||
%{!shared: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux-ia64.so.2}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}"
|
||||
|
||||
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/m68k/linux.h gcc-3.4.6/gcc/config/m68k/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/m68k/linux.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/m68k/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -131,12 +131,17 @@
|
||||
|
||||
/* If ELF is the default format, we should not use /lib/elf. */
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld.so.1"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC "-m m68kelf %{shared} \
|
||||
%{!shared: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker*:-dynamic-linker /lib/ld.so.1}} \
|
||||
+ %{!dynamic-linker*:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static}}"
|
||||
|
||||
/* For compatibility with linux/a.out */
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/mips/linux.h gcc-3.4.6/gcc/config/mips/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/mips/linux.h 2004-06-16 03:42:25.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/mips/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -109,6 +109,11 @@
|
||||
|
||||
/* Borrowed from sparc/linux.h */
|
||||
#undef LINK_SPEC
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld.so.1"
|
||||
+#endif
|
||||
#define LINK_SPEC \
|
||||
"%(endian_spec) \
|
||||
%{shared:-shared} \
|
||||
@@ -116,7 +121,7 @@
|
||||
%{!ibcs: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}}"
|
||||
|
||||
#undef SUBTARGET_ASM_SPEC
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/pa/pa-linux.h gcc-3.4.6/gcc/config/pa/pa-linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/pa/pa-linux.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/pa/pa-linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -77,13 +77,18 @@
|
||||
/* Define this for shared library support because it isn't in the main
|
||||
linux.h file. */
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld.so.1"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC "\
|
||||
%{shared:-shared} \
|
||||
%{!shared: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}"
|
||||
|
||||
/* glibc's profiling functions don't need gcc to allocate counters. */
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/rs6000/linux.h gcc-3.4.6/gcc/config/rs6000/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/rs6000/linux.h 2005-03-17 11:41:18.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/rs6000/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -69,7 +69,11 @@
|
||||
#define LINK_START_DEFAULT_SPEC "%(link_start_linux)"
|
||||
|
||||
#undef LINK_OS_DEFAULT_SPEC
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define LINK_OS_DEFAULT_SPEC "%(link_os_linux_uclibc)"
|
||||
+#else
|
||||
#define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
|
||||
+#endif
|
||||
|
||||
#define LINK_GCC_C_SEQUENCE_SPEC \
|
||||
"%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}"
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/rs6000/sysv4.h gcc-3.4.6/gcc/config/rs6000/sysv4.h
|
||||
--- gcc-3.4.6.orig/gcc/config/rs6000/sysv4.h 2005-10-30 00:35:37.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/rs6000/sysv4.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -949,6 +949,7 @@
|
||||
mcall-linux : %(link_os_linux) ; \
|
||||
mcall-gnu : %(link_os_gnu) ; \
|
||||
mcall-netbsd : %(link_os_netbsd) ; \
|
||||
+ mcall-linux-uclibc : %(link_os_linux_uclibc); \
|
||||
mcall-openbsd: %(link_os_openbsd) ; \
|
||||
: %(link_os_default) }"
|
||||
|
||||
@@ -1127,6 +1128,10 @@
|
||||
%{rdynamic:-export-dynamic} \
|
||||
%{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}}"
|
||||
|
||||
+#define LINK_OS_LINUX_UCLIBC_SPEC "-m elf32ppclinux %{!shared: %{!static: \
|
||||
+ %{rdynamic:-export-dynamic} \
|
||||
+ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}}"
|
||||
+
|
||||
#if defined(HAVE_LD_EH_FRAME_HDR)
|
||||
# define LINK_EH_SPEC "%{!static:--eh-frame-hdr} "
|
||||
#endif
|
||||
@@ -1293,6 +1298,7 @@
|
||||
{ "link_os_sim", LINK_OS_SIM_SPEC }, \
|
||||
{ "link_os_freebsd", LINK_OS_FREEBSD_SPEC }, \
|
||||
{ "link_os_linux", LINK_OS_LINUX_SPEC }, \
|
||||
+ { "link_os_linux_uclibc", LINK_OS_LINUX_UCLIBC_SPEC }, \
|
||||
{ "link_os_gnu", LINK_OS_GNU_SPEC }, \
|
||||
{ "link_os_netbsd", LINK_OS_NETBSD_SPEC }, \
|
||||
{ "link_os_openbsd", LINK_OS_OPENBSD_SPEC }, \
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/s390/linux.h gcc-3.4.6/gcc/config/s390/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/s390/linux.h 2003-11-29 04:08:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/s390/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -77,6 +77,13 @@
|
||||
#define MULTILIB_DEFAULTS { "m31" }
|
||||
#endif
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF31_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#define ELF64_DYNAMIC_LINKER "/lib/ld64-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF31_DYNAMIC_LINKER "/lib/ld.so.1"
|
||||
+#define ELF64_DYNAMIC_LINKER "/lib/ld64.so.1"
|
||||
+#endif
|
||||
#undef LINK_SPEC
|
||||
#define LINK_SPEC \
|
||||
"%{m31:-m elf_s390}%{m64:-m elf64_s390} \
|
||||
@@ -86,8 +93,8 @@
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
%{!dynamic-linker: \
|
||||
- %{m31:-dynamic-linker /lib/ld.so.1} \
|
||||
- %{m64:-dynamic-linker /lib/ld64.so.1}}}}"
|
||||
+ %{m31:-dynamic-linker " ELF31_DYNAMIC_LINKER "} \
|
||||
+ %{m64:-dynamic-linker " ELF64_DYNAMIC_LINKER "}}}}"
|
||||
|
||||
|
||||
#define TARGET_ASM_FILE_END file_end_indicate_exec_stack
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sh/linux.h gcc-3.4.6/gcc/config/sh/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/sh/linux.h 2004-01-12 03:29:13.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/sh/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -73,11 +73,16 @@
|
||||
#undef SUBTARGET_LINK_EMUL_SUFFIX
|
||||
#define SUBTARGET_LINK_EMUL_SUFFIX "_linux"
|
||||
#undef SUBTARGET_LINK_SPEC
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
#define SUBTARGET_LINK_SPEC \
|
||||
"%{shared:-shared} \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}"
|
||||
|
||||
#undef LIB_SPEC
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sparc/linux64.h gcc-3.4.6/gcc/config/sparc/linux64.h
|
||||
--- gcc-3.4.6.orig/gcc/config/sparc/linux64.h 2004-06-06 05:55:17.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/sparc/linux64.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -167,12 +167,17 @@
|
||||
{ "link_arch_default", LINK_ARCH_DEFAULT_SPEC }, \
|
||||
{ "link_arch", LINK_ARCH_SPEC },
|
||||
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
#define LINK_ARCH32_SPEC "-m elf32_sparc -Y P,/usr/lib %{shared:-shared} \
|
||||
%{!shared: \
|
||||
%{!ibcs: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}} \
|
||||
"
|
||||
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sparc/linux.h gcc-3.4.6/gcc/config/sparc/linux.h
|
||||
--- gcc-3.4.6.orig/gcc/config/sparc/linux.h 2004-06-06 05:55:17.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/sparc/linux.h 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -162,13 +162,18 @@
|
||||
%{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.1}} \
|
||||
%{static:-static}}}"
|
||||
#else
|
||||
+#ifdef USE_UCLIBC
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
|
||||
+#else
|
||||
+#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2"
|
||||
+#endif
|
||||
#define LINK_SPEC "-m elf32_sparc -Y P,/usr/lib %{shared:-shared} \
|
||||
%{!mno-relax:%{!r:-relax}} \
|
||||
%{!shared: \
|
||||
%{!ibcs: \
|
||||
%{!static: \
|
||||
%{rdynamic:-export-dynamic} \
|
||||
- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
|
||||
+ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \
|
||||
%{static:-static}}}"
|
||||
#endif
|
||||
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/t-linux-uclibc gcc-3.4.6/gcc/config/t-linux-uclibc
|
||||
--- gcc-3.4.6.orig/gcc/config/t-linux-uclibc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/t-linux-uclibc 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -0,0 +1,5 @@
|
||||
+# Remove glibc specific files added in t-linux
|
||||
+SHLIB_MAPFILES := $(filter-out $(srcdir)/config/libgcc-glibc.ver, $(SHLIB_MAPFILES))
|
||||
+
|
||||
+# Use unwind-dw2-fde instead of unwind-dw2-fde-glibc
|
||||
+LIB2ADDEH := $(subst unwind-dw2-fde-glibc.c,unwind-dw2-fde.c,$(LIB2ADDEH))
|
||||
diff -durN gcc-3.4.6.orig/gcc/config.gcc gcc-3.4.6/gcc/config.gcc
|
||||
--- gcc-3.4.6.orig/gcc/config.gcc 2005-07-19 23:08:48.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config.gcc 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -2322,6 +2322,12 @@
|
||||
;;
|
||||
esac
|
||||
|
||||
+# Rather than hook into each target, just do it after all the linux
|
||||
+# targets have been processed
|
||||
+case ${target} in
|
||||
+*-linux-uclibc*) tm_defines="${tm_defines} USE_UCLIBC" ; tmake_file="${tmake_file} t-linux-uclibc"
|
||||
+esac
|
||||
+
|
||||
# Support for --with-cpu and related options (and a few unrelated options,
|
||||
# too).
|
||||
case ${with_cpu} in
|
||||
diff -durN gcc-3.4.6.orig/libtool.m4 gcc-3.4.6/libtool.m4
|
||||
--- gcc-3.4.6.orig/libtool.m4 2004-05-18 11:09:14.000000000 +0200
|
||||
+++ gcc-3.4.6/libtool.m4 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -689,6 +689,11 @@
|
||||
lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
|
||||
;;
|
||||
|
||||
+linux-uclibc*)
|
||||
+ lt_cv_deplibs_check_method=pass_all
|
||||
+ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so`
|
||||
+ ;;
|
||||
+
|
||||
netbsd*)
|
||||
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
|
||||
[lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$']
|
||||
diff -durN gcc-3.4.6.orig/ltconfig gcc-3.4.6/ltconfig
|
||||
--- gcc-3.4.6.orig/ltconfig 2004-03-05 22:05:41.000000000 +0100
|
||||
+++ gcc-3.4.6/ltconfig 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -602,6 +602,7 @@
|
||||
|
||||
# Transform linux* to *-*-linux-gnu*, to support old configure scripts.
|
||||
case $host_os in
|
||||
+linux-uclibc*) ;;
|
||||
linux-gnu*) ;;
|
||||
linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
|
||||
esac
|
||||
@@ -1262,6 +1263,24 @@
|
||||
dynamic_linker='GNU/Linux ld.so'
|
||||
;;
|
||||
|
||||
+linux-uclibc*)
|
||||
+ version_type=linux
|
||||
+ need_lib_prefix=no
|
||||
+ need_version=no
|
||||
+ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
|
||||
+ soname_spec='${libname}${release}.so$major'
|
||||
+ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
|
||||
+ shlibpath_var=LD_LIBRARY_PATH
|
||||
+ shlibpath_overrides_runpath=no
|
||||
+ # This implies no fast_install, which is unacceptable.
|
||||
+ # Some rework will be needed to allow for fast_install
|
||||
+ # before this can be enabled.
|
||||
+ # Note: copied from linux-gnu, and may not be appropriate.
|
||||
+ hardcode_into_libs=yes
|
||||
+ # Assume using the uClibc dynamic linker.
|
||||
+ dynamic_linker="uClibc ld.so"
|
||||
+ ;;
|
||||
+
|
||||
netbsd*)
|
||||
need_lib_prefix=no
|
||||
need_version=no
|
||||
diff -durN gcc-3.4.6.orig/null gcc-3.4.6/null
|
||||
--- gcc-3.4.6.orig/null 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ gcc-3.4.6/null 2007-08-15 22:49:47.000000000 +0200
|
||||
@@ -0,0 +1 @@
|
||||
+~/dev
|
3255
patches/gcc/3.4.6/200-uclibc-locale.patch
Normal file
3255
patches/gcc/3.4.6/200-uclibc-locale.patch
Normal file
File diff suppressed because it is too large
Load Diff
46
patches/gcc/3.4.6/300-libstdc++-pic.patch
Normal file
46
patches/gcc/3.4.6/300-libstdc++-pic.patch
Normal file
@ -0,0 +1,46 @@
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/src/Makefile.am gcc-3.4.6/libstdc++-v3/src/Makefile.am
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/src/Makefile.am 2004-04-16 21:08:35.000000000 +0200
|
||||
+++ gcc-3.4.6/libstdc++-v3/src/Makefile.am 2007-08-15 22:52:23.000000000 +0200
|
||||
@@ -210,6 +210,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
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/src/Makefile.in gcc-3.4.6/libstdc++-v3/src/Makefile.in
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/src/Makefile.in 2004-04-16 21:08:35.000000000 +0200
|
||||
+++ gcc-3.4.6/libstdc++-v3/src/Makefile.in 2007-08-15 22:52:23.000000000 +0200
|
||||
@@ -592,7 +592,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
|
||||
|
||||
@@ -625,6 +625,7 @@
|
||||
distclean-tags distdir dvi dvi-am info info-am install \
|
||||
install-am install-data install-data-am install-data-local \
|
||||
install-exec install-exec-am install-info install-info-am \
|
||||
+ install-exec-local \
|
||||
install-man install-strip install-toolexeclibLTLIBRARIES \
|
||||
installcheck installcheck-am installdirs maintainer-clean \
|
||||
maintainer-clean-generic mostlyclean mostlyclean-compile \
|
||||
@@ -709,6 +710,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:
|
26
patches/gcc/3.4.6/304-index_macro.patch
Normal file
26
patches/gcc/3.4.6/304-index_macro.patch
Normal file
@ -0,0 +1,26 @@
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/include/ext/rope gcc-3.4.6/libstdc++-v3/include/ext/rope
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/include/ext/rope 2005-01-16 23:08:43.000000000 +0100
|
||||
+++ gcc-3.4.6/libstdc++-v3/include/ext/rope 2007-08-15 22:53:37.000000000 +0200
|
||||
@@ -58,6 +58,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
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/include/ext/ropeimpl.h gcc-3.4.6/libstdc++-v3/include/ext/ropeimpl.h
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/include/ext/ropeimpl.h 2004-09-08 15:36:04.000000000 +0200
|
||||
+++ gcc-3.4.6/libstdc++-v3/include/ext/ropeimpl.h 2007-08-15 22:53:37.000000000 +0200
|
||||
@@ -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
|
||||
+
|
||||
namespace __gnu_cxx
|
||||
{
|
||||
using std::size_t;
|
68
patches/gcc/3.4.6/600-gcc34-arm-ldm-peephole.patch
Normal file
68
patches/gcc/3.4.6/600-gcc34-arm-ldm-peephole.patch
Normal file
@ -0,0 +1,68 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/arm.c gcc-3.4.6/gcc/config/arm/arm.c
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/arm.c 2005-10-01 15:31:38.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/arm.c 2007-08-15 22:54:59.000000000 +0200
|
||||
@@ -4857,6 +4857,11 @@
|
||||
*load_offset = unsorted_offsets[order[0]];
|
||||
}
|
||||
|
||||
+ /* For XScale a two-word LDM is a performance loss, so only do this if
|
||||
+ size is more important. See comments in arm_gen_load_multiple. */
|
||||
+ if (nops == 2 && arm_tune_xscale && !optimize_size)
|
||||
+ return 0;
|
||||
+
|
||||
if (unsorted_offsets[order[0]] == 0)
|
||||
return 1; /* ldmia */
|
||||
|
||||
@@ -5083,6 +5088,11 @@
|
||||
*load_offset = unsorted_offsets[order[0]];
|
||||
}
|
||||
|
||||
+ /* For XScale a two-word LDM is a performance loss, so only do this if
|
||||
+ size is more important. See comments in arm_gen_load_multiple. */
|
||||
+ if (nops == 2 && arm_tune_xscale && !optimize_size)
|
||||
+ return 0;
|
||||
+
|
||||
if (unsorted_offsets[order[0]] == 0)
|
||||
return 1; /* stmia */
|
||||
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/arm.md gcc-3.4.6/gcc/config/arm/arm.md
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/arm.md 2005-10-01 15:31:38.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/arm.md 2007-08-15 22:54:59.000000000 +0200
|
||||
@@ -8811,13 +8811,16 @@
|
||||
(set_attr "length" "4,8,8")]
|
||||
)
|
||||
|
||||
+; Try to convert LDR+LDR+arith into [add+]LDM+arith
|
||||
+; On XScale, LDM is always slower than two LDRs, so only do this if
|
||||
+; optimising for size.
|
||||
(define_insn "*arith_adjacentmem"
|
||||
[(set (match_operand:SI 0 "s_register_operand" "=r")
|
||||
(match_operator:SI 1 "shiftable_operator"
|
||||
[(match_operand:SI 2 "memory_operand" "m")
|
||||
(match_operand:SI 3 "memory_operand" "m")]))
|
||||
(clobber (match_scratch:SI 4 "=r"))]
|
||||
- "TARGET_ARM && adjacent_mem_locations (operands[2], operands[3])"
|
||||
+ "TARGET_ARM && (!arm_tune_xscale || optimize_size) && adjacent_mem_locations (operands[2], operands[3])"
|
||||
"*
|
||||
{
|
||||
rtx ldm[3];
|
||||
@@ -8852,6 +8855,8 @@
|
||||
}
|
||||
if (val1 && val2)
|
||||
{
|
||||
+ /* This would be a loss on a Harvard core, but adjacent_mem_locations()
|
||||
+ will prevent it from happening. */
|
||||
rtx ops[3];
|
||||
ldm[0] = ops[0] = operands[4];
|
||||
ops[1] = XEXP (XEXP (operands[2], 0), 0);
|
||||
diff -durN gcc-3.4.6.orig/gcc/genpeep.c gcc-3.4.6/gcc/genpeep.c
|
||||
--- gcc-3.4.6.orig/gcc/genpeep.c 2003-07-05 07:27:22.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/genpeep.c 2007-08-15 22:54:59.000000000 +0200
|
||||
@@ -381,6 +381,7 @@
|
||||
printf ("#include \"recog.h\"\n");
|
||||
printf ("#include \"except.h\"\n\n");
|
||||
printf ("#include \"function.h\"\n\n");
|
||||
+ printf ("#include \"flags.h\"\n\n");
|
||||
|
||||
printf ("#ifdef HAVE_peephole\n");
|
||||
printf ("extern rtx peep_operand[];\n\n");
|
32
patches/gcc/3.4.6/601-gcc34-arm-ldm-peephole2.patch
Normal file
32
patches/gcc/3.4.6/601-gcc34-arm-ldm-peephole2.patch
Normal file
@ -0,0 +1,32 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/arm.c gcc-3.4.6/gcc/config/arm/arm.c
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/arm.c 2007-08-15 22:57:51.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/arm.c 2007-08-15 22:57:51.000000000 +0200
|
||||
@@ -4572,6 +4572,10 @@
|
||||
int
|
||||
adjacent_mem_locations (rtx a, rtx b)
|
||||
{
|
||||
+ /* We don't guarantee to preserve the order of these memory refs. */
|
||||
+ if (volatile_refs_p (a) || volatile_refs_p (b))
|
||||
+ return 0;
|
||||
+
|
||||
if ((GET_CODE (XEXP (a, 0)) == REG
|
||||
|| (GET_CODE (XEXP (a, 0)) == PLUS
|
||||
&& GET_CODE (XEXP (XEXP (a, 0), 1)) == CONST_INT))
|
||||
@@ -4611,6 +4615,17 @@
|
||||
return 0;
|
||||
|
||||
val_diff = val1 - val0;
|
||||
+
|
||||
+ if (arm_ld_sched)
|
||||
+ {
|
||||
+ /* If the target has load delay slots, then there's no benefit
|
||||
+ to using an ldm instruction unless the offset is zero and
|
||||
+ we are optimizing for size. */
|
||||
+ return (optimize_size && (REGNO (reg0) == REGNO (reg1))
|
||||
+ && (val0 == 0 || val1 == 0 || val0 == 4 || val1 == 4)
|
||||
+ && (val_diff == 4 || val_diff == -4));
|
||||
+ }
|
||||
+
|
||||
return ((REGNO (reg0) == REGNO (reg1))
|
||||
&& (val_diff == 4 || val_diff == -4));
|
||||
}
|
120
patches/gcc/3.4.6/601-gcc34-arm-ldm.patch
Normal file
120
patches/gcc/3.4.6/601-gcc34-arm-ldm.patch
Normal file
@ -0,0 +1,120 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/arm.c gcc-3.4.6/gcc/config/arm/arm.c
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/arm.c 2007-08-15 22:56:20.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/arm.c 2007-08-15 22:56:20.000000000 +0200
|
||||
@@ -8524,6 +8524,26 @@
|
||||
return_used_this_function = 0;
|
||||
}
|
||||
|
||||
+/* Return the number (counting from 0) of
|
||||
+ the least significant set bit in MASK. */
|
||||
+
|
||||
+#ifdef __GNUC__
|
||||
+inline
|
||||
+#endif
|
||||
+static int
|
||||
+number_of_first_bit_set (mask)
|
||||
+ int mask;
|
||||
+{
|
||||
+ int bit;
|
||||
+
|
||||
+ for (bit = 0;
|
||||
+ (mask & (1 << bit)) == 0;
|
||||
+ ++bit)
|
||||
+ continue;
|
||||
+
|
||||
+ return bit;
|
||||
+}
|
||||
+
|
||||
const char *
|
||||
arm_output_epilogue (rtx sibling)
|
||||
{
|
||||
@@ -8757,27 +8777,47 @@
|
||||
saved_regs_mask |= (1 << PC_REGNUM);
|
||||
}
|
||||
|
||||
- /* Load the registers off the stack. If we only have one register
|
||||
- to load use the LDR instruction - it is faster. */
|
||||
- if (saved_regs_mask == (1 << LR_REGNUM))
|
||||
- {
|
||||
- /* The exception handler ignores the LR, so we do
|
||||
- not really need to load it off the stack. */
|
||||
- if (eh_ofs)
|
||||
- asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM);
|
||||
- else
|
||||
- asm_fprintf (f, "\tldr\t%r, [%r], #4\n", LR_REGNUM, SP_REGNUM);
|
||||
- }
|
||||
- else if (saved_regs_mask)
|
||||
+ if (saved_regs_mask)
|
||||
{
|
||||
- if (saved_regs_mask & (1 << SP_REGNUM))
|
||||
- /* Note - write back to the stack register is not enabled
|
||||
- (ie "ldmfd sp!..."). We know that the stack pointer is
|
||||
- in the list of registers and if we add writeback the
|
||||
- instruction becomes UNPREDICTABLE. */
|
||||
- print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask);
|
||||
+ /* Load the registers off the stack. If we only have one register
|
||||
+ to load use the LDR instruction - it is faster. */
|
||||
+ if (bit_count (saved_regs_mask) == 1)
|
||||
+ {
|
||||
+ int reg = number_of_first_bit_set (saved_regs_mask);
|
||||
+
|
||||
+ switch (reg)
|
||||
+ {
|
||||
+ case SP_REGNUM:
|
||||
+ /* Mustn't use base writeback when loading SP. */
|
||||
+ asm_fprintf (f, "\tldr\t%r, [%r]\n", SP_REGNUM, SP_REGNUM);
|
||||
+ break;
|
||||
+
|
||||
+ case LR_REGNUM:
|
||||
+ if (eh_ofs)
|
||||
+ {
|
||||
+ /* The exception handler ignores the LR, so we do
|
||||
+ not really need to load it off the stack. */
|
||||
+ asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM);
|
||||
+ break;
|
||||
+ }
|
||||
+ /* else fall through */
|
||||
+
|
||||
+ default:
|
||||
+ asm_fprintf (f, "\tldr\t%r, [%r], #4\n", reg, SP_REGNUM);
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
else
|
||||
- print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask);
|
||||
+ {
|
||||
+ if (saved_regs_mask & (1 << SP_REGNUM))
|
||||
+ /* Note - write back to the stack register is not enabled
|
||||
+ (ie "ldmfd sp!..."). We know that the stack pointer is
|
||||
+ in the list of registers and if we add writeback the
|
||||
+ instruction becomes UNPREDICTABLE. */
|
||||
+ print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask);
|
||||
+ else
|
||||
+ print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask);
|
||||
+ }
|
||||
}
|
||||
|
||||
if (current_function_pretend_args_size)
|
||||
@@ -11405,22 +11445,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
-/* Return the number (counting from 0) of
|
||||
- the least significant set bit in MASK. */
|
||||
-
|
||||
-inline static int
|
||||
-number_of_first_bit_set (int mask)
|
||||
-{
|
||||
- int bit;
|
||||
-
|
||||
- for (bit = 0;
|
||||
- (mask & (1 << bit)) == 0;
|
||||
- ++bit)
|
||||
- continue;
|
||||
-
|
||||
- return bit;
|
||||
-}
|
||||
-
|
||||
/* Generate code to return from a thumb function.
|
||||
If 'reg_containing_return_addr' is -1, then the return address is
|
||||
actually on the stack, at the stack pointer. */
|
24
patches/gcc/3.4.6/602-sdk-libstdc++-includes.patch
Normal file
24
patches/gcc/3.4.6/602-sdk-libstdc++-includes.patch
Normal file
@ -0,0 +1,24 @@
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/fragment.am gcc-3.4.6/libstdc++-v3/fragment.am
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/fragment.am 2003-08-27 02:38:28.000000000 +0200
|
||||
+++ gcc-3.4.6/libstdc++-v3/fragment.am 2007-08-15 22:59:09.000000000 +0200
|
||||
@@ -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
|
||||
|
||||
|
||||
|
||||
diff -durN gcc-3.4.6.orig/libstdc++-v3/libmath/Makefile.am gcc-3.4.6/libstdc++-v3/libmath/Makefile.am
|
||||
--- gcc-3.4.6.orig/libstdc++-v3/libmath/Makefile.am 2003-08-27 23:29:43.000000000 +0200
|
||||
+++ gcc-3.4.6/libstdc++-v3/libmath/Makefile.am 2007-08-15 22:59:09.000000000 +0200
|
||||
@@ -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
|
27
patches/gcc/3.4.6/700-pr15068-fix.patch
Normal file
27
patches/gcc/3.4.6/700-pr15068-fix.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/flow.c gcc-3.4.6/gcc/flow.c
|
||||
--- gcc-3.4.6.orig/gcc/flow.c 2005-09-01 22:51:09.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/flow.c 2007-08-15 23:00:30.000000000 +0200
|
||||
@@ -1884,6 +1884,7 @@
|
||||
rtx set_src = SET_SRC (pc_set (BB_END (bb)));
|
||||
rtx cond_true = XEXP (set_src, 0);
|
||||
rtx reg = XEXP (cond_true, 0);
|
||||
+ enum rtx_code inv_cond;
|
||||
|
||||
if (GET_CODE (reg) == SUBREG)
|
||||
reg = SUBREG_REG (reg);
|
||||
@@ -1892,11 +1893,13 @@
|
||||
in the form of a comparison of a register against zero.
|
||||
If the condition is more complex than that, then it is safe
|
||||
not to record any information. */
|
||||
- if (GET_CODE (reg) == REG
|
||||
+ inv_cond = reversed_comparison_code (cond_true, BB_END (bb));
|
||||
+ if (inv_cond != UNKNOWN
|
||||
+ && GET_CODE (reg) == REG
|
||||
&& XEXP (cond_true, 1) == const0_rtx)
|
||||
{
|
||||
rtx cond_false
|
||||
- = gen_rtx_fmt_ee (reverse_condition (GET_CODE (cond_true)),
|
||||
+ = gen_rtx_fmt_ee (inv_cond,
|
||||
GET_MODE (cond_true), XEXP (cond_true, 0),
|
||||
XEXP (cond_true, 1));
|
||||
if (GET_CODE (XEXP (set_src, 1)) == PC)
|
44
patches/gcc/3.4.6/71_all_sh-pr16665-fix.patch
Normal file
44
patches/gcc/3.4.6/71_all_sh-pr16665-fix.patch
Normal file
@ -0,0 +1,44 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sh/sh.c gcc-3.4.6/gcc/config/sh/sh.c
|
||||
--- gcc-3.4.6.orig/gcc/config/sh/sh.c 2004-09-03 08:51:30.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/sh/sh.c 2007-08-15 23:01:48.000000000 +0200
|
||||
@@ -9107,6 +9107,15 @@
|
||||
}
|
||||
this = FUNCTION_ARG (cum, Pmode, ptr_type_node, 1);
|
||||
|
||||
+ /* In PIC case, we set PIC register to compute the target address. We
|
||||
+ can use a scratch register to save and restore the original value
|
||||
+ except for SHcompact. For SHcompact, use stack. */
|
||||
+ if (flag_pic && TARGET_SHCOMPACT)
|
||||
+ {
|
||||
+ push (PIC_OFFSET_TABLE_REGNUM);
|
||||
+ emit_insn (gen_GOTaddr2picreg ());
|
||||
+ }
|
||||
+
|
||||
/* For SHcompact, we only have r0 for a scratch register: r1 is the
|
||||
static chain pointer (even if you can't have nested virtual functions
|
||||
right now, someone might implement them sometime), and the rest of the
|
||||
@@ -9189,8 +9198,24 @@
|
||||
assemble_external (function);
|
||||
TREE_USED (function) = 1;
|
||||
}
|
||||
+ /* We can use scratch1 to save and restore the original value of
|
||||
+ PIC register except for SHcompact. */
|
||||
+ if (flag_pic && ! TARGET_SHCOMPACT)
|
||||
+ {
|
||||
+ emit_move_insn (scratch1,
|
||||
+ gen_rtx_REG (Pmode, PIC_OFFSET_TABLE_REGNUM));
|
||||
+ emit_insn (gen_GOTaddr2picreg ());
|
||||
+ }
|
||||
funexp = XEXP (DECL_RTL (function), 0);
|
||||
emit_move_insn (scratch2, funexp);
|
||||
+ if (flag_pic)
|
||||
+ {
|
||||
+ if (! TARGET_SHCOMPACT)
|
||||
+ emit_move_insn (gen_rtx_REG (Pmode, PIC_OFFSET_TABLE_REGNUM),
|
||||
+ scratch1);
|
||||
+ else
|
||||
+ pop (PIC_OFFSET_TABLE_REGNUM);
|
||||
+ }
|
||||
funexp = gen_rtx_MEM (FUNCTION_MODE, scratch2);
|
||||
sibcall = emit_call_insn (gen_sibcall (funexp, const0_rtx, NULL_RTX));
|
||||
SIBLING_CALL_P (sibcall) = 1;
|
14
patches/gcc/3.4.6/72_all_sh-no-reorder-blocks.patch
Normal file
14
patches/gcc/3.4.6/72_all_sh-no-reorder-blocks.patch
Normal file
@ -0,0 +1,14 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sh/sh.h gcc-3.4.6/gcc/config/sh/sh.h
|
||||
--- gcc-3.4.6.orig/gcc/config/sh/sh.h 2006-01-12 02:20:32.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/sh/sh.h 2007-08-15 23:03:09.000000000 +0200
|
||||
@@ -422,6 +422,10 @@
|
||||
do { \
|
||||
if (LEVEL) \
|
||||
flag_omit_frame_pointer = -1; \
|
||||
+ if (LEVEL <= 2) \
|
||||
+ { \
|
||||
+ flag_reorder_blocks = 0; \
|
||||
+ } \
|
||||
if (SIZE) \
|
||||
target_flags |= SPACE_BIT; \
|
||||
if (TARGET_SHMEDIA && LEVEL > 1) \
|
24
patches/gcc/3.4.6/73_all_sh-pr20617.patch
Normal file
24
patches/gcc/3.4.6/73_all_sh-pr20617.patch
Normal file
@ -0,0 +1,24 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/sh/lib1funcs.asm gcc-3.4.6/gcc/config/sh/lib1funcs.asm
|
||||
--- gcc-3.4.6.orig/gcc/config/sh/lib1funcs.asm 2003-08-12 03:25:07.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/sh/lib1funcs.asm 2007-08-15 23:04:26.000000000 +0200
|
||||
@@ -37,9 +37,19 @@
|
||||
ELF local label prefixes by J"orn Rennecke
|
||||
amylaar@cygnus.com */
|
||||
|
||||
+#define ALIAS(X,Y) .global GLOBAL(X); .set GLOBAL(X),GLOBAL(Y)
|
||||
+
|
||||
#ifdef __ELF__
|
||||
#define LOCAL(X) .L_##X
|
||||
-#define FUNC(X) .type X,@function
|
||||
+
|
||||
+#if 1 /* ??? The export list mechanism is broken, everything that is not
|
||||
+ hidden is exported. */
|
||||
+#undef FUNC
|
||||
+#define FUNC(X) .type X,@function; .hidden X
|
||||
+#undef ALIAS
|
||||
+#define ALIAS(X,Y) .global GLOBAL(X); .set GLOBAL(X),GLOBAL(Y); .hidden GLOBAL(X)
|
||||
+#endif
|
||||
+
|
||||
#define ENDFUNC0(X) .Lfe_##X: .size X,.Lfe_##X-X
|
||||
#define ENDFUNC(X) ENDFUNC0(X)
|
||||
#else
|
65
patches/gcc/3.4.6/800-arm-bigendian.patch
Normal file
65
patches/gcc/3.4.6/800-arm-bigendian.patch
Normal file
@ -0,0 +1,65 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/linux-elf.h gcc-3.4.6/gcc/config/arm/linux-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/linux-elf.h 2007-08-15 22:51:01.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/linux-elf.h 2007-08-15 23:05:42.000000000 +0200
|
||||
@@ -30,17 +30,34 @@
|
||||
/* Do not assume anything about header files. */
|
||||
#define NO_IMPLICIT_EXTERN_C
|
||||
|
||||
+/*
|
||||
+ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-*
|
||||
+ * (big endian) configurations.
|
||||
+ */
|
||||
+#if TARGET_BIG_ENDIAN_DEFAULT
|
||||
+#define TARGET_ENDIAN_DEFAULT ARM_FLAG_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
|
||||
+
|
||||
/* Default is to use APCS-32 mode. */
|
||||
#undef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT (ARM_FLAG_APCS_32 | ARM_FLAG_MMU_TRAPS)
|
||||
+#define TARGET_DEFAULT \
|
||||
+ ( ARM_FLAG_APCS_32 | \
|
||||
+ ARM_FLAG_MMU_TRAPS | \
|
||||
+ 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", "mapcs-32", "mno-thumb-interwork" }
|
||||
+ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mapcs-32", "mno-thumb-interwork" }
|
||||
|
||||
#define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__"
|
||||
|
||||
@@ -94,7 +111,7 @@
|
||||
%{rdynamic:-export-dynamic} \
|
||||
%{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "} \
|
||||
-X \
|
||||
- %{mbig-endian:-EB}" \
|
||||
+ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \
|
||||
SUBTARGET_EXTRA_LINK_SPEC
|
||||
|
||||
#define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS()
|
||||
diff -durN gcc-3.4.6.orig/gcc/config.gcc gcc-3.4.6/gcc/config.gcc
|
||||
--- gcc-3.4.6.orig/gcc/config.gcc 2007-08-15 22:51:01.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config.gcc 2007-08-15 23:05:42.000000000 +0200
|
||||
@@ -678,6 +678,11 @@
|
||||
;;
|
||||
arm*-*-linux*) # ARM GNU/Linux with ELF
|
||||
tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h"
|
||||
+ case $target in
|
||||
+ arm*b-*)
|
||||
+ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines"
|
||||
+ ;;
|
||||
+ esac
|
||||
tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux"
|
||||
extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
|
||||
gnu_ld=yes
|
16
patches/gcc/3.4.6/800-powerpc-libc_stack_end-uclibc.patch
Normal file
16
patches/gcc/3.4.6/800-powerpc-libc_stack_end-uclibc.patch
Normal file
@ -0,0 +1,16 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/rs6000/linux-unwind.h gcc-3.4.6/gcc/config/rs6000/linux-unwind.h
|
||||
--- gcc-3.4.6.orig/gcc/config/rs6000/linux-unwind.h 2005-03-17 11:41:18.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/rs6000/linux-unwind.h 2007-08-15 23:07:00.000000000 +0200
|
||||
@@ -32,6 +32,7 @@
|
||||
these structs elsewhere; Many fields are missing, particularly
|
||||
from the end of the structures. */
|
||||
|
||||
+#ifndef inhibit_libc
|
||||
struct gcc_vregs
|
||||
{
|
||||
__attribute__ ((vector_size (16))) int vr[32];
|
||||
@@ -320,3 +321,4 @@
|
||||
\
|
||||
goto SUCCESS; \
|
||||
} while (0)
|
||||
+#endif
|
7
patches/gcc/3.4.6/810-mips-xgot.patch
Normal file
7
patches/gcc/3.4.6/810-mips-xgot.patch
Normal file
@ -0,0 +1,7 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/mips/t-linux gcc-3.4.6/gcc/config/mips/t-linux
|
||||
--- gcc-3.4.6.orig/gcc/config/mips/t-linux 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/mips/t-linux 2007-08-15 23:08:15.000000000 +0200
|
||||
@@ -0,0 +1,3 @@
|
||||
+# Compile crtbegin/end with xgot so it works for both
|
||||
+# normal and large GOTs.
|
||||
+CRTSTUFF_T_CFLAGS = -mxgot
|
10231
patches/gcc/3.4.6/900-nios2.patch
Normal file
10231
patches/gcc/3.4.6/900-nios2.patch
Normal file
File diff suppressed because it is too large
Load Diff
161
patches/gcc/3.4.6/arm-softfloat.patch
Normal file
161
patches/gcc/3.4.6/arm-softfloat.patch
Normal file
@ -0,0 +1,161 @@
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/coff.h gcc-3.4.6/gcc/config/arm/coff.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/coff.h 2004-02-24 15:25:22.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/arm/coff.h 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -31,11 +31,16 @@
|
||||
#define TARGET_VERSION fputs (" (ARM/coff)", stderr)
|
||||
|
||||
#undef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS)
|
||||
+#define TARGET_DEFAULT \
|
||||
+ ( ARM_FLAG_SOFT_FLOAT \
|
||||
+ | ARM_FLAG_VFP \
|
||||
+ | ARM_FLAG_APCS_32 \
|
||||
+ | ARM_FLAG_APCS_FRAME \
|
||||
+ | ARM_FLAG_MMU_TRAPS )
|
||||
|
||||
#ifndef MULTILIB_DEFAULTS
|
||||
#define MULTILIB_DEFAULTS \
|
||||
- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork" }
|
||||
+ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork" }
|
||||
#endif
|
||||
|
||||
/* This is COFF, but prefer stabs. */
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/elf.h gcc-3.4.6/gcc/config/arm/elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/elf.h 2004-02-24 15:25:22.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/arm/elf.h 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -46,7 +46,9 @@
|
||||
|
||||
#ifndef SUBTARGET_ASM_FLOAT_SPEC
|
||||
#define SUBTARGET_ASM_FLOAT_SPEC "\
|
||||
-%{mapcs-float:-mfloat} %{msoft-float:-mfpu=softfpa}"
|
||||
+%{mapcs-float:-mfloat} \
|
||||
+%{mhard-float:-mfpu=fpa} \
|
||||
+%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}"
|
||||
#endif
|
||||
|
||||
#ifndef ASM_SPEC
|
||||
@@ -106,12 +108,17 @@
|
||||
#endif
|
||||
|
||||
#ifndef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS)
|
||||
+#define TARGET_DEFAULT \
|
||||
+ ( ARM_FLAG_SOFT_FLOAT \
|
||||
+ | ARM_FLAG_VFP \
|
||||
+ | ARM_FLAG_APCS_32 \
|
||||
+ | ARM_FLAG_APCS_FRAME \
|
||||
+ | ARM_FLAG_MMU_TRAPS )
|
||||
#endif
|
||||
|
||||
#ifndef MULTILIB_DEFAULTS
|
||||
#define MULTILIB_DEFAULTS \
|
||||
- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" }
|
||||
+ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" }
|
||||
#endif
|
||||
|
||||
#define TARGET_ASM_FILE_START_APP_OFF true
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/linux-elf.h gcc-3.4.6/gcc/config/arm/linux-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/linux-elf.h 2007-08-15 23:07:00.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/linux-elf.h 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -44,12 +44,26 @@
|
||||
#define TARGET_LINKER_EMULATION "armelf_linux"
|
||||
#endif
|
||||
|
||||
-/* Default is to use APCS-32 mode. */
|
||||
+/*
|
||||
+ * Default is to use APCS-32 mode with soft-vfp.
|
||||
+ * The old Linux default for floats can be achieved with -mhard-float
|
||||
+ * or with the configure --with-float=hard option.
|
||||
+ * If -msoft-float or --with-float=soft is used then software float
|
||||
+ * support will be used just like the default but with the legacy
|
||||
+ * big endian word ordering for double float representation instead.
|
||||
+ */
|
||||
#undef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT \
|
||||
- ( ARM_FLAG_APCS_32 | \
|
||||
- ARM_FLAG_MMU_TRAPS | \
|
||||
- TARGET_ENDIAN_DEFAULT )
|
||||
+#define TARGET_DEFAULT \
|
||||
+ ( ARM_FLAG_APCS_32 \
|
||||
+ | ARM_FLAG_SOFT_FLOAT \
|
||||
+ | TARGET_ENDIAN_DEFAULT \
|
||||
+ | ARM_FLAG_VFP \
|
||||
+ | ARM_FLAG_MMU_TRAPS )
|
||||
+
|
||||
+#undef SUBTARGET_EXTRA_ASM_SPEC
|
||||
+#define SUBTARGET_EXTRA_ASM_SPEC "\
|
||||
+%{mhard-float:-mfpu=fpa} \
|
||||
+%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}"
|
||||
|
||||
#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6
|
||||
|
||||
@@ -57,7 +71,7 @@
|
||||
|
||||
#undef MULTILIB_DEFAULTS
|
||||
#define MULTILIB_DEFAULTS \
|
||||
- { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mapcs-32", "mno-thumb-interwork" }
|
||||
+ { "marm", TARGET_ENDIAN_OPTION, "mapcs-32", "mno-thumb-interwork" }
|
||||
|
||||
#define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__"
|
||||
|
||||
@@ -72,7 +86,7 @@
|
||||
%{shared:-lc} \
|
||||
%{!shared:%{profile:-lc_p}%{!profile:-lc}}"
|
||||
|
||||
-#define LIBGCC_SPEC "%{msoft-float:-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
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/t-linux gcc-3.4.6/gcc/config/arm/t-linux
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/t-linux 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -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
|
||||
|
||||
# MULTILIB_OPTIONS = mhard-float/msoft-float
|
||||
# MULTILIB_DIRNAMES = hard-float soft-float
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/unknown-elf.h gcc-3.4.6/gcc/config/arm/unknown-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/unknown-elf.h 2004-02-24 15:25:22.000000000 +0100
|
||||
+++ gcc-3.4.6/gcc/config/arm/unknown-elf.h 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -30,7 +30,12 @@
|
||||
|
||||
/* Default to using APCS-32 and software floating point. */
|
||||
#ifndef TARGET_DEFAULT
|
||||
-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS)
|
||||
+#define TARGET_DEFAULT \
|
||||
+ ( ARM_FLAG_SOFT_FLOAT \
|
||||
+ | ARM_FLAG_VFP \
|
||||
+ | ARM_FLAG_APCS_32 \
|
||||
+ | ARM_FLAG_APCS_FRAME \
|
||||
+ | ARM_FLAG_MMU_TRAPS )
|
||||
#endif
|
||||
|
||||
/* Now we define the strings used to build the spec file. */
|
||||
diff -durN gcc-3.4.6.orig/gcc/config/arm/xscale-elf.h gcc-3.4.6/gcc/config/arm/xscale-elf.h
|
||||
--- gcc-3.4.6.orig/gcc/config/arm/xscale-elf.h 2003-07-02 01:26:43.000000000 +0200
|
||||
+++ gcc-3.4.6/gcc/config/arm/xscale-elf.h 2007-08-15 23:10:54.000000000 +0200
|
||||
@@ -49,11 +49,12 @@
|
||||
endian, regardless of the endian-ness of the memory
|
||||
system. */
|
||||
|
||||
-#define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \
|
||||
- %{mhard-float:-mfpu=fpa} \
|
||||
- %{!mhard-float: %{msoft-float:-mfpu=softfpa;:-mfpu=softvfp}}"
|
||||
+#define SUBTARGET_EXTRA_ASM_SPEC "\
|
||||
+%{!mcpu=*:-mcpu=xscale} \
|
||||
+%{mhard-float:-mfpu=fpa} \
|
||||
+%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}"
|
||||
|
||||
#ifndef MULTILIB_DEFAULTS
|
||||
#define MULTILIB_DEFAULTS \
|
||||
- { "mlittle-endian", "mno-thumb-interwork", "marm", "msoft-float" }
|
||||
+ { "mlittle-endian", "mno-thumb-interwork", "marm" }
|
||||
#endif
|
Loading…
x
Reference in New Issue
Block a user