summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/dependencies/dependencies.mk1
-rwxr-xr-xtoolchain/dependencies/dependencies.sh12
-rw-r--r--toolchain/gcc/4.4.4/powerpc-link-with-math-lib.patch.conditional137
-rw-r--r--toolchain/kernel-headers/Config.in8
-rw-r--r--toolchain/kernel-headers/linux-2.6.32.18-scsi-use-__uX-types-for-headers-exported-to-user-space.patch (renamed from toolchain/kernel-headers/linux-2.6.32.16-scsi-use-__uX-types-for-headers-exported-to-user-space.patch)0
-rw-r--r--toolchain/kernel-headers/linux-2.6.33.7-scsi-use-__uX-types-for-headers-exported-to-user-space.patch (renamed from toolchain/kernel-headers/linux-2.6.33.6-scsi-use-__uX-types-for-headers-exported-to-user-space.patch)0
-rw-r--r--toolchain/kernel-headers/linux-2.6.34.3-scsi-use-__uX-types-for-headers-exported-to-user-space.patch (renamed from toolchain/kernel-headers/linux-2.6.34.1-scsi-use-__uX-types-for-headers-exported-to-user-space.patch)0
-rw-r--r--toolchain/toolchain-common.in6
-rw-r--r--toolchain/uClibc/uClibc-0.9.30.3-fix-error-locale-utf-8.patch17
-rw-r--r--toolchain/uClibc/uClibc-0.9.31-fix-error-locale-utf-8.patch17
10 files changed, 191 insertions, 7 deletions
diff --git a/toolchain/dependencies/dependencies.mk b/toolchain/dependencies/dependencies.mk
index d50042462..b334811ac 100644
--- a/toolchain/dependencies/dependencies.mk
+++ b/toolchain/dependencies/dependencies.mk
@@ -16,6 +16,7 @@ endif
dependencies: host-sed $(DEPENDENCIES_HOST_PREREQ)
@HOSTCC="$(firstword $(HOSTCC))" MAKE="$(MAKE)" \
HOST_SED_DIR="$(HOST_SED_DIR)" \
+ CONFIG_FILE="$(CONFIG_DIR)/.config" \
$(TOPDIR)/toolchain/dependencies/dependencies.sh
dependencies-source:
diff --git a/toolchain/dependencies/dependencies.sh b/toolchain/dependencies/dependencies.sh
index b3822ef66..b47e9d81e 100755
--- a/toolchain/dependencies/dependencies.sh
+++ b/toolchain/dependencies/dependencies.sh
@@ -152,3 +152,15 @@ for prog in awk bison flex msgfmt makeinfo patch gzip bzip2 perl tar wget cpio p
exit 1;
fi
done
+
+if grep ^BR2_TOOLCHAIN_BUILDROOT=y $CONFIG_FILE > /dev/null && \
+ grep ^BR2_ENABLE_LOCALE=y $CONFIG_FILE > /dev/null ; then
+ if ! which locale > /dev/null ; then
+ /bin/echo -e "\nYou need locale support on your build machine to build a toolchain supporting locales\n"
+ exit 1 ;
+ fi
+ if ! locale -a | grep -i utf8$ ; then
+ /bin/echo -e "\nYou need at least one UTF8 locale to build a toolchain supporting locales\n"
+ exit 1 ;
+ fi
+fi
diff --git a/toolchain/gcc/4.4.4/powerpc-link-with-math-lib.patch.conditional b/toolchain/gcc/4.4.4/powerpc-link-with-math-lib.patch.conditional
new file mode 100644
index 000000000..3fe8757d7
--- /dev/null
+++ b/toolchain/gcc/4.4.4/powerpc-link-with-math-lib.patch.conditional
@@ -0,0 +1,137 @@
+http://gcc.gnu.org/ml/gcc-patches/2008-10/msg00269.html
+
+On glibc the libc.so carries a copy of the math function copysignl() but
+on uClibc math functions like copysignl() live in libm. Since libgcc_s
+contains unresolved symbols, any attempt to link against libgcc_s
+without explicitely specifying -lm fails, resulting in a broken
+bootstrap of the compiler.
+
+
+diff -rdup gcc-4.4.0.old/gcc/config/t-slibgcc-elf-ver gcc-4.4.0/gcc/config/t-slibgcc-elf-ver
+
+diff -durN gcc-4.4.4.orig/gcc/config/t-slibgcc-elf-ver gcc-4.4.4/gcc/config/t-slibgcc-elf-ver
+--- gcc-4.4.4.orig/gcc/config/t-slibgcc-elf-ver 2010-01-04 16:13:08.000000000 +0100
++++ gcc-4.4.4/gcc/config/t-slibgcc-elf-ver 2010-05-16 19:38:36.000000000 +0200
+@@ -9,7 +9,7 @@
+ SHLIB_OBJS = @shlib_objs@
+ SHLIB_DIR = @multilib_dir@
+ SHLIB_SLIBDIR_QUAL = @shlib_slibdir_qual@
+-SHLIB_LC = -lc
++SHLIB_LC = @libgcc_libm@ -lc
+ SHLIB_MAKE_SOLINK = $(LN_S) $(SHLIB_SONAME) $(SHLIB_DIR)/$(SHLIB_SOLINK)
+ SHLIB_INSTALL_SOLINK = $(LN_S) $(SHLIB_SONAME) \
+ $$(DESTDIR)$$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_SOLINK)
+diff -durN gcc-4.4.4.orig/libgcc/Makefile.in gcc-4.4.4/libgcc/Makefile.in
+--- gcc-4.4.4.orig/libgcc/Makefile.in 2009-04-10 01:23:07.000000000 +0200
++++ gcc-4.4.4/libgcc/Makefile.in 2010-05-16 19:38:36.000000000 +0200
+@@ -39,6 +39,7 @@
+ decimal_float = @decimal_float@
+ enable_decimal_float = @enable_decimal_float@
+ fixed_point = @fixed_point@
++LIBGCC_LIBM = @LIBGCC_LIBM@
+
+ host_noncanonical = @host_noncanonical@
+
+@@ -787,9 +788,10 @@
+ @multilib_dir@,$(MULTIDIR),$(subst \
+ @shlib_objs@,$(objects),$(subst \
+ @shlib_base_name@,libgcc_s,$(subst \
++ @libgcc_libm@,$(LIBGCC_LIBM),$(subst \
+ @shlib_map_file@,$(mapfile),$(subst \
+ @shlib_slibdir_qual@,$(MULTIOSSUBDIR),$(subst \
+- @shlib_slibdir@,$(shlib_slibdir),$(SHLIB_LINK))))))))
++ @shlib_slibdir@,$(shlib_slibdir),$(SHLIB_LINK)))))))))
+
+ libunwind$(SHLIB_EXT): $(libunwind-s-objects) $(extra-parts)
+ # @multilib_flags@ is still needed because this may use
+diff -durN gcc-4.4.4.orig/libgcc/configure gcc-4.4.4/libgcc/configure
+--- gcc-4.4.4.orig/libgcc/configure 2008-11-20 18:13:01.000000000 +0100
++++ gcc-4.4.4/libgcc/configure 2010-05-16 19:38:36.000000000 +0200
+@@ -272,7 +272,7 @@
+ PACKAGE_BUGREPORT=''
+
+ ac_unique_file="static-object.mk"
+-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS libgcc_topdir enable_shared slibdir INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AWK build build_cpu build_vendor build_os host host_cpu host_vendor host_os host_noncanonical build_libsubdir build_subdir host_subdir target_subdir AR ac_ct_AR LIPO ac_ct_LIPO NM ac_ct_NM RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP LN_S CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP decimal_float enable_decimal_float fixed_point vis_hide set_have_cc_tls tmake_file extra_parts asm_hidden_op LIBOBJS LTLIBOBJS'
++ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS libgcc_topdir enable_shared slibdir INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AWK build build_cpu build_vendor build_os host host_cpu host_vendor host_os host_noncanonical build_libsubdir build_subdir host_subdir target_subdir AR ac_ct_AR LIPO ac_ct_LIPO NM ac_ct_NM RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP LN_S CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP decimal_float enable_decimal_float fixed_point vis_hide set_have_cc_tls LIBGCC_LIBM tmake_file extra_parts asm_hidden_op LIBOBJS LTLIBOBJS'
+ ac_subst_files=''
+ ac_pwd=`pwd`
+
+@@ -3547,6 +3547,39 @@
+ fi
+
+
++# On powerpc libgcc_s references copysignl which is a libm function but
++# glibc apparently also provides it via libc as opposed to uClibc where
++# it lives in libm.
++echo "$as_me:$LINENO: checking for library containing copysignl" >&5
++echo $ECHO_N "checking for library containing copysignl... $ECHO_C" >&6
++if test "${libgcc_cv_copysignl_lib+set}" = set; then
++ echo $ECHO_N "(cached) $ECHO_C" >&6
++else
++
++ echo '#include <features.h>' > conftest.c
++ echo 'int the_libc = __UCLIBC__ + __powerpc__;' >> conftest.c
++ libgcc_cv_copysignl_lib="-lc"
++ if { ac_try='${CC-cc} -S conftest.c -o conftest.s 1>&5'
++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
++ (eval $ac_try) 2>&5
++ ac_status=$?
++ echo "$as_me:$LINENO: \$? = $ac_status" >&5
++ (exit $ac_status); }; }
++ then
++ libgcc_cv_copysignl_lib="-lm"
++ fi
++ rm -f conftest.*
++
++fi
++echo "$as_me:$LINENO: result: $libgcc_cv_copysignl_lib" >&5
++echo "${ECHO_T}$libgcc_cv_copysignl_lib" >&6
++
++case /${libgcc_cv_copysignl_lib}/ in
++ /-lm/) LIBGCC_LIBM="$LIBGCC_LIBM -lm" ;;
++ *) LIBGCC_LIBM= ;;
++esac
++
++
+ # Conditionalize the makefile for this target machine.
+ tmake_file_=
+ for f in ${tmake_file}
+@@ -4267,6 +4300,7 @@
+ s,@fixed_point@,$fixed_point,;t t
+ s,@vis_hide@,$vis_hide,;t t
+ s,@set_have_cc_tls@,$set_have_cc_tls,;t t
++s,@LIBGCC_LIBM@,$LIBGCC_LIBM,;t t
+ s,@tmake_file@,$tmake_file,;t t
+ s,@extra_parts@,$extra_parts,;t t
+ s,@asm_hidden_op@,$asm_hidden_op,;t t
+diff -durN gcc-4.4.4.orig/libgcc/configure.ac gcc-4.4.4/libgcc/configure.ac
+--- gcc-4.4.4.orig/libgcc/configure.ac 2008-11-20 18:13:01.000000000 +0100
++++ gcc-4.4.4/libgcc/configure.ac 2010-05-16 19:38:36.000000000 +0200
+@@ -223,6 +223,27 @@
+ fi
+ AC_SUBST(set_have_cc_tls)
+
++# On powerpc libgcc_s references copysignl which is a libm function but
++# glibc apparently also provides it via libc as opposed to uClibc where
++# it lives in libm.
++AC_CACHE_CHECK
++ libgcc_cv_copysignl_lib,
++ echo '#include <features.h>' > conftest.c
++ echo 'int the_libc = __UCLIBC__ + __powerpc__;' >> conftest.c
++ libgcc_cv_copysignl_lib="-lc"
++ if AC_TRY_COMMAND(${CC-cc} -S conftest.c -o conftest.s 1>&AS_MESSAGE_LOG_FD)
++ then
++ libgcc_cv_copysignl_lib="-lm"
++ fi
++ rm -f conftest.*
++ ])
++
++case /${libgcc_cv_copysignl_lib}/ in
++ /-lm/) LIBGCC_LIBM="$LIBGCC_LIBM -lm" ;;
++ *) LIBGCC_LIBM= ;;
++esac
++AC_SUBST(LIBGCC_LIBM)
++
+ # Conditionalize the makefile for this target machine.
+ tmake_file_=
+ for f in ${tmake_file}
diff --git a/toolchain/kernel-headers/Config.in b/toolchain/kernel-headers/Config.in
index fea3ee4ff..e60595fc3 100644
--- a/toolchain/kernel-headers/Config.in
+++ b/toolchain/kernel-headers/Config.in
@@ -61,13 +61,13 @@ config BR2_DEFAULT_KERNEL_VERSION
config BR2_DEFAULT_KERNEL_HEADERS
string
- default "2.6.27.47" if BR2_KERNEL_HEADERS_2_6_27
+ default "2.6.27.50" if BR2_KERNEL_HEADERS_2_6_27
default "2.6.28.10" if BR2_KERNEL_HEADERS_2_6_28
default "2.6.29.6" if BR2_KERNEL_HEADERS_2_6_29
default "2.6.30.10" if BR2_KERNEL_HEADERS_2_6_30
default "2.6.31.14" if BR2_KERNEL_HEADERS_2_6_31
- default "2.6.32.16" if BR2_KERNEL_HEADERS_2_6_32
- default "2.6.33.6" if BR2_KERNEL_HEADERS_2_6_33
- default "2.6.34.1" if BR2_KERNEL_HEADERS_2_6_34
+ default "2.6.32.18" if BR2_KERNEL_HEADERS_2_6_32
+ default "2.6.33.7" if BR2_KERNEL_HEADERS_2_6_33
+ default "2.6.34.3" if BR2_KERNEL_HEADERS_2_6_34
default "2.6" if BR2_KERNEL_HEADERS_SNAP
default $BR2_DEFAULT_KERNEL_VERSION if BR2_KERNEL_HEADERS_VERSION
diff --git a/toolchain/kernel-headers/linux-2.6.32.16-scsi-use-__uX-types-for-headers-exported-to-user-space.patch b/toolchain/kernel-headers/linux-2.6.32.18-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
index 2fc6176e8..2fc6176e8 100644
--- a/toolchain/kernel-headers/linux-2.6.32.16-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
+++ b/toolchain/kernel-headers/linux-2.6.32.18-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
diff --git a/toolchain/kernel-headers/linux-2.6.33.6-scsi-use-__uX-types-for-headers-exported-to-user-space.patch b/toolchain/kernel-headers/linux-2.6.33.7-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
index 1089c7106..1089c7106 100644
--- a/toolchain/kernel-headers/linux-2.6.33.6-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
+++ b/toolchain/kernel-headers/linux-2.6.33.7-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
diff --git a/toolchain/kernel-headers/linux-2.6.34.1-scsi-use-__uX-types-for-headers-exported-to-user-space.patch b/toolchain/kernel-headers/linux-2.6.34.3-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
index 1089c7106..1089c7106 100644
--- a/toolchain/kernel-headers/linux-2.6.34.1-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
+++ b/toolchain/kernel-headers/linux-2.6.34.3-scsi-use-__uX-types-for-headers-exported-to-user-space.patch
diff --git a/toolchain/toolchain-common.in b/toolchain/toolchain-common.in
index 3c70f9c77..ea06acefa 100644
--- a/toolchain/toolchain-common.in
+++ b/toolchain/toolchain-common.in
@@ -157,7 +157,7 @@ config BR2_GCC_CROSS_CXX
config BR2_INSTALL_LIBSTDCPP
bool "Build/install c++ compiler and libstdc++?"
select BR2_GCC_CROSS_CXX
- depends on !(BR2_avr32 && BR2_ENABLE_LOCALE && BR2_UCLIBC_VERSION_0_9_31)
+ depends on !(! BR2_GCC_SUPPORTS_FINEGRAINEDMTUNE && BR2_ENABLE_LOCALE && BR2_UCLIBC_VERSION_0_9_31)
help
If you are building your own toolchain and want to build and install
the C++ compiler and library then you need to enable this option.
@@ -165,8 +165,8 @@ config BR2_INSTALL_LIBSTDCPP
support and you want to use the compiler / library then you need
to select this option.
-comment "C++ support broken in uClibc 0.9.31 with locale enabled"
- depends on BR2_avr32 && BR2_ENABLE_LOCALE && BR2_UCLIBC_VERSION_0_9_31
+comment "C++ support broken in uClibc 0.9.31 with locale enabled with gcc 4.2"
+ depends on !BR2_GCC_SUPPORTS_FINEGRAINEDMTUNE && BR2_ENABLE_LOCALE && BR2_UCLIBC_VERSION_0_9_31
config BR2_TARGET_OPTIMIZATION
string "Target Optimizations"
diff --git a/toolchain/uClibc/uClibc-0.9.30.3-fix-error-locale-utf-8.patch b/toolchain/uClibc/uClibc-0.9.30.3-fix-error-locale-utf-8.patch
new file mode 100644
index 000000000..2fe6c508c
--- /dev/null
+++ b/toolchain/uClibc/uClibc-0.9.30.3-fix-error-locale-utf-8.patch
@@ -0,0 +1,17 @@
+---
+ extra/locale/gen_wc8bit.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: uClibc-0.9.30.3/extra/locale/gen_wc8bit.c
+===================================================================
+--- uClibc-0.9.30.3.orig/extra/locale/gen_wc8bit.c
++++ uClibc-0.9.30.3/extra/locale/gen_wc8bit.c
+@@ -119,7 +119,7 @@
+ }
+
+ locale_failure:
+- printf("could not find a UTF8 locale ... please enable en_US.UTF-8\n");
++ fprintf(stderr, "could not find a UTF8 locale ... please enable en_US.UTF-8\n");
+ return EXIT_FAILURE;
+ locale_success:
+ pclose(fp);
diff --git a/toolchain/uClibc/uClibc-0.9.31-fix-error-locale-utf-8.patch b/toolchain/uClibc/uClibc-0.9.31-fix-error-locale-utf-8.patch
new file mode 100644
index 000000000..1305add50
--- /dev/null
+++ b/toolchain/uClibc/uClibc-0.9.31-fix-error-locale-utf-8.patch
@@ -0,0 +1,17 @@
+---
+ extra/locale/gen_wc8bit.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: uClibc-0.9.31/extra/locale/gen_wc8bit.c
+===================================================================
+--- uClibc-0.9.31.orig/extra/locale/gen_wc8bit.c
++++ uClibc-0.9.31/extra/locale/gen_wc8bit.c
+@@ -120,7 +120,7 @@
+ }
+
+ locale_failure:
+- printf("could not find a UTF8 locale ... please enable en_US.UTF-8\n");
++ fprintf(stderr, "could not find a UTF8 locale ... please enable en_US.UTF-8\n");
+ return EXIT_FAILURE;
+ locale_success:
+ pclose(fp);