allow setting DEBUGCPPUNIT=TRUE to dump a gdb try/catch trace

This commit is contained in:
Caolán McNamara
2011-04-07 11:37:56 +01:00
parent 2f9a326043
commit b9bc97d455
2 changed files with 19 additions and 1 deletions

View File

@@ -0,0 +1,14 @@
set pagination off
catch throw
commands
bt
cont
end
catch catch
commands
bt
cont
end
run
bt
quit

View File

@@ -32,11 +32,15 @@
DBGSV_ERROR_OUT := shell
export DBGSV_ERROR_OUT
ifeq ($(strip $(DEBUGCPPUNIT)),TRUE)
gb_CppunitTest_GDBTRACE := gdb -nx --command=$(SOLARENV)/bin/gdbtrycatchtrace-stdout -return-child-result --args
endif
# defined by platform
# gb_CppunitTest_TARGETTYPE
# gb_CppunitTest_get_filename
gb_CppunitTest_CPPTESTTARGET := $(call gb_Executable_get_target,cppunit/cppunittester)
gb_CppunitTest_CPPTESTCOMMAND := $(gb_CppunitTest_CPPTESTPRECOMMAND) $(gb_CppunitTest_CPPTESTTARGET)
gb_CppunitTest_CPPTESTCOMMAND := $(gb_CppunitTest_CPPTESTPRECOMMAND) $(gb_CppunitTest_GDBTRACE) $(gb_CppunitTest_CPPTESTTARGET)
gb_CppunitTest__get_linktargetname = CppunitTest/$(call gb_CppunitTest_get_filename,$(1))
.PHONY : $(call gb_CppunitTest_get_clean_target,%)