From a9eedfe40509af1651c27eaf42067a1e79112b13 Mon Sep 17 00:00:00 2001 From: Martin Kinkelin Date: Sun, 19 Feb 2023 10:56:30 +0100 Subject: [PATCH] druntime: Fix up `cpp_demangle` subtest of `exceptions` integration tests (#14894) * Don't run the test in release mode on Linux; just like for the other Posix targets. * Include `-L--export-dynamic` as required dflag (added implicitly to cc linker cmdline by DMD, but not by LDC), which is required for symbol resolution in druntime exception backtraces. --- druntime/test/exceptions/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/druntime/test/exceptions/Makefile b/druntime/test/exceptions/Makefile index 6be18e4353a..d7d2c82427b 100644 --- a/druntime/test/exceptions/Makefile +++ b/druntime/test/exceptions/Makefile @@ -9,7 +9,7 @@ ifeq ($(OS)-$(BUILD),linux-debug) LINE_TRACE_DFLAGS:=-L--export-dynamic endif ifeq ($(OS),linux) - TESTS+=rt_trap_exceptions_drt_gdb cpp_demangle + TESTS+=rt_trap_exceptions_drt_gdb endif ifeq ($(OS)-$(BUILD),freebsd-debug) TESTS+=line_trace line_trace_21656 long_backtrace_trunc cpp_demangle @@ -129,7 +129,7 @@ $(ROOT)/long_backtrace_trunc: DFLAGS+=$(LINE_TRACE_DFLAGS) $(ROOT)/rt_trap_exceptions: DFLAGS+=$(LINE_TRACE_DFLAGS) $(ROOT)/rt_trap_exceptions_drt: DFLAGS+=-g $(ROOT)/refcounted: DFLAGS+=-dip1008 -$(ROOT)/cpp_demangle: DFLAGS+=-L-lstdc++ +$(ROOT)/cpp_demangle: DFLAGS+=-L-lstdc++ $(LINE_TRACE_DFLAGS) $(ROOT)/%: $(SRC)/%.d $(DMD) $(DRUNTIME) $(QUIET)$(DMD) $(DFLAGS) -of$@ $<