From 271fcee5f4545395fbdb51bdf44697bf69bb5f2d Mon Sep 17 00:00:00 2001 From: Hugo Melder Date: Mon, 18 Aug 2025 13:41:03 +0200 Subject: [PATCH] Enable weak-style references in "ng" configuration Currently, all code emulating weak references by just not retaining it is essentially UB when interfacing with ARC. The clang flag enables the use of '__weak' in non-ARC translation units. --- library-combo.make | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library-combo.make b/library-combo.make index 16f531c6..baa66974 100644 --- a/library-combo.make +++ b/library-combo.make @@ -50,7 +50,7 @@ ifeq ($(OBJC_RUNTIME_LIB), ng) RUNTIME_VERSION=gnustep-2.2 endif endif - RUNTIME_FLAG = -fobjc-runtime=$(RUNTIME_VERSION) -fblocks + RUNTIME_FLAG = -fobjc-runtime=$(RUNTIME_VERSION) -fblocks -fobjc-weak RUNTIME_DEFINE = -DGNUSTEP_RUNTIME=1 -D_NONFRAGILE_ABI=1 endif