Rework of worker threads' start and exit + slight changes in cleanup code
[tor.git] / src / ext / timeouts / Makefile
blob554ebb9ddddcc46c9ed76c8d8d4365ad6f931462
1 # NOTE: GNU Make 3.81 won't export MAKEFLAGS if .POSIX is specified, but
2 # Solaris make won't export MAKEFLAGS unless .POSIX is specified.
3 $(firstword ignore).POSIX:
5 .DEFAULT_GOAL = all
7 .SUFFIXES:
9 all:
12 # USER-MODIFIABLE MACROS
14 top_srcdir = .
15 top_builddir = .
17 CFLAGS = -O2 -march=native -g -Wall -Wextra -Wno-unused-parameter -Wno-unused-function
18 SOFLAGS = $$(auto_soflags)
19 LIBS = $$(auto_libs)
21 ALL_CPPFLAGS = -I$(top_srcdir) -DWHEEL_BIT=$(WHEEL_BIT) -DWHEEL_NUM=$(WHEEL_NUM) $(CPPFLAGS)
22 ALL_CFLAGS = $(CFLAGS)
23 ALL_SOFLAGS = $(SOFLAGS)
24 ALL_LDFLAGS = $(LDFLAGS)
25 ALL_LIBS = $(LIBS)
27 LUA_API = 5.3
28 LUA = lua
29 LUA51_CPPFLAGS = $(LUA_CPPFLAGS)
30 LUA52_CPPFLAGS = $(LUA_CPPFLAGS)
31 LUA53_CPPFLAGS = $(LUA_CPPFLAGS)
33 WHEEL_BIT = 6
34 WHEEL_NUM = 4
36 RM = rm -f
38 # END MACROS
40 SHRC = \
41 top_srcdir="$(top_srcdir)"; \
42 top_builddir="$(top_builddir)"; \
43 . "$${top_srcdir}/Rules.shrc"
45 LUA_APIS = 5.1 5.2 5.3
47 include $(top_srcdir)/lua/Rules.mk
48 include $(top_srcdir)/bench/Rules.mk
50 all: test-timeout
52 timeout.o: $(top_srcdir)/timeout.c
53 test-timeout.o: $(top_srcdir)/test-timeout.c
55 timeout.o test-timeout.o:
56 @$(SHRC); echo_cmd $(CC) $(ALL_CFLAGS) -c -o $@ $${top_srcdir}/$(@F:%.o=%.c) $(ALL_CPPFLAGS)
58 test-timeout: timeout.o test-timeout.o
59 @$(SHRC); echo_cmd $(CC) $(ALL_CPPFLAGS) $(ALL_CFLAGS) -o $@ timeout.o test-timeout.o
61 .PHONY: clean clean~
63 clean:
64 $(RM) $(top_builddir)/test-timeout $(top_builddir)/*.o
65 $(RM) -r $(top_builddir)/*.dSYM
67 clean~:
68 find $(top_builddir) $(top_srcdir) -name "*~" -exec $(RM) -- {} "+"