mirror of
https://github.com/fail0verflow/bootmii-utils.git
synced 2024-11-22 18:29:18 +01:00
buildtoolchain: add patch to build modern GCC on ARM64 Apple devices
This commit is contained in:
parent
31724a5e73
commit
cdbc093553
@ -105,6 +105,8 @@ prepsrc() {
|
|||||||
|
|
||||||
extract "$1/src" "$1/var/cache/$BINUTILS_TARBALL"
|
extract "$1/src" "$1/var/cache/$BINUTILS_TARBALL"
|
||||||
extract "$1/src" "$1/var/cache/$GCC_TARBALL"
|
extract "$1/src" "$1/var/cache/$GCC_TARBALL"
|
||||||
|
patch -d "$1"/src/gcc-* -u -p1 -i $SCRIPTDIR/gcc-11.3.0.patch || die "Error applying GCC patch"
|
||||||
|
|
||||||
extract "$1/src/$GCC_DIR" "$1/var/cache/$GMP_TARBALL"
|
extract "$1/src/$GCC_DIR" "$1/var/cache/$GMP_TARBALL"
|
||||||
mv "$1/src/$GCC_DIR/$GMP_DIR" "$1/src/$GCC_DIR/gmp" || die "Error renaming $GMP_DIR -> gmp"
|
mv "$1/src/$GCC_DIR/$GMP_DIR" "$1/src/$GCC_DIR/gmp" || die "Error renaming $GMP_DIR -> gmp"
|
||||||
extract "$1/src/$GCC_DIR" "$1/var/cache/$MPFR_TARBALL"
|
extract "$1/src/$GCC_DIR" "$1/var/cache/$MPFR_TARBALL"
|
||||||
|
20
buildtoolchain/gcc-11.3.0.patch
Normal file
20
buildtoolchain/gcc-11.3.0.patch
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
https://github.com/richfelker/musl-cross-make/issues/116#issuecomment-823612404
|
||||||
|
|
||||||
|
diff -Nru gcc-11.3.0/gcc/config/host-darwin.c gcc-11.3.0-patched/gcc/config/host-darwin.c
|
||||||
|
--- gcc-11.3.0/gcc/config/host-darwin.c 2022-04-21 09:58:52
|
||||||
|
+++ gcc-11.3.0-patched/gcc/config/host-darwin.c 2024-01-03 00:34:29
|
||||||
|
@@ -22,6 +22,8 @@
|
||||||
|
#include "coretypes.h"
|
||||||
|
#include "diagnostic-core.h"
|
||||||
|
#include "config/host-darwin.h"
|
||||||
|
+#include "hosthooks.h"
|
||||||
|
+#include "hosthooks-def.h"
|
||||||
|
|
||||||
|
/* Yes, this is really supposed to work. */
|
||||||
|
/* This allows for a pagesize of 16384, which we have on Darwin20, but should
|
||||||
|
@@ -79,3 +81,5 @@
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
+
|
||||||
|
+const struct host_hooks host_hooks = HOST_HOOKS_INITIALIZER;
|
Loading…
Reference in New Issue
Block a user