package/gcc: add support for gcc 12

https://gcc.gnu.org/gcc-12/changes.html
https://gcc.gnu.org/gcc-12/porting_to.html

Tested with toolchain-builder:
https://gitlab.com/kubu93/toolchains-builder/-/pipelines/550404957

All three patches we had on gcc 11.x are upstream, so there are so far
no known patches needed for gcc 12.x. Here are the upstream commits of
the 3 patches:

https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=eff8110674ef193481d3657456a262beeb9951ff
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=da8a9d695b3c4b9397b5d9a27660bfa48af8d707
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=cac2f69cdad434ad5cb60f5fe931d45cd82ef476

Signed-off-by: Romain Naour <romain.naour@gmail.com>
Tested-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
Romain Naour 2022-05-29 15:18:08 +02:00 committed by Thomas Petazzoni
parent 4011ff535e
commit 0f1ad4fc93
2 changed files with 16 additions and 0 deletions

View File

@ -62,6 +62,19 @@ config BR2_GCC_VERSION_11_X
depends on !BR2_archs4x_rel31
select BR2_TOOLCHAIN_GCC_AT_LEAST_11
config BR2_GCC_VERSION_12_X
bool "gcc 12.x"
# powerpc spe support has been deprecated since gcc 8.x.
# https://gcc.gnu.org/ml/gcc/2018-04/msg00102.html
depends on !BR2_powerpc_SPE
# uClibc-ng broken on sparc due to recent gcc changes
# that need to be reverted since gcc 8.4, 9.3 and 10.1.
# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98784
depends on !BR2_sparc
# ARC HS48 rel 31 only supported by gcc arc fork.
depends on !BR2_archs4x_rel31
select BR2_TOOLCHAIN_GCC_AT_LEAST_12
endchoice
# libcilkrts was introduced in gcc 4.9 and removed in gcc 8.x
@ -88,6 +101,7 @@ config BR2_GCC_VERSION
default "9.4.0" if BR2_GCC_VERSION_9_X
default "10.3.0" if BR2_GCC_VERSION_10_X
default "11.3.0" if BR2_GCC_VERSION_11_X
default "12.1.0" if BR2_GCC_VERSION_12_X
default "arc-2020.09-release" if BR2_GCC_VERSION_ARC
config BR2_EXTRA_GCC_CONFIG_OPTIONS

View File

@ -6,6 +6,8 @@ sha512 dfd3500bf21784b8351a522d53463cf362ede66b0bc302edf350bb44e94418497a8b4b79
sha512 2b2dd7453d48a398c29eaebd1422b70341001b8c90a62aee51e83344e7fdd8a8e45f82a4a9165bd7edc76dada912c932f4b6632c5636760fec4c5d7e402b3f86 gcc-10.3.0.tar.xz
# From https://gcc.gnu.org/pub/gcc/releases/gcc-11.3.0/sha512.sum
sha512 f0be5ad705c73b84477128a69c047f57dd47002f375eb60e1e842e08cf2009a509e92152bca345823926d550b7395ae6d4de7db51d1ee371c2dc37313881fca7 gcc-11.3.0.tar.xz
# From https://gcc.gnu.org/pub/gcc/releases/gcc-12.1.0/sha512.sum
sha512 2121d295292814a6761edf1fba08c5f633ebe16f52b80e7b73a91050e71e1d2ed98bf17eebad263e191879561c02b48906c53faa4c4670c486a26fc75df23900 gcc-12.1.0.tar.xz
# Locally calculated (fetched from Github)
sha512 b0853e2b1c5998044392023fa653e399e74118c46e616504ac59e1a2cf27620f94434767ce06b6cf4ca3dfb57f81d6eda92752befaf095ea5e564a9181b4659c gcc-arc-2020.09-release.tar.gz