From 1bf2ff01599770cda8e6b21f1b372560add12307 Mon Sep 17 00:00:00 2001 From: Alug Date: Fri, 15 Aug 2025 07:57:31 +0200 Subject: [PATCH] append those to LDFLAGS instead of libs so they may be passed to other things --- src/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/Makefile b/src/Makefile index ee77a948c..b4e9a161e 100644 --- a/src/Makefile +++ b/src/Makefile @@ -246,7 +246,7 @@ endif # build with profiling information ifdef PROFILEMODE opts+=-pg -libs+=-pg +LDFLAGS+=-pg endif ifdef DEBUGMODE @@ -258,10 +258,10 @@ ifdef USELTO # compile with LTO ifdef MINGW opts+=-flto=auto -g -libs+=-flto=auto -g +LDFLAGS+=-flto=auto -g else opts+=-flto=auto -libs+=-flto=auto +LDFLAGS+=-flto=auto endif endif endif @@ -275,8 +275,8 @@ else opts+=-fsanitize=address libs+=-fsanitize=address endif -opts+=-fsanitize=address -libs+=-fsanitize=address +endif + endif # debug_opts also get passed to windres @@ -291,6 +291,7 @@ cxxopts:=$(opts) $(CXXFLAGS) opts+=$(CWFLAGS) # warning flags that shouldnt be passed to c++ compiler libs+=$(LDFLAGS) -lstdc++ -lpthread + asflags:=$(ASFLAGS) -x assembler-with-cpp cc=$(CC)