mirror of
https://github.com/yuzu-emu/breakpad.git
synced 2024-11-24 17:45:47 +01:00
Linux Breakpad Dumper: support running unit tests under valgrind or other wrapper programs.
This adds a new variable, TEST_WRAPPER, to src/tools/linux/dump_syms. Comments in the patch provide details. This patch also moves the public variable section to sit after the public phony targets. a=jimblandy, r=nealsid git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@486 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
eef5ccc61f
commit
7b873221e6
@ -1,18 +1,3 @@
|
|||||||
### Variables that can be overridden on the command line.
|
|
||||||
CC = gcc
|
|
||||||
CXX = g++
|
|
||||||
CPPFLAGS = -DNDEBUG
|
|
||||||
CXXFLAGS = -g3 -O2 -Wall -m32
|
|
||||||
|
|
||||||
# To produce test coverage reports:
|
|
||||||
# 1) Build all .o files and executables without optimization and with
|
|
||||||
# 'COVERAGE=1' on the make command line.
|
|
||||||
# 2) Run the tests.
|
|
||||||
# 3) Do 'make coverage'.
|
|
||||||
# All in one command:
|
|
||||||
# $ make CFLAGS='-O0' CXXFLAGS='-O0' COVERAGE=1 clean check coverage
|
|
||||||
COVERAGE=
|
|
||||||
|
|
||||||
# Build all executables.
|
# Build all executables.
|
||||||
all::
|
all::
|
||||||
|
|
||||||
@ -38,6 +23,33 @@ coverage-reset:
|
|||||||
|
|
||||||
.PHONY: all clean check coverage coverage-reset
|
.PHONY: all clean check coverage coverage-reset
|
||||||
|
|
||||||
|
### Variables that are useful to override on the command line.
|
||||||
|
CC = gcc
|
||||||
|
CXX = g++
|
||||||
|
CPPFLAGS = -DNDEBUG
|
||||||
|
CXXFLAGS = -g3 -O2 -Wall -m32
|
||||||
|
|
||||||
|
# To produce test coverage reports:
|
||||||
|
# 1) Build all .o files and executables without optimization and with
|
||||||
|
# 'COVERAGE=1' on the make command line.
|
||||||
|
# 2) Run the tests.
|
||||||
|
# 3) Do 'make coverage'.
|
||||||
|
# All in one command:
|
||||||
|
# $ make CFLAGS='-O0' CXXFLAGS='-O0' COVERAGE=1 clean check coverage
|
||||||
|
COVERAGE=
|
||||||
|
|
||||||
|
# A wrapper for running 'make check' targets. This is inserted before
|
||||||
|
# the test executable name in the commands for 'check' targets. So if
|
||||||
|
# 'make check' would normally execute some test program with the
|
||||||
|
# command:
|
||||||
|
#
|
||||||
|
# SOME_ENV_VAR=value ./some-test-executable test-args
|
||||||
|
#
|
||||||
|
# then setting TEST_WRAPPER to 'valgrind' (say) would have 'make
|
||||||
|
# check' run the this command line:
|
||||||
|
#
|
||||||
|
# SOME_ENV_VAR=value valgrind ./some-test-executable test-args
|
||||||
|
TEST_WRAPPER=
|
||||||
|
|
||||||
### Variables used internally by this Makefile.
|
### Variables used internally by this Makefile.
|
||||||
|
|
||||||
@ -195,7 +207,7 @@ clean::
|
|||||||
### appropriate for Google C++ Testing Framework test programs. But
|
### appropriate for Google C++ Testing Framework test programs. But
|
||||||
### you can provide your own commands.
|
### you can provide your own commands.
|
||||||
check-%: %
|
check-%: %
|
||||||
srcdir=$(SRC) ./$< $(TEST_ARGS)
|
srcdir=$(SRC) $(TEST_WRAPPER) ./$< $(TEST_ARGS)
|
||||||
|
|
||||||
|
|
||||||
### Generic coverage reporting rules.
|
### Generic coverage reporting rules.
|
||||||
|
Loading…
Reference in New Issue
Block a user