]> git.notmuchmail.org Git - notmuch/blob - test/Makefile.local
util: Fix two corner-cases in boolean term quoting function
[notmuch] / test / Makefile.local
1 # -*- makefile -*-
2
3 dir := test
4
5 # save against changes in $(dir)
6 test_src_dir := $(dir)
7 extra_cflags += -I.
8
9 smtp_dummy_srcs =               \
10         $(notmuch_compat_srcs)  \
11         $(dir)/smtp-dummy.c
12
13 smtp_dummy_modules = $(smtp_dummy_srcs:.c=.o)
14
15 $(dir)/arg-test: $(dir)/arg-test.o command-line-arguments.o util/libutil.a
16         $(call quiet,CC) -I. $^ -o $@
17
18 $(dir)/hex-xcode: $(dir)/hex-xcode.o command-line-arguments.o util/libutil.a
19         $(call quiet,CC) -I. $^ -o $@ -ltalloc
20
21 random_corpus_deps =  $(dir)/random-corpus.o  $(dir)/database-test.o \
22                         notmuch-config.o command-line-arguments.o \
23                         lib/libnotmuch.a util/libutil.a \
24                         parse-time-string/libparse-time-string.a
25
26 $(dir)/random-corpus: $(random_corpus_deps)
27         $(call quiet,CXX) $(CFLAGS_FINAL) $^ -o $@ $(CONFIGURE_LDFLAGS)
28
29 $(dir)/smtp-dummy: $(smtp_dummy_modules)
30         $(call quiet,CC) $^ -o $@
31
32 $(dir)/symbol-test: $(dir)/symbol-test.o lib/$(LINKER_NAME)
33         $(call quiet,CXX) $^ -o $@ -Llib -lnotmuch $(XAPIAN_LDFLAGS)
34
35 $(dir)/parse-time: $(dir)/parse-time.o parse-time-string/parse-time-string.o
36         $(call quiet,CC) $^ -o $@
37
38 .PHONY: test check
39
40 TEST_BINARIES=$(dir)/arg-test \
41               $(dir)/hex-xcode \
42               $(dir)/random-corpus \
43               $(dir)/parse-time \
44               $(dir)/smtp-dummy \
45               $(dir)/symbol-test
46
47 test-binaries: $(TEST_BINARIES)
48
49 test:   all test-binaries
50         @${test_src_dir}/notmuch-test $(OPTIONS)
51
52 check: test
53
54 SRCS := $(SRCS) $(smtp_dummy_srcs)
55 CLEAN += $(TEST_BINARIES) $(addsuffix .o,$(TEST_BINARIES)) \
56          $(dir)/database-test.o \
57          $(dir)/corpus.mail $(dir)/test-results $(dir)/tmp.*