diff --git a/0_RootFS/GCCBootstrap@12-IainS/bundled/patches/libtapi/libtapi-llvm-missing-include.patch b/0_RootFS/GCCBootstrap@12-IainS/bundled/patches/libtapi/libtapi-llvm-missing-include.patch index 373af741b2a..c807b6bcddb 100644 --- a/0_RootFS/GCCBootstrap@12-IainS/bundled/patches/libtapi/libtapi-llvm-missing-include.patch +++ b/0_RootFS/GCCBootstrap@12-IainS/bundled/patches/libtapi/libtapi-llvm-missing-include.patch @@ -4,13 +4,13 @@ Date: Tue, 10 Nov 2020 14:55:25 +0100 Subject: [PATCH] [nfc] Fix missing include --- - llvm/utils/benchmark/src/benchmark_register.h | 1 + + src/llvm/utils/benchmark/src/benchmark_register.h | 1 + 1 file changed, 1 insertion(+) -diff --git a/llvm/utils/benchmark/src/benchmark_register.h b/llvm/utils/benchmark/src/benchmark_register.h +diff --git a/src/llvm/utils/benchmark/src/benchmark_register.h b/src/llvm/utils/benchmark/src/benchmark_register.h index 0705e219f2fa2..4caa5ad4da079 100644 ---- a/llvm/utils/benchmark/src/benchmark_register.h -+++ b/llvm/utils/benchmark/src/benchmark_register.h +--- a/src/llvm/utils/benchmark/src/benchmark_register.h ++++ b/src/llvm/utils/benchmark/src/benchmark_register.h @@ -1,6 +1,7 @@ #ifndef BENCHMARK_REGISTER_H #define BENCHMARK_REGISTER_H diff --git a/0_RootFS/GCCBootstrap@14/build_tarballs.jl b/0_RootFS/GCCBootstrap@14/build_tarballs.jl new file mode 100644 index 00000000000..920afb87a70 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/build_tarballs.jl @@ -0,0 +1,2 @@ +include("../gcc_common.jl") +build_and_upload_gcc(v"14.2.0") diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_deterministic_dlltool.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_deterministic_dlltool.patch new file mode 120000 index 00000000000..aceafcc0975 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_deterministic_dlltool.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/binutils_deterministic_dlltool.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_freebsd_symbol_versioning.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_freebsd_symbol_versioning.patch new file mode 120000 index 00000000000..def50f526dd --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/binutils_freebsd_symbol_versioning.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/binutils_freebsd_symbol_versioning.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210-libcc1-musl-poisoned-calloc.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210-libcc1-musl-poisoned-calloc.patch new file mode 120000 index 00000000000..2068df652b0 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210-libcc1-musl-poisoned-calloc.patch @@ -0,0 +1 @@ +../../../../GCCBootstrap@12/bundled/patches/gcc/gcc1210-libcc1-musl-poisoned-calloc.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210_mingw_include.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210_mingw_include.patch new file mode 120000 index 00000000000..1ae616e9809 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1210_mingw_include.patch @@ -0,0 +1 @@ +../../../../GCCBootstrap@12/bundled/patches/gcc/gcc1210_mingw_include.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1420-Increase-fallback-min-macOS-version-for-libgcc-to-10.8.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1420-Increase-fallback-min-macOS-version-for-libgcc-to-10.8.patch new file mode 100644 index 00000000000..dc44d88b7d2 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc/gcc1420-Increase-fallback-min-macOS-version-for-libgcc-to-10.8.patch @@ -0,0 +1,39 @@ +From eb521cd67a69fdb0497feee5235e0f355a18d3c1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Mos=C3=A8=20Giordano?= +Date: Sat, 4 Jan 2025 01:48:23 +0100 +Subject: [PATCH] Increase fallback min macOS version for libgcc to 10.8 + +`-mmacosx-version-min=10.5` seems to cause problems with ld64 from cctools +(https://github.com/JuliaPackaging/Yggdrasil/pull/10132#issuecomment-2569925646), +and in any case in Julia/BinaryBuilder we support macOS 10.12 at minimum. +--- + libgcc/config.host | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/libgcc/config.host b/libgcc/config.host +index e75a7af64..12aa05581 100644 +--- a/libgcc/config.host ++++ b/libgcc/config.host +@@ -240,7 +240,7 @@ case ${host} in + tmake_file="t-darwin-min-8 $tmake_file" + ;; + *-*-darwin9* | *-*-darwin1[0-7]*) +- tmake_file="t-darwin-min-5 $tmake_file" ++ tmake_file="t-darwin-min-8 $tmake_file" + ;; + *-*-darwin[4-8]*) + tmake_file="t-darwin-min-1 $tmake_file" +@@ -248,8 +248,8 @@ case ${host} in + *) + # Fall back to configuring for the oldest system known to work with + # all archs and the current sources. +- tmake_file="t-darwin-min-5 $tmake_file" +- echo "Warning: libgcc configured to support macOS 10.5" 1>&2 ++ tmake_file="t-darwin-min-8 $tmake_file" ++ echo "Warning: libgcc configured to support macOS 10.8" 1>&2 + ;; + esac + # We are not using libtool to build the libs here, so we need to replicate +-- +2.31.0 + diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc1020_revert-generic-morestack_c.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc1020_revert-generic-morestack_c.patch new file mode 120000 index 00000000000..9f71b06cf78 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc1020_revert-generic-morestack_c.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@10/bundled/patches/gcc1020_revert-generic-morestack_c.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc485_triplet_prefixed_cxx_headers.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc485_triplet_prefixed_cxx_headers.patch new file mode 120000 index 00000000000..d369ff00200 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc485_triplet_prefixed_cxx_headers.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/gcc485_triplet_prefixed_cxx_headers.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc520-libgomp-Don-t-hard-code-MS-printf-attributes.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc520-libgomp-Don-t-hard-code-MS-printf-attributes.patch new file mode 120000 index 00000000000..5cbe226cf7f --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc520-libgomp-Don-t-hard-code-MS-printf-attributes.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@5/bundled/patches/gcc520-libgomp-Don-t-hard-code-MS-printf-attributes.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/gcc9_vsnprintf-str.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc9_vsnprintf-str.patch new file mode 120000 index 00000000000..2402f499b6c --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/gcc9_vsnprintf-str.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@9/bundled/patches/gcc9_vsnprintf-str.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-01.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-01.patch new file mode 120000 index 00000000000..c750d5a8835 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-01.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-01.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-02.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-02.patch new file mode 120000 index 00000000000..c2f8ca9cddb --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-02.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-02.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-03.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-03.patch new file mode 120000 index 00000000000..7f9b18ab810 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-03.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-03.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-04.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-04.patch new file mode 120000 index 00000000000..82f535d0ef6 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-04.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-04.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-05.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-05.patch new file mode 120000 index 00000000000..629c1a71ca7 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-05.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-05.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-06.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-06.patch new file mode 120000 index 00000000000..4682d7d2638 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-06.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-06.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-07.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-07.patch new file mode 120000 index 00000000000..ec0ff4fc245 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-07.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-07.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-08.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-08.patch new file mode 120000 index 00000000000..dd3d8002d07 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-08.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-08.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-09.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-09.patch new file mode 120000 index 00000000000..6160e1ff6c9 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-09.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-09.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-10.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-10.patch new file mode 120000 index 00000000000..3b0eb446435 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-10.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-10.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-11.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-11.patch new file mode 120000 index 00000000000..1a8b2b1874a --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-11.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-11.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-12.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-12.patch new file mode 120000 index 00000000000..5c61ae4d308 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-12.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-12.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-13.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-13.patch new file mode 120000 index 00000000000..9fcd14da248 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-13.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-13.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-14.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-14.patch new file mode 120000 index 00000000000..2c105860a79 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-14.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-14.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-15.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-15.patch new file mode 120000 index 00000000000..553e804d24c --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-15.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-15.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-16.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-16.patch new file mode 120000 index 00000000000..45b396e6e16 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-16.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-16.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-17.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-17.patch new file mode 120000 index 00000000000..381198312d8 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-17.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-17.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-18.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-18.patch new file mode 120000 index 00000000000..75da139edca --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-18.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-18.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-19.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-19.patch new file mode 120000 index 00000000000..15b94428f84 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-19.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-19.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-20.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-20.patch new file mode 120000 index 00000000000..363da6ff21d --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-20.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-20.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-21.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-21.patch new file mode 120000 index 00000000000..d0b5d34df23 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-21.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-21.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-22.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-22.patch new file mode 120000 index 00000000000..e33401a61ec --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-22.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-22.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-23.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-23.patch new file mode 120000 index 00000000000..e17c24162a4 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-23.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-23.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-24.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-24.patch new file mode 120000 index 00000000000..dabf39e7b9c --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-24.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-24.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-25.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-25.patch new file mode 120000 index 00000000000..a1013682f68 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-25.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-25.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-26.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-26.patch new file mode 120000 index 00000000000..9d6541b9b82 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-26.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-26.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-27.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-27.patch new file mode 120000 index 00000000000..b4b0172a637 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-27.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-27.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-28.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-28.patch new file mode 120000 index 00000000000..422f6eab38f --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-28.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-28.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-29.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-29.patch new file mode 120000 index 00000000000..29c53da8ea3 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-29.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-29.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-30.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-30.patch new file mode 120000 index 00000000000..6d532a56d8d --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-30.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-30.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-31.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-31.patch new file mode 120000 index 00000000000..9b06be66e43 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-31.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-31.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-32.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-32.patch new file mode 120000 index 00000000000..ed3e7f02517 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-32.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-32.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-33.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-33.patch new file mode 120000 index 00000000000..468c085f789 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-33.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-33.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-34.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-34.patch new file mode 120000 index 00000000000..58778f0e720 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-34.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-34.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-35.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-35.patch new file mode 120000 index 00000000000..07ea002e01f --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-35.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-35.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-36.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-36.patch new file mode 120000 index 00000000000..3bc5b0034c8 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-36.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-36.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-37.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-37.patch new file mode 120000 index 00000000000..84f35423e52 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-37.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-37.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-38.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-38.patch new file mode 120000 index 00000000000..dc2041a6dfe --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-38.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-38.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-39.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-39.patch new file mode 120000 index 00000000000..edcdb4e0660 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-39.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-39.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-40.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-40.patch new file mode 120000 index 00000000000..d6664bac3ae --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-40.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-40.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-41.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-41.patch new file mode 120000 index 00000000000..024e01a1d93 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-41.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-41.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-42.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-42.patch new file mode 120000 index 00000000000..cc626e8bd3e --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-42.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-42.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-43.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-43.patch new file mode 120000 index 00000000000..78508bdced4 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-43.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-43.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-44.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-44.patch new file mode 120000 index 00000000000..abc87cc7705 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-44.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-44.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-45.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-45.patch new file mode 120000 index 00000000000..546a75ecf8b --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-45.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-45.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-46.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-46.patch new file mode 120000 index 00000000000..651cb9e3cca --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-46.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-46.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-47-pwr6-mtfsf.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-47-pwr6-mtfsf.patch new file mode 120000 index 00000000000..8c086355317 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-47-pwr6-mtfsf.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-47-pwr6-mtfsf.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-48-ldbl_high.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-48-ldbl_high.patch new file mode 120000 index 00000000000..d6f0ec0b0f2 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-48-ldbl_high.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc-ppc64le-48-ldbl_high.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-49-gcc10-cache_line_size-common.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-49-gcc10-cache_line_size-common.patch new file mode 120000 index 00000000000..6f94a199200 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-ppc64le-49-gcc10-cache_line_size-common.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@10/bundled/patches/glibc-ppc64le-49-gcc10-cache_line_size-common.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-remove-__ASSUME_AT_RANDOM-in-_dl_setup_stack_chk_guard.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-remove-__ASSUME_AT_RANDOM-in-_dl_setup_stack_chk_guard.patch new file mode 120000 index 00000000000..077aabacc5d --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc-remove-__ASSUME_AT_RANDOM-in-_dl_setup_stack_chk_guard.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@12/bundled/patches/glibc-remove-__ASSUME_AT_RANDOM-in-_dl_setup_stack_chk_guard.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc217_gcc_version.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc217_gcc_version.patch new file mode 120000 index 00000000000..c997e5ac6bd --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc217_gcc_version.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@10/bundled/patches/glibc217_gcc_version.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc219_gcc_version.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc219_gcc_version.patch new file mode 120000 index 00000000000..6c39b3a87f4 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc219_gcc_version.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@10/bundled/patches/glibc219_gcc_version.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_aarch64_relocation.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_aarch64_relocation.patch new file mode 120000 index 00000000000..23af0beaecb --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_aarch64_relocation.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_aarch64_relocation.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_arm_gcc_fix.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_arm_gcc_fix.patch new file mode 120000 index 00000000000..13167359553 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_arm_gcc_fix.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_arm_gcc_fix.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_gcc_version.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_gcc_version.patch new file mode 120000 index 00000000000..473f7a525d9 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_gcc_version.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_gcc_version.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_i686_asm.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_i686_asm.patch new file mode 120000 index 00000000000..35f065f0d0d --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_i686_asm.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_i686_asm.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_make_version.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_make_version.patch new file mode 120000 index 00000000000..1c6b268bfab --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_make_version.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_make_version.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_movq_fix.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_movq_fix.patch new file mode 120000 index 00000000000..82589175587 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_movq_fix.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@12/bundled/patches/glibc_movq_fix.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_musl_rejection.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_musl_rejection.patch new file mode 100644 index 00000000000..6d85ff271ed --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_musl_rejection.patch @@ -0,0 +1,184 @@ +From 6edeea11b1f8fb5df9e421834da6f2d5c2bec21c Mon Sep 17 00:00:00 2001 +From: Keno Fischer +Date: Sat, 11 Jan 2025 19:06:34 +0000 +Subject: [PATCH] dl-load: Reject musl-linked libraries + +This prevents the glibc dynamic linker from considering shared +libraries linked against musl (similar to how it would reject +libraries for other architectures). + +See https://github.com/JuliaPackaging/BinaryBuilder.jl/issues/297 +--- + elf/dl-load.c | 80 ++++++++++++++++++++++- + elf/ldconfig.c | 10 +++ + sysdeps/generic/ldconfig.h | 1 + + sysdeps/unix/sysv/linux/x86_64/ldconfig.h | 3 +- + 4 files changed, 92 insertions(+), 2 deletions(-) + +diff --git a/elf/dl-load.c b/elf/dl-load.c +index 70fe78f3e7..aadc810a45 100644 +--- a/elf/dl-load.c ++++ b/elf/dl-load.c +@@ -72,6 +72,7 @@ + # define MAP_BASE_ADDR(l) 0 + #endif + ++#include + + #include + #if BYTE_ORDER == BIG_ENDIAN +@@ -1649,6 +1650,60 @@ print_search_path (struct r_search_path_elem **list, + else + _dl_debug_printf_c ("\t\t(%s)\n", what); + } ++ ++struct known_names ++{ ++ const char *soname; ++ int flag; ++}; ++ ++static struct known_names known_libs[] = ++{ ++#ifdef SYSDEP_KNOWN_LIBRARY_NAMES ++ SYSDEP_KNOWN_LIBRARY_NAMES ++#endif ++}; ++ ++static int validate_lib(int fd, unsigned int dynamic_addr, unsigned int dynamic_size) ++{ ++ ElfW(Dyn) *dyn_entry; ++ ElfW(Dyn) *dynamic_segment = alloca(dynamic_size); ++ char fname[255]; ++ __lseek (fd, dynamic_addr, SEEK_SET); ++ if ((size_t) __libc_read (fd, (void *) dynamic_segment, dynamic_size) != dynamic_size) ++ { ++ return -2; ++ } ++ // Find the string table ++ unsigned int string_offset = 0; ++ for (dyn_entry = dynamic_segment; dyn_entry->d_tag != DT_NULL; ++dyn_entry) ++ { ++ if (dyn_entry->d_tag == DT_STRTAB) { ++ string_offset = dyn_entry->d_un.d_val; ++ } ++ if (string_offset != 0) { ++ for (dyn_entry = dynamic_segment; dyn_entry->d_tag != DT_NULL; ++dyn_entry) ++ { ++ if (dyn_entry->d_tag == DT_NEEDED) { ++ __lseek (fd, string_offset + dyn_entry->d_un.d_val, SEEK_SET); ++ ssize_t nchars = __libc_read (fd, (void *)fname, 254); ++ if (nchars == -1) ++ return -2; ++ fname[nchars] = 0; ++ for (int j = 0; j < sizeof (known_libs) / sizeof (known_libs [0]); ++j) { ++ if (strcmp (fname, known_libs [j].soname) == 0) ++ { ++ if (known_libs [j].flag == FLAG_ELF_MUSL) ++ return 1; ++ } ++ } ++ } ++ } ++ } ++ } ++ return 0; ++} ++ + + /* Open a file and verify it is an ELF file for this architecture. We + ignore only ELF files for other architectures. Non-ELF files and +@@ -1690,6 +1745,8 @@ open_verify (const char *name, struct filebuf *fbp, struct link_map *loader, + } expected_note = { 4, 16, 1, "GNU" }; + /* Initialize it to make the compiler happy. */ + const char *errstring = NULL; ++ unsigned int dynamic_addr = 0; ++ unsigned int dynamic_size = 0; + int errval = 0; + + #ifdef SHARED +@@ -1856,8 +1913,15 @@ open_verify (const char *name, struct filebuf *fbp, struct link_map *loader, + } + } + ++ dynamic_addr = 0; ++ dynamic_size = 0; + /* Check .note.ABI-tag if present. */ +- for (ph = phdr; ph < &phdr[ehdr->e_phnum]; ++ph) ++ for (ph = phdr; ph < &phdr[ehdr->e_phnum]; ++ph) { ++ if (ph->p_type == PT_DYNAMIC) ++ { ++ dynamic_addr = ph->p_offset; ++ dynamic_size = ph->p_filesz; ++ } + if (ph->p_type == PT_NOTE && ph->p_filesz >= 32 && ph->p_align >= 4) + { + ElfW(Addr) size = ph->p_filesz; +@@ -1905,6 +1969,20 @@ open_verify (const char *name, struct filebuf *fbp, struct link_map *loader, + + break; + } ++ } ++ /* Check the dynamic section */ ++ if (dynamic_addr != 0) { ++ int err = validate_lib(fd, dynamic_addr, dynamic_size); ++ if (err == -2) { ++ errstring = N_("failed to read file"); ++ goto call_lose; ++ } ++ else if (err != 0) { ++ __close (fd); ++ __set_errno (ENOENT); ++ fd = -1; ++ } ++ } + } + + return fd; +diff --git a/elf/ldconfig.c b/elf/ldconfig.c +index 453cd6278d..03bd57da92 100644 +--- a/elf/ldconfig.c ++++ b/elf/ldconfig.c +@@ -882,6 +882,16 @@ search_dir (const struct dir_entry *entry) + add_to_aux_cache (&lstat_buf, flag, osversion, soname); + } + ++ /* Don't try to load MUSL-dependent libraries */ ++ if ((flag & FLAG_TYPE_MASK) == FLAG_ELF_MUSL) ++ { ++ if (real_name != real_file_name) ++ free (real_name); ++ if (opt_verbose) ++ error (0, 0, _("Skipping musl-linked library %s"), file_name); ++ continue; ++ } ++ + if (soname == NULL) + soname = implicit_soname (direntry->d_name, flag); + +diff --git a/sysdeps/generic/ldconfig.h b/sysdeps/generic/ldconfig.h +index 43cb9bdb0c..83d3572c34 100644 +--- a/sysdeps/generic/ldconfig.h ++++ b/sysdeps/generic/ldconfig.h +@@ -25,6 +25,7 @@ + #define FLAG_ELF 0x0001 + #define FLAG_ELF_LIBC5 0x0002 + #define FLAG_ELF_LIBC6 0x0003 ++#define FLAG_ELF_MUSL 0x0004 + #define FLAG_REQUIRED_MASK 0xff00 + #define FLAG_SPARC_LIB64 0x0100 + #define FLAG_IA64_LIB64 0x0200 +diff --git a/sysdeps/unix/sysv/linux/x86_64/ldconfig.h b/sysdeps/unix/sysv/linux/x86_64/ldconfig.h +index 6f5b828f44..3bac734e22 100644 +--- a/sysdeps/unix/sysv/linux/x86_64/ldconfig.h ++++ b/sysdeps/unix/sysv/linux/x86_64/ldconfig.h +@@ -23,4 +23,5 @@ + { "/lib64/ld-linux-x86-64.so.2", FLAG_ELF_LIBC6 }, + #define SYSDEP_KNOWN_LIBRARY_NAMES \ + { "libc.so.6", FLAG_ELF_LIBC6 }, \ +- { "libm.so.6", FLAG_ELF_LIBC6 }, ++ { "libm.so.6", FLAG_ELF_LIBC6 }, \ ++ { "libc.musl-x86_64.so.1", FLAG_ELF_MUSL } +-- +2.31.0 + diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_nocommon.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_nocommon.patch new file mode 120000 index 00000000000..5b375100acb --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_nocommon.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_nocommon.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_powerpc64le_gcc_fix.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_powerpc64le_gcc_fix.patch new file mode 120000 index 00000000000..206ed74aa45 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_powerpc64le_gcc_fix.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_powerpc64le_gcc_fix.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_regexp_nocommon.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_regexp_nocommon.patch new file mode 120000 index 00000000000..1a10ef2694b --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_regexp_nocommon.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_regexp_nocommon.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_sunrpc.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_sunrpc.patch new file mode 120000 index 00000000000..9359558d4e0 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/glibc_sunrpc.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/glibc_sunrpc.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_fullyaml.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_fullyaml.patch new file mode 120000 index 00000000000..8c24845b566 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_fullyaml.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/libtapi_fullyaml.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_musl.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_musl.patch new file mode 120000 index 00000000000..435ae951cdc --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/libtapi_musl.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/libtapi_musl.patch \ No newline at end of file diff --git a/0_RootFS/GCCBootstrap@14/bundled/patches/mingw_gcc710_i686.patch b/0_RootFS/GCCBootstrap@14/bundled/patches/mingw_gcc710_i686.patch new file mode 120000 index 00000000000..94de400d805 --- /dev/null +++ b/0_RootFS/GCCBootstrap@14/bundled/patches/mingw_gcc710_i686.patch @@ -0,0 +1 @@ +../../../GCCBootstrap@4/bundled/patches/mingw_gcc710_i686.patch \ No newline at end of file diff --git a/0_RootFS/gcc_common.jl b/0_RootFS/gcc_common.jl index 84181ceec2f..413b2701d4b 100644 --- a/0_RootFS/gcc_common.jl +++ b/0_RootFS/gcc_common.jl @@ -16,6 +16,11 @@ # # ORIGDIR=../../../GCCBootstrap@XYZ/bundled/patches; for p in ${ORIGDIR}/{,*/}*.patch; do DESTDIR=$(dirname ${p#"${ORIGDIR}/"}); mkdir -p "${DESTDIR}"; if [[ -L "${p}" ]]; then cp -a "${p}" "${DESTDIR}"; else ln -s $(realpath --relative-to="${DESTDIR}" "${p}") "${DESTDIR}"; fi; done # +# * adapt the recipe as necessary, but try to make changes in a backward +# compatible way. If you introduce steps that are necessary only with +# specific versions of GCC, guard them with appropriate conditionals. We may +# need to use the same recipe to rebuild older versions of GCC at a later +# point and being able to rerun it as-is is extremely important # * you can build only one platform at the time. To deploy the compiler shards # and automatically update your BinaryBuilderBase's `Artifacts.toml`, use the # `--deploy` flag to the `build_tarballs.jl` script. You can either build & @@ -32,8 +37,14 @@ using BinaryBuilder: BinaryBuilderBase @eval BinaryBuilder.BinaryBuilderBase push!(bootstrap_list, :rootfs, :platform_support) -function gcc_script(compiler_target::Platform) - script = raw""" +function gcc_script(gcc_version::VersionNumber, compiler_target::Platform) + script = """ + GCC_VERSION_MAJOR=$(gcc_version.major) + GCC_VERSION_MINOR=$(gcc_version.minor) + GCC_VERSION_PATCH=$(gcc_version.patch) + """ + + script *= raw""" cd ${WORKSPACE}/srcdir COMPILER_TARGET=${target} HOST_TARGET=${MACHTYPE} @@ -59,19 +70,11 @@ function gcc_script(compiler_target::Platform) sysroot="${prefix}/${COMPILER_TARGET}/sys-root" cp -ra "/opt/${COMPILER_TARGET}/${COMPILER_TARGET}" "${prefix}/${COMPILER_TARGET}" - # Some things need /lib64, others just need /lib - case ${COMPILER_TARGET} in - x86_64*) - LIB64=lib64 - ;; - aarch64*) - LIB64=lib64 - ;; - ppc64*) - LIB64=lib64 - ;; - risc64*) - # TODO: Is this correct? + # Some things need /lib64, others just need /lib. Be consistent with where + # our compiler wrappers expect the libraries to be: + # . + case ${nbits} in + 64) LIB64=lib64 ;; *) @@ -191,32 +194,53 @@ function gcc_script(compiler_target::Platform) # Apply libtapi patches, if any if [[ -d "${WORKSPACE}/srcdir/patches/libtapi" ]]; then for p in ${WORKSPACE}/srcdir/patches/libtapi/*.patch; do - atomic_patch -p1 -d src/ "${p}" + atomic_patch -p1 "${p}" done fi + # Install libtapi mkdir -p ${WORKSPACE}/srcdir/apple-libtapi/build cd ${WORKSPACE}/srcdir/apple-libtapi/build - export TAPIDIR=${WORKSPACE}/srcdir/apple-libtapi - # Install libtapi + TAPI_CMAKE_FLAGS=() + if [[ "${GCC_VERSION_MAJOR}" -ge 14 ]]; then + TAPI_CMAKE_FLAGS+=( + -DLLVM_ENABLE_PROJECTS="tapi;clang" + -DLLVM_TARGETS_TO_BUILD:STRING="host" + ) + fi + cmake ../src/llvm \ + -DCMAKE_C_COMPILER_LAUNCHER=ccache \ + -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ -DCMAKE_CXX_FLAGS="-I${TAPIDIR}/src/llvm/projects/clang/include -I${TAPIDIR}/build/projects/clang/include" \ -DLLVM_INCLUDE_TESTS=OFF \ -DCMAKE_BUILD_TYPE=RELEASE \ - -DCMAKE_INSTALL_PREFIX=${prefix} + -DCMAKE_INSTALL_PREFIX=${prefix} \ + "${TAPI_CMAKE_FLAGS[@]}" make -j${nproc} VERBOSE=1 clangBasic - make -j${nproc} VERBOSE=1 - make install + make -j${nproc} VERBOSE=1 libtapi + make -j${nproc} VERBOSE=1 install # Install cctools + cd ${WORKSPACE}/srcdir/cctools-port/cctools + ./autogen.sh mkdir -p ${WORKSPACE}/srcdir/cctools_build cd ${WORKSPACE}/srcdir/cctools_build - CC=/usr/bin/clang CXX=/usr/bin/clang++ LDFLAGS=-L/usr/lib ${WORKSPACE}/srcdir/cctools-port/cctools/configure \ + + # TODO: Update RootFS to v3.17 or later, and preinstall libdispatch (and libdispatch-dev here only when building for macOS). + if [[ "${GCC_VERSION_MAJOR}" -ge 14 ]]; then + apk add libdispatch libdispatch-dev --repository=http://dl-cdn.alpinelinux.org/alpine/v3.17/community + fi + + ${WORKSPACE}/srcdir/cctools-port/cctools/configure \ --prefix=${prefix} \ --target=${COMPILER_TARGET} \ --host=${MACHTYPE} \ + CC=/usr/bin/clang \ + CXX=/usr/bin/clang++ \ + LDFLAGS=-L/usr/lib \ --with-libtapi=${prefix} make -j${nproc} make install @@ -357,10 +381,19 @@ function gcc_script(compiler_target::Platform) GLIBC_CONFIGURE_OVERRIDES+=( libc_cv_ssp=no libc_cv_ssp_strong=no ) fi - if [[ ${COMPILER_TARGET} == riscv64-* ]]; then - # Explicitly disable C++ - # (Disable for all architectures?) - GLIBC_CONFIGURE_OVERRIDES+=( CXX=false ) + # Explicitly disable C++. + # If we don't do this, glibc will pick up the host C++ + # compiler (/usr/bin/g++) to build some C++ files. With this + # setting, glibc will build C versions of these files instead. + GLIBC_CONFIGURE_OVERRIDES+=( CXX=false ) + + # These flags are necessary for GCC 14. GCC 14 defaults to a + # modern version of C, too modern for the old glibc libraries we are + # trying to build. Various configure tests would fail otherwise. (Why + # declare variables or functions if they default to int anyway?) + GLIBC_CFLAGS="${CFLAGS} -g -O2" + if [[ "${GCC_VERSION_MAJOR}" -ge 14 ]]; then + GLIBC_CFLAGS="${GLIBC_CFLAGS} -Wno-implicit-int -Wno-implicit-function-declaration -Wno-builtin-declaration-mismatch -Wno-array-parameter -Wno-int-conversion" fi # Configure glibc @@ -373,6 +406,7 @@ function gcc_script(compiler_target::Platform) --with-headers="${sysroot}/usr/include" \ --disable-multilib \ --disable-werror \ + CFLAGS="${GLIBC_CFLAGS}" \ ${GLIBC_CONFIGURE_OVERRIDES[@]} @@ -386,7 +420,7 @@ function gcc_script(compiler_target::Platform) # Install CSU make csu/subdir_lib -j${nproc} mkdir -p ${sysroot}/usr/${LIB64} - install csu/crt1.o csu/crti.o csu/crtn.o ${sysroot}/usr/${LIB64} + install -v csu/crt1.o csu/crti.o csu/crtn.o ${sysroot}/usr/${LIB64} ${COMPILER_TARGET}-gcc -nostdlib -nostartfiles -shared -x c /dev/null -o ${sysroot}/usr/${LIB64}/libc.so elif [[ ${COMPILER_TARGET} == *-musl* ]]; then @@ -410,7 +444,7 @@ function gcc_script(compiler_target::Platform) # Make CRT make lib/{crt1,crti,crtn}.o mkdir -p ${sysroot}/usr/lib - install lib/crt1.o lib/crti.o lib/crtn.o ${sysroot}/usr/lib + install -v lib/crt1.o lib/crti.o lib/crtn.o ${sysroot}/usr/lib ${COMPILER_TARGET}-gcc -nostdlib -nostartfiles -shared -x c /dev/null -o ${sysroot}/usr/lib/libc.so elif [[ ${COMPILER_TARGET} == *-mingw* ]]; then @@ -597,6 +631,12 @@ function gcc_script(compiler_target::Platform) # Remove heavy doc directories rm -rf ${sysroot}/usr/share/man + + # Remove leftover dummy `libc.so` file: + # . + if [[ "${target}" == riscv64-linux-gnu ]]; then + rm -v ${sysroot}/usr/${LIB64}/libc.so + fi """ return script @@ -624,7 +664,7 @@ function build_and_upload_gcc(version::VersionNumber, ARGS=ARGS) deleteat!(ARGS, length(ARGS)) sources = gcc_sources(version, compiler_target) - script = gcc_script(compiler_target) + script = gcc_script(version, compiler_target) products = gcc_products() # Build the tarballs, and possibly a `build.jl` as well. diff --git a/0_RootFS/gcc_sources.jl b/0_RootFS/gcc_sources.jl index 536f13563cf..7506571566c 100644 --- a/0_RootFS/gcc_sources.jl +++ b/0_RootFS/gcc_sources.jl @@ -106,7 +106,6 @@ const gcc_version_sources = Dict{VersionNumber,Vector}( "fcf78dd9656c10eb8cf9fbd5f59a0b6b01386205fe1934b3b287a0a1898145c0"), ], v"13.2.0" => [ - ArchiveSource("https://mirrors.kernel.org/gnu/gcc/gcc-13.2.0/gcc-13.2.0.tar.xz", "e275e76442a6067341a27f04c5c6b83d8613144004c0413528863dc6b5c743da"), ArchiveSource("https://mirrors.kernel.org/gnu/gmp/gmp-6.2.1.tar.xz", @@ -118,6 +117,18 @@ const gcc_version_sources = Dict{VersionNumber,Vector}( ArchiveSource("https://gcc.gnu.org/pub/gcc/infrastructure/isl-0.24.tar.bz2", "fcf78dd9656c10eb8cf9fbd5f59a0b6b01386205fe1934b3b287a0a1898145c0"), ], + v"14.2.0" => [ + ArchiveSource("https://mirrors.kernel.org/gnu/gcc/gcc-14.2.0/gcc-14.2.0.tar.xz", + "a7b39bc69cbf9e25826c5a60ab26477001f7c08d85cec04bc0e29cabed6f3cc9"), + ArchiveSource("https://mirrors.kernel.org/gnu/gmp/gmp-6.2.1.tar.xz", + "fd4829912cddd12f84181c3451cc752be224643e87fac497b69edddadc49b4f2"), + ArchiveSource("https://mirrors.kernel.org/gnu/mpfr/mpfr-4.1.0.tar.xz", + "0c98a3f1732ff6ca4ea690552079da9c597872d30e96ec28414ee23c95558a7f"), + ArchiveSource("https://mirrors.kernel.org/gnu/mpc/mpc-1.2.1.tar.gz", + "17503d2c395dfcf106b622dc142683c1199431d095367c6aacba6eec30340459"), + ArchiveSource("https://gcc.gnu.org/pub/gcc/infrastructure/isl-0.24.tar.bz2", + "fcf78dd9656c10eb8cf9fbd5f59a0b6b01386205fe1934b3b287a0a1898145c0"), + ], ) function gcc_sources(gcc_version::VersionNumber, compiler_target::Platform; kwargs...) @@ -156,12 +167,21 @@ function gcc_sources(gcc_version::VersionNumber, compiler_target::Platform; kwar "258e6cd51b3fbdfc185c716d55f82c08aff57df0c6fbd143cf6ed561267a1526"), ] # MacOS doesn't actually use binutils, it uses cctools - binutils_sources = [ - GitSource("https://github.com/tpoechtrager/apple-libtapi.git", - "a66284251b46d591ee4a0cb4cf561b92a0c138d8"), - GitSource("https://github.com/tpoechtrager/cctools-port.git", - "634a084377ee2e2932c66459b0396edf76da2e9f"), - ] + if gcc_version < v"14" + binutils_sources = [ + GitSource("https://github.com/tpoechtrager/apple-libtapi.git", + "a66284251b46d591ee4a0cb4cf561b92a0c138d8"), + GitSource("https://github.com/tpoechtrager/cctools-port.git", + "634a084377ee2e2932c66459b0396edf76da2e9f"), + ] + else + binutils_sources = [ + GitSource("https://github.com/tpoechtrager/apple-libtapi.git", + "54c9044082ba35bdb2b0edf282ba1a340096154c"), + GitSource("https://github.com/tpoechtrager/cctools-port.git", + "81f205e8ca6bbf2fdbcb6948132454fd1f97839e"), + ] + end else # Different versions of GCC should be paired with different versions of Binutils binutils_gcc_version_mapping = Dict( @@ -175,6 +195,7 @@ function gcc_sources(gcc_version::VersionNumber, compiler_target::Platform; kwar v"11.1.0" => v"2.36", v"12.1.0" => v"2.38", v"13.2.0" => v"2.41", + v"14.2.0" => v"2.43.1", ) # Everyone else uses GNU Binutils, but we have to version carefully. @@ -223,6 +244,10 @@ function gcc_sources(gcc_version::VersionNumber, compiler_target::Platform; kwar ArchiveSource("https://ftp.gnu.org/gnu/binutils/binutils-2.41.tar.xz", "ae9a5789e23459e59606e6714723f2d3ffc31c03174191ef0d015bdf06007450"), ], + v"2.43.1" => [ + ArchiveSource("https://ftp.gnu.org/gnu/binutils/binutils-2.43.1.tar.xz", + "13f74202a3c4c51118b797a39ea4200d3f6cfbe224da6d1d95bb938480132dfd"), + ], ) binutils_version = binutils_gcc_version_mapping[gcc_version] binutils_sources = binutils_version_sources[binutils_version] diff --git a/0_RootFS/llvm_common.jl b/0_RootFS/llvm_common.jl index 692709f6ddb..b19dba38cfd 100644 --- a/0_RootFS/llvm_common.jl +++ b/0_RootFS/llvm_common.jl @@ -10,13 +10,17 @@ # # for p in ../../../LLVMBootstrap@X-1/bundled/patches/*.patch; do if [[ -L "${p}" ]]; then cp -a "${p}" .; else ln -s "${p}" .; fi; done # +# * adapt the recipe as necessary, but try to make changes in a backward +# compatible way. If you introduce steps that are necessary only with +# specific versions of LLVM, guard them with appropriate conditionals. We may +# need to use the same recipe to rebuild older versions of LLVM at a later +# point and being able to rerun it as-is is extremely important # * you only need to build the platform `x86_64-linux-musl`. To deploy the shard # and automatically update your BinaryBuilderBase's `Artifacts.toml`, use the # `--deploy` flag to the `build_tarballs.jl` script. You can build & deploy # by running: # # julia build_tarballs.jl --debug --verbose --deploy -# include("./common.jl")