From ed48912ae6c77f1902a41fa06aae680507c8092b Mon Sep 17 00:00:00 2001 From: hacheigriega Date: Wed, 14 Aug 2024 09:09:15 -0400 Subject: [PATCH] chore: add error message in makefile when both rosetta and static are on --- Makefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 0bffdbc7..947609cd 100644 --- a/Makefile +++ b/Makefile @@ -74,7 +74,10 @@ endif # For building statically linked binaries ifeq ($(LINK_STATICALLY),true) - ldflags += -linkmode=external -extldflags "-Wl,-z,muldefs -static" + ifeq ($(ENABLE_ROSETTA),true) + $(error Cannot link statically when Rosetta is enabled) + endif + ldflags += -linkmode=external -extldflags "-Wl,-z,muldefs -static" endif ifeq (,$(findstring nostrip,$(COSMOS_BUILD_OPTIONS)))