From 7a0801040687d8c84ce2129c261e2fb49687681a Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Fri, 5 Jun 2026 19:22:10 +0200 Subject: [PATCH 1/3] Fix trashing of $data that breaks the check for C11 atomics --- c_check | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/c_check b/c_check index b887368b26..25e503c8c1 100755 --- a/c_check +++ b/c_check @@ -342,8 +342,8 @@ no_sme=0 is_appleclang=0 if [ "$architecture" = "arm64" ]; then if [ "$compiler" = "CLANG" ]; then - data=`$compiler_name --version` - case "$data" in Apple*) + vdata=`$compiler_name --version` + case "$vdata" in Apple*) is_appleclang=1 esac fi From 8a767975b0ff6c6ad00b69d49774b3469d7b76d6 Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Fri, 5 Jun 2026 20:37:28 +0200 Subject: [PATCH 2/3] Comment out the libclang_rt kludge, for future removal --- Makefile.arm64 | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Makefile.arm64 b/Makefile.arm64 index bcdda04778..49b25ab6f9 100644 --- a/Makefile.arm64 +++ b/Makefile.arm64 @@ -310,12 +310,10 @@ endif ifeq ($(CORE), VORTEXM4) ifneq ($(C_COMPILER), GCC) -ifeq ($(APPLECLANG),1) CCOMMON_OPT += -march=armv8.4-a+sme -else -CCOMMON_OPT += -march=armv8.4-a+sme -override LDFLAGS += -lclang_rt_builtins-aarch64 -endif +#ifneq ($(APPLECLANG),1) +#override LDFLAGS += -lclang_rt_builtins-aarch64 +#endif else CCOMMON_OPT += -march=armv8.4-a endif From 1145c75a9609c032bdb2659f683b0f7215aedcc6 Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Fri, 5 Jun 2026 23:06:28 +0200 Subject: [PATCH 3/3] Comment out the libclang_rt.builtins kludge in preparation for removal --- kernel/Makefile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/kernel/Makefile b/kernel/Makefile index 221836d185..9cab79c869 100644 --- a/kernel/Makefile +++ b/kernel/Makefile @@ -38,12 +38,10 @@ ifeq ($(TARGET_CORE), VORTEXM4) ifeq ($(C_COMPILER), GCC) override CFLAGS += -DBUILD_KERNEL -DTABLE_NAME=gotoblas_$(TARGET_CORE) -UHAVE_SME -march=armv8.4-a else - ifeq ($(APPLECLANG),1) - override CFLAGS += -DBUILD_KERNEL -DTABLE_NAME=gotoblas_$(TARGET_CORE) -march=armv8.4-a+sme - else - override CFLAGS += -DBUILD_KERNEL -DTABLE_NAME=gotoblas_$(TARGET_CORE) -march=armv8.4-a+sme - override LDFLAGS += -lclang_rt_builtins-aarch64 - endif + override CFLAGS += -DBUILD_KERNEL -DTABLE_NAME=gotoblas_$(TARGET_CORE) -march=armv8.4-a+sme +# ifneq ($(APPLECLANG),1) +# override LDFLAGS += -lclang_rt_builtins-aarch64 +# endif ifdef OS_WINDOWS ifeq ($(C_COMPILER), CLANG) override CFLAGS += --aarch64-stack-hazard-size=0