Kaydet (Commit) 4f76e462 authored tarafından Bjoern Michaelsen's avatar Bjoern Michaelsen Kaydeden (comit) Björn Michaelsen

make CPPUNITTRACE=TRUE a shortcut for debuging on WNT

Change-Id: Ie834e1e1592163977435f0af6dde04c4fe86c1bf
Reviewed-on: https://gerrit.libreoffice.org/19977Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarjan iversen <jani@documentfoundation.org>
Reviewed-by: 's avatarMichael Meeks <michael.meeks@collabora.com>
Reviewed-by: 's avatarBjörn Michaelsen <bjoern.michaelsen@canonical.com>
üst 474f5eeb
...@@ -22,12 +22,12 @@ ...@@ -22,12 +22,12 @@
gb_CppunitTest_UNITTESTFAILED ?= $(GBUILDDIR)/platform/unittest-failed-default.sh gb_CppunitTest_UNITTESTFAILED ?= $(GBUILDDIR)/platform/unittest-failed-default.sh
gb_CppunitTest_PYTHONDEPS ?= $(call gb_Library_get_target,pyuno_wrapper) $(if $(SYSTEM_PYTHON),,$(call gb_Package_get_target,python3)) gb_CppunitTest_PYTHONDEPS ?= $(call gb_Library_get_target,pyuno_wrapper) $(if $(SYSTEM_PYTHON),,$(call gb_Package_get_target,python3))
ifeq ($(strip $(DEBUGCPPUNIT)),TRUE) ifeq ($(strip $(gb_CppunitTest_GDBTRACE)),)
gb_CppunitTest_GDBTRACE := gdb -nx -ex "add-auto-load-safe-path $(INSTDIR)" --batch --command=$(SRCDIR)/solenv/bin/gdbtrycatchtrace-stdout -return-child-result --args ifneq ($(strip $(CPPUNITTRACE)),)
else ifneq ($(strip $(CPPUNITTRACE)),)
gb_CppunitTest_GDBTRACE := $(CPPUNITTRACE) gb_CppunitTest_GDBTRACE := $(CPPUNITTRACE)
gb_CppunitTest__interactive := $(true) gb_CppunitTest__interactive := $(true)
endif endif
endif
ifneq ($(strip $(VALGRIND)),) ifneq ($(strip $(VALGRIND)),)
gb_CppunitTest_VALGRINDTOOL := valgrind --tool=$(VALGRIND) --num-callers=50 --error-exitcode=1 --trace-children=yes --trace-children-skip='*/java,*/gij' gb_CppunitTest_VALGRINDTOOL := valgrind --tool=$(VALGRIND) --num-callers=50 --error-exitcode=1 --trace-children=yes --trace-children-skip='*/java,*/gij'
......
...@@ -190,6 +190,12 @@ $(call gb_Helper_abbreviate_dirs,\ ...@@ -190,6 +190,12 @@ $(call gb_Helper_abbreviate_dirs,\
endef endef
# CppunitTest class
ifeq ($(strip $(DEBUGCPPUNIT)),TRUE)
gb_CppunitTest_GDBTRACE := gdb -nx -ex "add-auto-load-safe-path $(INSTDIR)" --batch --command=$(SRCDIR)/solenv/bin/gdbtrycatchtrace-stdout -return-child-result --args
endif
# ExternalProject class # ExternalProject class
gb_ExternalProject_use_autoconf := gb_ExternalProject_use_autoconf :=
......
...@@ -439,6 +439,10 @@ endef ...@@ -439,6 +439,10 @@ endef
gb_PythonTest_PRECOMMAND := $(gb_CppunitTest_CPPTESTPRECOMMAND) gb_PythonTest_PRECOMMAND := $(gb_CppunitTest_CPPTESTPRECOMMAND)
gb_PythonTest_DEPS := $(call gb_Package_get_target,python3) gb_PythonTest_DEPS := $(call gb_Package_get_target,python3)
ifeq ($(strip $(CPPUNITTRACE)),TRUE)
gb_CppunitTest_GDBTRACE := '$(DEVENV)' /debugexe
endif
# SrsPartTarget class # SrsPartTarget class
ifeq ($(gb_FULLDEPS),$(true)) ifeq ($(gb_FULLDEPS),$(true))
......
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
cat << EOF cat << EOF
Error: a unit test failed, please do one of: Error: a unit test failed, please do one of:
make $1Test_$2 CPPUNITTRACE=TRUE # which is a shortcut for the following line
make $1Test_$2 CPPUNITTRACE="'$DEVENV' /debugexe" # for interactive debugging in Visual Studio make $1Test_$2 CPPUNITTRACE="'$DEVENV' /debugexe" # for interactive debugging in Visual Studio
make $1Test_$2 CPPUNITTRACE="drmemory -free_max_frames 20" # for memory checking (install Dr.Memory first, and put it to your PATH) make $1Test_$2 CPPUNITTRACE="drmemory -free_max_frames 20" # for memory checking (install Dr.Memory first, and put it to your PATH)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment