summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--DESIGN2
-rw-r--r--Makefile6
-rw-r--r--Mk/proxy.mk2
-rw-r--r--Mk/tests.mk4
-rw-r--r--src/opentracker.c (renamed from opentracker.c)0
-rw-r--r--src/ot_accesslist.c (renamed from ot_accesslist.c)0
-rw-r--r--src/ot_accesslist.h (renamed from ot_accesslist.h)0
-rw-r--r--src/ot_batch.c (renamed from ot_batch.c)0
-rw-r--r--src/ot_batch.h (renamed from ot_batch.h)0
-rw-r--r--src/ot_buf.c (renamed from ot_buf.c)0
-rw-r--r--src/ot_buf.h (renamed from ot_buf.h)0
-rw-r--r--src/ot_clean.c (renamed from ot_clean.c)0
-rw-r--r--src/ot_clean.h (renamed from ot_clean.h)0
-rw-r--r--src/ot_config.c (renamed from ot_config.c)0
-rw-r--r--src/ot_config.h (renamed from ot_config.h)0
-rw-r--r--src/ot_event.c (renamed from ot_event.c)0
-rw-r--r--src/ot_event.h (renamed from ot_event.h)0
-rw-r--r--src/ot_fdstate.c (renamed from ot_fdstate.c)0
-rw-r--r--src/ot_fdstate.h (renamed from ot_fdstate.h)0
-rw-r--r--src/ot_fmt.c (renamed from ot_fmt.c)0
-rw-r--r--src/ot_fmt.h (renamed from ot_fmt.h)0
-rw-r--r--src/ot_fullscrape.c (renamed from ot_fullscrape.c)0
-rw-r--r--src/ot_fullscrape.h (renamed from ot_fullscrape.h)0
-rw-r--r--src/ot_hex.c (renamed from ot_hex.c)0
-rw-r--r--src/ot_hex.h (renamed from ot_hex.h)0
-rw-r--r--src/ot_http.c (renamed from ot_http.c)0
-rw-r--r--src/ot_http.h (renamed from ot_http.h)0
-rw-r--r--src/ot_iovec.c (renamed from ot_iovec.c)0
-rw-r--r--src/ot_iovec.h (renamed from ot_iovec.h)0
-rw-r--r--src/ot_ip.c (renamed from ot_ip.c)0
-rw-r--r--src/ot_ip.h (renamed from ot_ip.h)0
-rw-r--r--src/ot_livesync.c (renamed from ot_livesync.c)0
-rw-r--r--src/ot_livesync.h (renamed from ot_livesync.h)0
-rw-r--r--src/ot_mutex.c (renamed from ot_mutex.c)0
-rw-r--r--src/ot_mutex.h (renamed from ot_mutex.h)0
-rw-r--r--src/ot_random.c (renamed from ot_random.c)0
-rw-r--r--src/ot_random.h (renamed from ot_random.h)0
-rw-r--r--src/ot_rijndael.c (renamed from ot_rijndael.c)0
-rw-r--r--src/ot_rijndael.h (renamed from ot_rijndael.h)0
-rw-r--r--src/ot_scan.c (renamed from ot_scan.c)0
-rw-r--r--src/ot_scan.h (renamed from ot_scan.h)0
-rw-r--r--src/ot_socket.c (renamed from ot_socket.c)0
-rw-r--r--src/ot_socket.h (renamed from ot_socket.h)0
-rw-r--r--src/ot_stats.c (renamed from ot_stats.c)0
-rw-r--r--src/ot_stats.h (renamed from ot_stats.h)0
-rw-r--r--src/ot_tcp.c (renamed from ot_tcp.c)0
-rw-r--r--src/ot_tcp.h (renamed from ot_tcp.h)0
-rw-r--r--src/ot_udp.c (renamed from ot_udp.c)0
-rw-r--r--src/ot_udp.h (renamed from ot_udp.h)0
-rw-r--r--src/ot_urlencoded.c (renamed from ot_urlencoded.c)0
-rw-r--r--src/ot_urlencoded.h (renamed from ot_urlencoded.h)0
-rw-r--r--src/ot_vector.c (renamed from ot_vector.c)0
-rw-r--r--src/ot_vector.h (renamed from ot_vector.h)0
-rw-r--r--src/ot_worker.c (renamed from ot_worker.c)0
-rw-r--r--src/ot_worker.h (renamed from ot_worker.h)0
-rw-r--r--src/ot_workqueue.c (renamed from ot_workqueue.c)0
-rw-r--r--src/ot_workqueue.h (renamed from ot_workqueue.h)0
-rw-r--r--src/proxy.c (renamed from proxy.c)0
-rw-r--r--src/trackerlogic.c (renamed from trackerlogic.c)0
-rw-r--r--src/trackerlogic.h (renamed from trackerlogic.h)0
60 files changed, 6 insertions, 8 deletions
diff --git a/DESIGN b/DESIGN
index 5abeb4a..f058fe0 100644
--- a/DESIGN
+++ b/DESIGN
@@ -114,8 +114,6 @@ A directory for object files. bmake has no pattern rules and the Makefile
114builds under FreeBSD's make today. Building each binary in one invocation 114builds under FreeBSD's make today. Building each binary in one invocation
115clears the objects out of the tree without giving that up. 115clears the objects out of the tree without giving that up.
116 116
117A src/ directory. 52 files sharing an ot_ prefix are a module list rather
118than clutter, and build output was most of what made the tree look crowded.
119 117
120 118
121Platform differences that cost us code 119Platform differences that cost us code
diff --git a/Makefile b/Makefile
index 993f0ae..d2e0c2d 100644
--- a/Makefile
+++ b/Makefile
@@ -49,8 +49,8 @@ COMPILE=$(CPPFLAGS) $(OT_CFLAGS) $(FEATURES)
49LINK=$(LDFLAGS) $(OT_LDFLAGS) $(LDLIBS) $(OT_LDLIBS) 49LINK=$(LDFLAGS) $(OT_LDFLAGS) $(LDLIBS) $(OT_LDLIBS)
50 50
51BINARY=opentracker 51BINARY=opentracker
52HEADERS=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_worker.h ot_workqueue.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 52HEADERS=src/trackerlogic.h src/ot_urlencoded.h src/ot_batch.h src/ot_buf.h src/ot_event.h src/ot_fdstate.h src/ot_fmt.h src/ot_hex.h src/ot_ip.h src/ot_config.h src/ot_scan.h src/ot_socket.h src/ot_tcp.h src/ot_worker.h src/ot_workqueue.h src/ot_mutex.h src/ot_random.h src/ot_stats.h src/ot_vector.h src/ot_clean.h src/ot_udp.h src/ot_iovec.h src/ot_fullscrape.h src/ot_accesslist.h src/ot_http.h src/ot_livesync.h src/ot_rijndael.h
53SOURCES=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_worker.c ot_workqueue.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 53SOURCES=src/opentracker.c src/trackerlogic.c src/ot_urlencoded.c src/ot_batch.c src/ot_buf.c src/ot_event.c src/ot_fdstate.c src/ot_fmt.c src/ot_hex.c src/ot_ip.c src/ot_config.c src/ot_scan.c src/ot_socket.c src/ot_tcp.c src/ot_worker.c src/ot_workqueue.c src/ot_mutex.c src/ot_random.c src/ot_stats.c src/ot_vector.c src/ot_clean.c src/ot_udp.c src/ot_iovec.c src/ot_fullscrape.c src/ot_accesslist.c src/ot_http.c src/ot_livesync.c src/ot_rijndael.c
54BINARIES=$(BINARY) $(BINARY).debug 54BINARIES=$(BINARY) $(BINARY).debug
55 55
56# Everything is built in one go from sources, so there are no object files to 56# Everything is built in one go from sources, so there are no object files to
@@ -73,7 +73,7 @@ $(BUILDSTAMP): FORCE
73 @echo "$(CFLAGS) $(COMPILE) $(LINK)" | cmp -s - $@ 2>/dev/null || echo "$(CFLAGS) $(COMPILE) $(LINK)" > $@ 73 @echo "$(CFLAGS) $(COMPILE) $(LINK)" | cmp -s - $@ 2>/dev/null || echo "$(CFLAGS) $(COMPILE) $(LINK)" > $@
74 74
75clean: 75clean:
76 rm -rf $(BINARIES) $(BINARIES:=.dSYM) $(BUILDSTAMP) *.o *~ 76 rm -rf $(BINARIES) $(BINARIES:=.dSYM) $(BUILDSTAMP) *.o *~ src/*.o src/*~
77 77
78install: $(BINARY) 78install: $(BINARY)
79 install -d $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1 $(DESTDIR)$(MANDIR)/man5 79 install -d $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1 $(DESTDIR)$(MANDIR)/man5
diff --git a/Mk/proxy.mk b/Mk/proxy.mk
index 2e876e9..64d18dc 100644
--- a/Mk/proxy.mk
+++ b/Mk/proxy.mk
@@ -7,7 +7,7 @@
7# CFLAGS_libowfat=-I$(LIBOWFAT_HEADERS) 7# CFLAGS_libowfat=-I$(LIBOWFAT_HEADERS)
8# LDFLAGS_libowfat=-L$(LIBOWFAT_LIBRARY) -lowfat 8# LDFLAGS_libowfat=-L$(LIBOWFAT_LIBRARY) -lowfat
9# 9#
10# 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 10# SOURCES_proxy=src/proxy.c src/ot_batch.c src/ot_fdstate.c src/ot_vector.c src/ot_mutex.c src/ot_random.c src/ot_scan.c src/ot_ip.c src/ot_socket.c
11# CFLAGS_proxy=$(CFLAGS_production) $(CFLAGS_libowfat) -DWANT_SYNC_LIVE 11# CFLAGS_proxy=$(CFLAGS_production) $(CFLAGS_libowfat) -DWANT_SYNC_LIVE
12# CFLAGS_proxy_debug=$(CFLAGS_debug) $(CFLAGS_libowfat) -DWANT_SYNC_LIVE 12# CFLAGS_proxy_debug=$(CFLAGS_debug) $(CFLAGS_libowfat) -DWANT_SYNC_LIVE
13# 13#
diff --git a/Mk/tests.mk b/Mk/tests.mk
index 8e63839..46f308b 100644
--- a/Mk/tests.mk
+++ b/Mk/tests.mk
@@ -5,13 +5,13 @@ BUILDDEPS+=Mk/tests.mk
5# the few symbols those modules reference but the tests never reach. 5# the few symbols those modules reference but the tests never reach.
6TESTBIN=tests/runner 6TESTBIN=tests/runner
7TEST_SOURCES=tests/runner.c tests/test.c tests/stubs.c tests/t_urlencoded.c tests/t_iovec.c tests/t_vector.c tests/t_random.c tests/t_hex.c tests/t_accesslist.c tests/t_scan.c tests/t_buf.c tests/t_ip.c tests/t_socket.c tests/t_mutex.c tests/t_trackerlogic.c tests/t_workqueue.c tests/t_batch.c tests/t_fdstate.c tests/t_event.c tests/t_fmt.c 7TEST_SOURCES=tests/runner.c tests/test.c tests/stubs.c tests/t_urlencoded.c tests/t_iovec.c tests/t_vector.c tests/t_random.c tests/t_hex.c tests/t_accesslist.c tests/t_scan.c tests/t_buf.c tests/t_ip.c tests/t_socket.c tests/t_mutex.c tests/t_trackerlogic.c tests/t_workqueue.c tests/t_batch.c tests/t_fdstate.c tests/t_event.c tests/t_fmt.c
8TEST_UNITS=ot_urlencoded.c ot_fmt.c ot_event.c ot_batch.c ot_fdstate.c ot_buf.c ot_ip.c ot_socket.c ot_iovec.c ot_vector.c ot_random.c ot_hex.c ot_scan.c ot_accesslist.c ot_mutex.c ot_workqueue.c trackerlogic.c 8TEST_UNITS=src/ot_urlencoded.c src/ot_fmt.c src/ot_event.c src/ot_batch.c src/ot_fdstate.c src/ot_buf.c src/ot_ip.c src/ot_socket.c src/ot_iovec.c src/ot_vector.c src/ot_random.c src/ot_hex.c src/ot_scan.c src/ot_accesslist.c src/ot_mutex.c src/ot_workqueue.c src/trackerlogic.c
9TEST_HEADERS=tests/test.h $(HEADERS) 9TEST_HEADERS=tests/test.h $(HEADERS)
10 10
11# A test binary is not a production binary, so it is built with the features 11# A test binary is not a production binary, so it is built with the features
12# the tests need to reach. 12# the tests need to reach.
13FEATURES_test=$(FEATURES) -DWANT_ACCESSLIST_BLACK -DWANT_SYNC_LIVE 13FEATURES_test=$(FEATURES) -DWANT_ACCESSLIST_BLACK -DWANT_SYNC_LIVE
14CFLAGS_test=-I. -g -O1 $(CPPFLAGS) $(OT_CFLAGS) $(FEATURES_test) 14CFLAGS_test=-Isrc -g -O1 $(CPPFLAGS) $(OT_CFLAGS) $(FEATURES_test)
15 15
16# clang over $(CC) because the two toolchains do not check the same things. 16# clang over $(CC) because the two toolchains do not check the same things.
17CC_sanitize?=clang 17CC_sanitize?=clang
diff --git a/opentracker.c b/src/opentracker.c
index 14b817e..14b817e 100644
--- a/opentracker.c
+++ b/src/opentracker.c
diff --git a/ot_accesslist.c b/src/ot_accesslist.c
index 86f9a7d..86f9a7d 100644
--- a/ot_accesslist.c
+++ b/src/ot_accesslist.c
diff --git a/ot_accesslist.h b/src/ot_accesslist.h
index 68c88dc..68c88dc 100644
--- a/ot_accesslist.h
+++ b/src/ot_accesslist.h
diff --git a/ot_batch.c b/src/ot_batch.c
index e4dda0b..e4dda0b 100644
--- a/ot_batch.c
+++ b/src/ot_batch.c
diff --git a/ot_batch.h b/src/ot_batch.h
index 910bea7..910bea7 100644
--- a/ot_batch.h
+++ b/src/ot_batch.h
diff --git a/ot_buf.c b/src/ot_buf.c
index ecd3f8d..ecd3f8d 100644
--- a/ot_buf.c
+++ b/src/ot_buf.c
diff --git a/ot_buf.h b/src/ot_buf.h
index 7fb944e..7fb944e 100644
--- a/ot_buf.h
+++ b/src/ot_buf.h
diff --git a/ot_clean.c b/src/ot_clean.c
index f181e83..f181e83 100644
--- a/ot_clean.c
+++ b/src/ot_clean.c
diff --git a/ot_clean.h b/src/ot_clean.h
index 0592791..0592791 100644
--- a/ot_clean.h
+++ b/src/ot_clean.h
diff --git a/ot_config.c b/src/ot_config.c
index 95136b5..95136b5 100644
--- a/ot_config.c
+++ b/src/ot_config.c
diff --git a/ot_config.h b/src/ot_config.h
index 79187ee..79187ee 100644
--- a/ot_config.h
+++ b/src/ot_config.h
diff --git a/ot_event.c b/src/ot_event.c
index 6062f70..6062f70 100644
--- a/ot_event.c
+++ b/src/ot_event.c
diff --git a/ot_event.h b/src/ot_event.h
index cb84ca8..cb84ca8 100644
--- a/ot_event.h
+++ b/src/ot_event.h
diff --git a/ot_fdstate.c b/src/ot_fdstate.c
index 8e4bd89..8e4bd89 100644
--- a/ot_fdstate.c
+++ b/src/ot_fdstate.c
diff --git a/ot_fdstate.h b/src/ot_fdstate.h
index 60fe070..60fe070 100644
--- a/ot_fdstate.h
+++ b/src/ot_fdstate.h
diff --git a/ot_fmt.c b/src/ot_fmt.c
index 362c9b5..362c9b5 100644
--- a/ot_fmt.c
+++ b/src/ot_fmt.c
diff --git a/ot_fmt.h b/src/ot_fmt.h
index 214cbc4..214cbc4 100644
--- a/ot_fmt.h
+++ b/src/ot_fmt.h
diff --git a/ot_fullscrape.c b/src/ot_fullscrape.c
index 9afad92..9afad92 100644
--- a/ot_fullscrape.c
+++ b/src/ot_fullscrape.c
diff --git a/ot_fullscrape.h b/src/ot_fullscrape.h
index 8d11cd3..8d11cd3 100644
--- a/ot_fullscrape.h
+++ b/src/ot_fullscrape.h
diff --git a/ot_hex.c b/src/ot_hex.c
index b537094..b537094 100644
--- a/ot_hex.c
+++ b/src/ot_hex.c
diff --git a/ot_hex.h b/src/ot_hex.h
index ddbbb44..ddbbb44 100644
--- a/ot_hex.h
+++ b/src/ot_hex.h
diff --git a/ot_http.c b/src/ot_http.c
index 96b8f4e..96b8f4e 100644
--- a/ot_http.c
+++ b/src/ot_http.c
diff --git a/ot_http.h b/src/ot_http.h
index fb56c64..fb56c64 100644
--- a/ot_http.h
+++ b/src/ot_http.h
diff --git a/ot_iovec.c b/src/ot_iovec.c
index 328f160..328f160 100644
--- a/ot_iovec.c
+++ b/src/ot_iovec.c
diff --git a/ot_iovec.h b/src/ot_iovec.h
index 4a8abbb..4a8abbb 100644
--- a/ot_iovec.h
+++ b/src/ot_iovec.h
diff --git a/ot_ip.c b/src/ot_ip.c
index 9c76290..9c76290 100644
--- a/ot_ip.c
+++ b/src/ot_ip.c
diff --git a/ot_ip.h b/src/ot_ip.h
index 533403e..533403e 100644
--- a/ot_ip.h
+++ b/src/ot_ip.h
diff --git a/ot_livesync.c b/src/ot_livesync.c
index 083fe1a..083fe1a 100644
--- a/ot_livesync.c
+++ b/src/ot_livesync.c
diff --git a/ot_livesync.h b/src/ot_livesync.h
index 4bd3af0..4bd3af0 100644
--- a/ot_livesync.h
+++ b/src/ot_livesync.h
diff --git a/ot_mutex.c b/src/ot_mutex.c
index 884b74c..884b74c 100644
--- a/ot_mutex.c
+++ b/src/ot_mutex.c
diff --git a/ot_mutex.h b/src/ot_mutex.h
index d7ded92..d7ded92 100644
--- a/ot_mutex.h
+++ b/src/ot_mutex.h
diff --git a/ot_random.c b/src/ot_random.c
index 43f91bb..43f91bb 100644
--- a/ot_random.c
+++ b/src/ot_random.c
diff --git a/ot_random.h b/src/ot_random.h
index c2d0387..c2d0387 100644
--- a/ot_random.h
+++ b/src/ot_random.h
diff --git a/ot_rijndael.c b/src/ot_rijndael.c
index 3f36bde..3f36bde 100644
--- a/ot_rijndael.c
+++ b/src/ot_rijndael.c
diff --git a/ot_rijndael.h b/src/ot_rijndael.h
index 1235215..1235215 100644
--- a/ot_rijndael.h
+++ b/src/ot_rijndael.h
diff --git a/ot_scan.c b/src/ot_scan.c
index 3b8e87c..3b8e87c 100644
--- a/ot_scan.c
+++ b/src/ot_scan.c
diff --git a/ot_scan.h b/src/ot_scan.h
index a79ec13..a79ec13 100644
--- a/ot_scan.h
+++ b/src/ot_scan.h
diff --git a/ot_socket.c b/src/ot_socket.c
index 79bb01a..79bb01a 100644
--- a/ot_socket.c
+++ b/src/ot_socket.c
diff --git a/ot_socket.h b/src/ot_socket.h
index 5c1d840..5c1d840 100644
--- a/ot_socket.h
+++ b/src/ot_socket.h
diff --git a/ot_stats.c b/src/ot_stats.c
index 2d6335b..2d6335b 100644
--- a/ot_stats.c
+++ b/src/ot_stats.c
diff --git a/ot_stats.h b/src/ot_stats.h
index 45a547e..45a547e 100644
--- a/ot_stats.h
+++ b/src/ot_stats.h
diff --git a/ot_tcp.c b/src/ot_tcp.c
index 1351b92..1351b92 100644
--- a/ot_tcp.c
+++ b/src/ot_tcp.c
diff --git a/ot_tcp.h b/src/ot_tcp.h
index afed142..afed142 100644
--- a/ot_tcp.h
+++ b/src/ot_tcp.h
diff --git a/ot_udp.c b/src/ot_udp.c
index 644b71d..644b71d 100644
--- a/ot_udp.c
+++ b/src/ot_udp.c
diff --git a/ot_udp.h b/src/ot_udp.h
index 2710744..2710744 100644
--- a/ot_udp.h
+++ b/src/ot_udp.h
diff --git a/ot_urlencoded.c b/src/ot_urlencoded.c
index 4109bb5..4109bb5 100644
--- a/ot_urlencoded.c
+++ b/src/ot_urlencoded.c
diff --git a/ot_urlencoded.h b/src/ot_urlencoded.h
index 9882468..9882468 100644
--- a/ot_urlencoded.h
+++ b/src/ot_urlencoded.h
diff --git a/ot_vector.c b/src/ot_vector.c
index ab0566c..ab0566c 100644
--- a/ot_vector.c
+++ b/src/ot_vector.c
diff --git a/ot_vector.h b/src/ot_vector.h
index 8a5ba86..8a5ba86 100644
--- a/ot_vector.h
+++ b/src/ot_vector.h
diff --git a/ot_worker.c b/src/ot_worker.c
index 432d272..432d272 100644
--- a/ot_worker.c
+++ b/src/ot_worker.c
diff --git a/ot_worker.h b/src/ot_worker.h
index 4954773..4954773 100644
--- a/ot_worker.h
+++ b/src/ot_worker.h
diff --git a/ot_workqueue.c b/src/ot_workqueue.c
index 56a7cd2..56a7cd2 100644
--- a/ot_workqueue.c
+++ b/src/ot_workqueue.c
diff --git a/ot_workqueue.h b/src/ot_workqueue.h
index 82ae29b..82ae29b 100644
--- a/ot_workqueue.h
+++ b/src/ot_workqueue.h
diff --git a/proxy.c b/src/proxy.c
index 8589db5..8589db5 100644
--- a/proxy.c
+++ b/src/proxy.c
diff --git a/trackerlogic.c b/src/trackerlogic.c
index 9565090..9565090 100644
--- a/trackerlogic.c
+++ b/src/trackerlogic.c
diff --git a/trackerlogic.h b/src/trackerlogic.h
index 7292d36..7292d36 100644
--- a/trackerlogic.h
+++ b/src/trackerlogic.h