From 670020c850da7af3f1a7fa6b00025a124979f465 Mon Sep 17 00:00:00 2001 From: malik1004x Date: Fri, 11 Jul 2025 06:27:50 +0200 Subject: Rust bootstrap support for macOS aarch64 (#143) * darwin rust bootstrap support * add patches for darwin rust bootstrap --- .../depends/patches/native_mrustc/codegen_c.cpp.patch | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 contrib/depends/patches/native_mrustc/codegen_c.cpp.patch (limited to 'contrib/depends/patches/native_mrustc') diff --git a/contrib/depends/patches/native_mrustc/codegen_c.cpp.patch b/contrib/depends/patches/native_mrustc/codegen_c.cpp.patch new file mode 100644 index 0000000..b392636 --- /dev/null +++ b/contrib/depends/patches/native_mrustc/codegen_c.cpp.patch @@ -0,0 +1,17 @@ +--- a/src/trans/codegen_c.cpp 2025-07-08 00:17:10.022769383 +0200 ++++ b/src/trans/codegen_c.cpp 2025-07-08 00:17:18.404645999 +0200 +@@ -1297,8 +1297,14 @@ + // HACK: Work around [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117423] by disabling an optimisation stage + if( opt.opt_level > 0 ) + { ++ #ifndef __clang__ // clang doesn't have this option. + args.push_back("-fno-tree-sra"); ++ #endif + } ++ #ifdef __APPLE__ ++ args.push_back("-framework"); ++ args.push_back("Security"); ++ #endif + if( opt.emit_debug_info ) + { + args.push_back("-g"); \ No newline at end of file -- cgit v1.2.3