Elyes Haouas has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/64021 )
Change subject: (only for test) crossgcc: Update to GCC 11.3 ......................................................................
(only for test) crossgcc: Update to GCC 11.3
Signed-off-by: Elyes Haouas ehaouas@noos.fr Change-Id: I27a2a16c2aa1cda36d7e8cb4dc48057fc210d110 --- M util/crossgcc/buildgcc D util/crossgcc/patches/gcc-11.2.0_ada-musl_workaround.patch D util/crossgcc/patches/gcc-11.2.0_gnat.patch D util/crossgcc/patches/gcc-11.2.0_libcpp.patch D util/crossgcc/patches/gcc-11.2.0_libgcc.patch R util/crossgcc/patches/gcc-11.3.0_asan_shadow_offset_callback.patch D util/crossgcc/sum/gcc-11.2.0.tar.xz.cksum A util/crossgcc/sum/gcc-11.3.0.tar.xz.cksum 8 files changed, 2 insertions(+), 249 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/21/64021/1
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc index b25b260..26326d8 100755 --- a/util/crossgcc/buildgcc +++ b/util/crossgcc/buildgcc @@ -35,7 +35,7 @@ GMP_VERSION=6.2.1 MPFR_VERSION=4.1.0 MPC_VERSION=1.2.1 -GCC_VERSION=11.2.0 +GCC_VERSION=11.3.0 BINUTILS_VERSION=2.37 IASL_VERSION=20220331 # CLANG version number diff --git a/util/crossgcc/patches/gcc-11.2.0_ada-musl_workaround.patch b/util/crossgcc/patches/gcc-11.2.0_ada-musl_workaround.patch deleted file mode 100644 index 1f504a4..0000000 --- a/util/crossgcc/patches/gcc-11.2.0_ada-musl_workaround.patch +++ /dev/null @@ -1,120 +0,0 @@ -diff --git a/gcc/ada/adaint.c b/gcc/ada/adaint.c -index 3b0aea92c05..998f2c66289 100644 ---- a/gcc/ada/adaint.c -+++ b/gcc/ada/adaint.c -@@ -107,6 +107,15 @@ - #define xmalloc(S) malloc (S) - #define xrealloc(V,S) realloc (V,S) - #else -+#if !defined(__ANDROID__) && defined(__linux__) -+#ifdef __cplusplus -+extern "C" { -+#endif -+#include <sched.h> -+#ifdef __cplusplus -+} -+#endif -+#endif - #include "config.h" - #include "system.h" - #include "version.h" -@@ -3265,7 +3274,7 @@ __gnat_lwp_self (void) - - /* Dynamic cpu sets */ - --cpu_set_t * -+void * - __gnat_cpu_alloc (size_t count) - { - return CPU_ALLOC (count); -@@ -3278,33 +3287,33 @@ __gnat_cpu_alloc_size (size_t count) - } - - void --__gnat_cpu_free (cpu_set_t *set) -+__gnat_cpu_free (void *set) - { -- CPU_FREE (set); -+ CPU_FREE ((cpu_set_t *)set); - } - - void --__gnat_cpu_zero (size_t count, cpu_set_t *set) -+__gnat_cpu_zero (size_t count, void *set) - { - CPU_ZERO_S (count, set); - } - - void --__gnat_cpu_set (int cpu, size_t count, cpu_set_t *set) -+__gnat_cpu_set (int cpu, size_t count, void *set) - { - /* Ada handles CPU numbers starting from 1, while C identifies the first - CPU by a 0, so we need to adjust. */ -- CPU_SET_S (cpu - 1, count, set); -+ CPU_SET_S (cpu - 1, count, (cpu_set_t *)set); - } - - #else /* !CPU_ALLOC */ - - /* Static cpu sets */ - --cpu_set_t * -+void * - __gnat_cpu_alloc (size_t count ATTRIBUTE_UNUSED) - { -- return (cpu_set_t *) xmalloc (sizeof (cpu_set_t)); -+ return xmalloc (sizeof (cpu_set_t)); - } - - size_t -@@ -3314,23 +3323,23 @@ __gnat_cpu_alloc_size (size_t count ATTRIBUTE_UNUSED) - } - - void --__gnat_cpu_free (cpu_set_t *set) -+__gnat_cpu_free (void *set) - { - free (set); - } - - void --__gnat_cpu_zero (size_t count ATTRIBUTE_UNUSED, cpu_set_t *set) -+__gnat_cpu_zero (size_t count ATTRIBUTE_UNUSED, void *set) - { - CPU_ZERO (set); - } - - void --__gnat_cpu_set (int cpu, size_t count ATTRIBUTE_UNUSED, cpu_set_t *set) -+__gnat_cpu_set (int cpu, size_t count ATTRIBUTE_UNUSED, void *set) - { - /* Ada handles CPU numbers starting from 1, while C identifies the first - CPU by a 0, so we need to adjust. */ -- CPU_SET (cpu - 1, set); -+ CPU_SET (cpu - 1, (cpu_set_t *)set); - } - #endif /* !CPU_ALLOC */ - #endif /* __linux__ */ -diff --git a/gcc/ada/adaint.h b/gcc/ada/adaint.h -index 0d12f7e9020..7b3def03fb0 100644 ---- a/gcc/ada/adaint.h -+++ b/gcc/ada/adaint.h -@@ -316,13 +316,11 @@ extern void *__gnat_lwp_self (void); - - /* Routines for interface to required CPU set primitives */ - --#include <sched.h> -- --extern cpu_set_t *__gnat_cpu_alloc (size_t); -+extern void *__gnat_cpu_alloc (size_t); - extern size_t __gnat_cpu_alloc_size (size_t); --extern void __gnat_cpu_free (cpu_set_t *); --extern void __gnat_cpu_zero (size_t, cpu_set_t *); --extern void __gnat_cpu_set (int, size_t, cpu_set_t *); -+extern void __gnat_cpu_free (void *); -+extern void __gnat_cpu_zero (size_t, void *); -+extern void __gnat_cpu_set (int, size_t, void *); - #endif - - #if defined (_WIN32) diff --git a/util/crossgcc/patches/gcc-11.2.0_gnat.patch b/util/crossgcc/patches/gcc-11.2.0_gnat.patch deleted file mode 100644 index 2d7cece..0000000 --- a/util/crossgcc/patches/gcc-11.2.0_gnat.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- gcc-6.1.0/gcc/ada/gcc-interface/Make-lang.in.bak 2015-08-24 16:23:25.004493665 +0200 -+++ gcc-6.1.0/gcc/ada/gcc-interface/Make-lang.in 2015-08-24 17:53:52.496636113 +0200 -@@ -45,7 +45,7 @@ - - - # Extra flags to pass to recursive makes. --COMMON_ADAFLAGS= -gnatpg -+COMMON_ADAFLAGS= -gnatpg -gnatwGUR - ifeq ($(TREECHECKING),) - CHECKING_ADAFLAGS= - else diff --git a/util/crossgcc/patches/gcc-11.2.0_libcpp.patch b/util/crossgcc/patches/gcc-11.2.0_libcpp.patch deleted file mode 100644 index df28c01..0000000 --- a/util/crossgcc/patches/gcc-11.2.0_libcpp.patch +++ /dev/null @@ -1,56 +0,0 @@ -GCC with `-Wformat-security -Werror=format-security` hardening options enabled -by default rejects some codes in libcpp. This patch fixes them. - ---- gcc-8.3.0/libcpp/expr.c.bak 2020-09-11 15:44:45.770000000 +0900 -+++ gcc-8.3.0/libcpp/expr.c 2020-09-11 15:46:22.370000000 +0900 -@@ -794,10 +794,10 @@ - - if (CPP_OPTION (pfile, c99)) - cpp_warning_with_line (pfile, CPP_W_LONG_LONG, virtual_location, -- 0, message); -+ 0, "%s", message); - else - cpp_pedwarning_with_line (pfile, CPP_W_LONG_LONG, -- virtual_location, 0, message); -+ virtual_location, 0, "%s", message); - } - - result |= CPP_N_INTEGER; ---- gcc-8.3.0/libcpp/macro.c.bak 2020-09-11 16:01:42.550000000 +0900 -+++ gcc-8.3.0/libcpp/macro.c 2020-09-11 16:03:47.850000000 +0900 -@@ -160,7 +160,7 @@ - if (m_state == 2 && token->type == CPP_PASTE) - { - cpp_error_at (m_pfile, CPP_DL_ERROR, token->src_loc, -- vaopt_paste_error); -+ "%s", vaopt_paste_error); - return ERROR; - } - /* Advance states before further considering this token, in -@@ -189,7 +189,7 @@ - if (was_paste) - { - cpp_error_at (m_pfile, CPP_DL_ERROR, token->src_loc, -- vaopt_paste_error); -+ "%s", vaopt_paste_error); - return ERROR; - } - -@@ -3361,7 +3361,7 @@ - function-like macros, but not at the end. */ - if (following_paste_op) - { -- cpp_error (pfile, CPP_DL_ERROR, paste_op_error_msg); -+ cpp_error (pfile, CPP_DL_ERROR, "%s", paste_op_error_msg); - goto out; - } - if (!vaopt_tracker.completed ()) -@@ -3374,7 +3374,7 @@ - function-like macros, but not at the beginning. */ - if (macro->count == 1) - { -- cpp_error (pfile, CPP_DL_ERROR, paste_op_error_msg); -+ cpp_error (pfile, CPP_DL_ERROR, "%s", paste_op_error_msg); - goto out; - } - diff --git a/util/crossgcc/patches/gcc-11.2.0_libgcc.patch b/util/crossgcc/patches/gcc-11.2.0_libgcc.patch deleted file mode 100644 index 2f75c92..0000000 --- a/util/crossgcc/patches/gcc-11.2.0_libgcc.patch +++ /dev/null @@ -1,60 +0,0 @@ -This enables building on Mac OS and FreeBSD by adding support to their -variants of the sed utility. - -diff -urN gcc-5.2.0.orig/libgcc/config/t-hardfp gcc-5.2.0/libgcc/config/t-hardfp ---- gcc-5.2.0.orig/libgcc/config/t-hardfp 2015-01-05 04:33:28.000000000 -0800 -+++ gcc-8.1.0/libgcc/config/t-hardfp 2016-04-06 12:04:51.000000000 -0700 -@@ -59,21 +59,52 @@ - - hardfp_func_list := $(filter-out $(hardfp_exclusions),$(hardfp_func_list)) - -+HOST_OS ?= $(shell uname) -+ - # Regexp for matching a floating-point mode. -+ifeq ($(HOST_OS), Darwin) -+hardfp_mode_regexp := $(shell echo $(hardfp_float_modes) | sed 's/ /|/g') -+else -+ifeq ($(HOST_OS), FreeBSD) -+hardfp_mode_regexp := $(shell echo $(hardfp_float_modes) | sed 's/ /|/g') -+else - hardfp_mode_regexp := $(shell echo $(hardfp_float_modes) | sed 's/ /\|/g') -+endif -+endif - - # Regexp for matching the end of a function name, after the last - # floating-point mode. -+ifeq ($(HOST_OS), Darwin) -+hardfp_suffix_regexp := $(shell echo $(hardfp_int_modes) 2 3 | sed 's/ /|/g') -+else -+ifeq ($(HOST_OS), FreeBSD) -+hardfp_suffix_regexp := $(shell echo $(hardfp_int_modes) 2 3 | sed 's/ /|/g') -+else - hardfp_suffix_regexp := $(shell echo $(hardfp_int_modes) 2 3 | sed 's/ /\|/g') -+endif -+endif - - # Add -D options to define: - # FUNC: the function name (e.g. __addsf3) - # OP: the function name without the leading __ and with the last - # floating-point mode removed (e.g. add3) - # TYPE: the last floating-point mode (e.g. sf) -+ -+ifeq ($(HOST_OS), Darwin) - hardfp_defines_for = \ - $(shell echo $1 | \ -- sed 's/(.*)($(hardfp_mode_regexp))($(hardfp_suffix_regexp)|)$$/-DFUNC=__& -DOP_\1\3 -DTYPE=\2/') -+ sed -E 's/(.*)($(hardfp_mode_regexp))($(hardfp_suffix_regexp)|.*)$$/-DFUNC=__& -DOP_\1\3 -DTYPE=\2/') -+else -+ifeq ($(HOST_OS), FreeBSD) -+hardfp_defines_for = \ -+ $(shell echo $1 | \ -+ sed -r 's/(.*)($(hardfp_mode_regexp))($(hardfp_suffix_regexp)|.*)$$/-DFUNC=__& -DOP_\1\3 -DTYPE=\2/') -+else -+hardfp_defines_for = \ -+ $(shell echo $1 | \ -+ sed 's/(.*)($(hardfp_mode_regexp))($(hardfp_suffix_regexp)|)$$/-DFUNC=__& -DOP_\1\3 -DTYPE=\2/') -+endif -+endif - - hardfp-o = $(patsubst %,%$(objext),$(hardfp_func_list)) - $(hardfp-o): %$(objext): $(srcdir)/config/hardfp.c diff --git a/util/crossgcc/patches/gcc-11.2.0_asan_shadow_offset_callback.patch b/util/crossgcc/patches/gcc-11.3.0_asan_shadow_offset_callback.patch similarity index 100% rename from util/crossgcc/patches/gcc-11.2.0_asan_shadow_offset_callback.patch rename to util/crossgcc/patches/gcc-11.3.0_asan_shadow_offset_callback.patch diff --git a/util/crossgcc/sum/gcc-11.2.0.tar.xz.cksum b/util/crossgcc/sum/gcc-11.2.0.tar.xz.cksum deleted file mode 100644 index 071c352..0000000 --- a/util/crossgcc/sum/gcc-11.2.0.tar.xz.cksum +++ /dev/null @@ -1 +0,0 @@ -f902ccacecf8949978d6261e9f1d034cff73ffdb tarballs/gcc-11.2.0.tar.xz diff --git a/util/crossgcc/sum/gcc-11.3.0.tar.xz.cksum b/util/crossgcc/sum/gcc-11.3.0.tar.xz.cksum new file mode 100644 index 0000000..a4d2bd5 --- /dev/null +++ b/util/crossgcc/sum/gcc-11.3.0.tar.xz.cksum @@ -0,0 +1 @@ +cf86a48278f9a6f4b03d4390550577b20353b4e9 tarballs/gcc-11.3.0.tar.xz