diff options
| -rw-r--r-- | Makefile | 15 |
1 files changed, 13 insertions, 2 deletions
| @@ -162,15 +162,26 @@ opentracker.integration: $(SOURCES) $(HEADERS) | |||
| 162 | check-integration: opentracker.integration | 162 | check-integration: opentracker.integration |
| 163 | OPENTRACKER=./opentracker.integration $(PYTHON) -m unittest discover -s tests/integration | 163 | OPENTRACKER=./opentracker.integration $(PYTHON) -m unittest discover -s tests/integration |
| 164 | 164 | ||
| 165 | # The same black box tests against a ThreadSanitizer build | ||
| 166 | CFLAGS_tsan=$(CFLAGS) $(OPTS_debug) $(FEATURES_integration) -fsanitize=thread -fno-omit-frame-pointer | ||
| 167 | LDFLAGS_tsan=$(LDFLAGS) -fsanitize=thread | ||
| 168 | |||
| 169 | opentracker.tsan: $(SOURCES) $(HEADERS) | ||
| 170 | $(CC) -o $@ $(CFLAGS_tsan) $(SOURCES) $(LDFLAGS_tsan) | ||
| 171 | |||
| 172 | check-tsan: opentracker.tsan | ||
| 173 | OPENTRACKER=./opentracker.tsan $(PYTHON) -m unittest discover -s tests/integration | ||
| 174 | |||
| 165 | # Everything, cheapest first, so a quick failure comes back quickly. | 175 | # Everything, cheapest first, so a quick failure comes back quickly. |
| 166 | check-all: | 176 | check-all: |
| 167 | $(MAKE) check | 177 | $(MAKE) check |
| 168 | $(MAKE) check-sanitize | 178 | $(MAKE) check-sanitize |
| 169 | $(MAKE) check-integration | 179 | $(MAKE) check-integration |
| 180 | $(MAKE) check-tsan | ||
| 170 | 181 | ||
| 171 | .PHONY: all check check-sanitize check-integration check-all clean install | 182 | .PHONY: all check check-sanitize check-integration check-tsan check-all clean install |
| 172 | 183 | ||
| 173 | BINARIES=opentracker opentracker.debug opentracker.integration proxy proxy.debug $(TESTBIN) $(TESTBIN).sanitize | 184 | BINARIES=opentracker opentracker.debug opentracker.integration opentracker.tsan proxy proxy.debug $(TESTBIN) $(TESTBIN).sanitize |
| 174 | 185 | ||
| 175 | clean: | 186 | clean: |
| 176 | rm -rf $(BINARIES) $(BINARIES:=.dSYM) *.o *~ | 187 | rm -rf $(BINARIES) $(BINARIES:=.dSYM) *.o *~ |
