diff options
Diffstat (limited to 'solenv/gbuild')
-rw-r--r-- | solenv/gbuild/LinkTarget.mk | 3 | ||||
-rw-r--r-- | solenv/gbuild/platform/EMSCRIPTEN_INTEL_GCC.mk | 6 |
2 files changed, 8 insertions, 1 deletions
diff --git a/solenv/gbuild/LinkTarget.mk b/solenv/gbuild/LinkTarget.mk index accb3a400df5..5dbdadc23f87 100644 --- a/solenv/gbuild/LinkTarget.mk +++ b/solenv/gbuild/LinkTarget.mk @@ -51,7 +51,8 @@ gb_LinkTarget__get_debugflags= \ # T_LDFLAGS is just expanded once. Override the flags here, so that the linker and compiler use the same. ifeq (EMSCRIPTEN,$(OS)) -gb_LinkTarget__get_debugldflags=$(call gb_LinkTarget__get_debugflags,$1) +gb_LinkTarget__get_debugldflags=$(call gb_LinkTarget__get_debugflags,$1) \ + $(gb_LinkTarget__emscripten_warnings_ldflags) else # similar for LDFLAGS, use linker optimization flags in non-debug case, # but moreover strip debug from libraries for which debuginfo is not wanted diff --git a/solenv/gbuild/platform/EMSCRIPTEN_INTEL_GCC.mk b/solenv/gbuild/platform/EMSCRIPTEN_INTEL_GCC.mk index 37d23aabcfe9..227ef83990de 100644 --- a/solenv/gbuild/platform/EMSCRIPTEN_INTEL_GCC.mk +++ b/solenv/gbuild/platform/EMSCRIPTEN_INTEL_GCC.mk @@ -48,6 +48,12 @@ endif gb_LinkTarget_LDFLAGS += $(gb_EMSCRIPTEN_LDFLAGS) $(gb_EMSCRIPTEN_CPPFLAGS) \ $(gb_EMSCRIPTEN_EXCEPT) -sEXPORT_EXCEPTION_HANDLING_HELPERS +ifeq ($(ENABLE_OPTIMIZED),TRUE) +ifneq ($(ENABLE_SYMBOLS_FOR),) +gb_LinkTarget__emscripten_warnings_ldflags := -Wno-limited-postlink-optimizations +endif +endif + # Linker and compiler optimize + debug flags are handled in LinkTarget.mk gb_LINKEROPTFLAGS := gb_LINKERSTRIPDEBUGFLAGS := |