From c7c289778a272b151644bda3b3d2116a3ede5d45 Mon Sep 17 00:00:00 2001 From: sisong Date: Mon, 29 Jul 2024 19:32:59 +0800 Subject: [PATCH] recode makefile link seting for optimize hpatchz file size; --- Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 3975bfa1..3c891f96 100644 --- a/Makefile +++ b/Makefile @@ -380,24 +380,24 @@ ifeq ($(STATIC_C),0) else PATCH_LINK += -static endif -DIFF_LINK := $(PATCH_LINK) ifeq ($(M32),0) else - DIFF_LINK += -m32 + PATCH_LINK += -m32 endif ifeq ($(MINS),0) else - DIFF_LINK += -s -Wl,--gc-sections,--as-needed -endif -ifeq ($(CL),1) - CXX := clang++ - CC := clang + PATCH_LINK += -s -Wl,--gc-sections,--as-needed endif +DIFF_LINK := $(PATCH_LINK) ifeq ($(STATIC_CPP),0) DIFF_LINK += -lstdc++ else DIFF_LINK += -static-libstdc++ endif +ifeq ($(CL),1) + CXX := clang++ + CC := clang +endif CFLAGS += $(DEF_FLAGS)