diff options
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 15 |
1 files changed, 11 insertions, 4 deletions
| @@ -69,8 +69,8 @@ CFLAGS_libowfat=-I$(LIBOWFAT_HEADERS) | |||
| 69 | LDFLAGS_libowfat=-L$(LIBOWFAT_LIBRARY) -lowfat | 69 | LDFLAGS_libowfat=-L$(LIBOWFAT_LIBRARY) -lowfat |
| 70 | 70 | ||
| 71 | BINARY =opentracker | 71 | BINARY =opentracker |
| 72 | HEADERS=trackerlogic.h ot_urlencoded.h ot_batch.h ot_buf.h ot_event.h ot_fdstate.h ot_fmt.h ot_hex.h ot_ip.h ot_config.h ot_scan.h ot_socket.h ot_mutex.h ot_random.h ot_stats.h ot_vector.h ot_clean.h ot_udp.h ot_iovec.h ot_fullscrape.h ot_accesslist.h ot_http.h ot_livesync.h ot_rijndael.h | 72 | HEADERS=trackerlogic.h ot_urlencoded.h ot_batch.h ot_buf.h ot_event.h ot_fdstate.h ot_fmt.h ot_hex.h ot_ip.h ot_config.h ot_scan.h ot_socket.h ot_tcp.h ot_mutex.h ot_random.h ot_stats.h ot_vector.h ot_clean.h ot_udp.h ot_iovec.h ot_fullscrape.h ot_accesslist.h ot_http.h ot_livesync.h ot_rijndael.h |
| 73 | SOURCES=opentracker.c trackerlogic.c ot_urlencoded.c ot_batch.c ot_buf.c ot_event.c ot_fdstate.c ot_fmt.c ot_hex.c ot_ip.c ot_config.c ot_scan.c ot_socket.c ot_mutex.c ot_random.c ot_stats.c ot_vector.c ot_clean.c ot_udp.c ot_iovec.c ot_fullscrape.c ot_accesslist.c ot_http.c ot_livesync.c ot_rijndael.c | 73 | SOURCES=opentracker.c trackerlogic.c ot_urlencoded.c ot_batch.c ot_buf.c ot_event.c ot_fdstate.c ot_fmt.c ot_hex.c ot_ip.c ot_config.c ot_scan.c ot_socket.c ot_tcp.c ot_mutex.c ot_random.c ot_stats.c ot_vector.c ot_clean.c ot_udp.c ot_iovec.c ot_fullscrape.c ot_accesslist.c ot_http.c ot_livesync.c ot_rijndael.c |
| 74 | SOURCES_proxy=proxy.c ot_batch.c ot_fdstate.c ot_vector.c ot_mutex.c ot_random.c ot_scan.c ot_ip.c ot_socket.c | 74 | SOURCES_proxy=proxy.c ot_batch.c ot_fdstate.c ot_vector.c ot_mutex.c ot_random.c ot_scan.c ot_ip.c ot_socket.c |
| 75 | 75 | ||
| 76 | all: $(BINARY) $(BINARY).debug | 76 | all: $(BINARY) $(BINARY).debug |
| @@ -110,6 +110,12 @@ $(TESTBIN): $(TEST_SOURCES) $(TEST_UNITS) $(TEST_HEADERS) | |||
| 110 | check: $(TESTBIN) $(BINARY) | 110 | check: $(TESTBIN) $(BINARY) |
| 111 | ./$(TESTBIN) | 111 | ./$(TESTBIN) |
| 112 | 112 | ||
| 113 | $(TESTBIN).poll: $(TEST_SOURCES) $(TEST_UNITS) $(TEST_HEADERS) | ||
| 114 | $(CC) -o $@ $(CFLAGS_test) -DOT_EVENT_FORCE_POLL $(TEST_SOURCES) $(TEST_UNITS) | ||
| 115 | |||
| 116 | check-poll: $(TESTBIN).poll | ||
| 117 | ./$(TESTBIN).poll ot_event | ||
| 118 | |||
| 113 | # The same unit tests under the sanitizers. Use clang over $(CC) because the | 119 | # The same unit tests under the sanitizers. Use clang over $(CC) because the |
| 114 | # two toolchains do not check the same things | 120 | # two toolchains do not check the same things |
| 115 | # Override CC_sanitize to use another compiler. | 121 | # Override CC_sanitize to use another compiler. |
| @@ -153,13 +159,14 @@ check-tsan: opentracker.tsan | |||
| 153 | # Everything, cheapest first, so a quick failure comes back quickly. | 159 | # Everything, cheapest first, so a quick failure comes back quickly. |
| 154 | check-all: | 160 | check-all: |
| 155 | $(MAKE) check | 161 | $(MAKE) check |
| 162 | $(MAKE) check-poll | ||
| 156 | $(MAKE) check-sanitize | 163 | $(MAKE) check-sanitize |
| 157 | $(MAKE) check-integration | 164 | $(MAKE) check-integration |
| 158 | $(MAKE) check-tsan | 165 | $(MAKE) check-tsan |
| 159 | 166 | ||
| 160 | .PHONY: all check check-sanitize check-integration check-tsan check-all clean install | 167 | .PHONY: all check check-poll check-sanitize check-integration check-tsan check-all clean install |
| 161 | 168 | ||
| 162 | BINARIES=opentracker opentracker.debug opentracker.integration opentracker.tsan proxy proxy.debug $(TESTBIN) $(TESTBIN).sanitize | 169 | BINARIES=opentracker opentracker.debug opentracker.integration opentracker.tsan proxy proxy.debug $(TESTBIN) $(TESTBIN).sanitize $(TESTBIN).poll |
| 163 | 170 | ||
| 164 | clean: | 171 | clean: |
| 165 | rm -rf $(BINARIES) $(BINARIES:=.dSYM) *.o *~ | 172 | rm -rf $(BINARIES) $(BINARIES:=.dSYM) *.o *~ |
