5 # save against changes in $(dir)
7 extra_cflags += -I$(srcdir)
10 $(notmuch_compat_srcs) \
13 smtp_dummy_modules = $(smtp_dummy_srcs:.c=.o)
15 $(dir)/arg-test: $(dir)/arg-test.o command-line-arguments.o util/libutil.a
16 $(call quiet,CC) $^ -o $@
18 $(dir)/hex-xcode: $(dir)/hex-xcode.o command-line-arguments.o util/libutil.a
19 $(call quiet,CC) $^ -o $@ -ltalloc
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
26 $(dir)/random-corpus: $(random_corpus_deps)
27 $(call quiet,CXX) $(CFLAGS_FINAL) $^ -o $@ $(CONFIGURE_LDFLAGS)
29 $(dir)/smtp-dummy: $(smtp_dummy_modules)
30 $(call quiet,CC) $^ -o $@
32 $(dir)/symbol-test: $(dir)/symbol-test.o lib/$(LINKER_NAME)
33 $(call quiet,CXX) $^ -o $@ -Llib -lnotmuch $(XAPIAN_LDFLAGS)
35 $(dir)/parse-time: $(dir)/parse-time.o parse-time-string/parse-time-string.o
36 $(call quiet,CC) $^ -o $@
38 $(dir)/have-compact: Makefile.config
39 ifeq ($(HAVE_XAPIAN_COMPACT),1)
45 $(dir)/have-man: Makefile.config
46 ifeq ($(HAVE_SPHINX)$(HAVE_RST2MAN),00)
54 TEST_BINARIES=$(dir)/arg-test \
58 $(dir)/random-corpus \
63 test-binaries: $(TEST_BINARIES)
65 test: all test-binaries
66 @${test_src_dir}/notmuch-test $(OPTIONS)
70 SRCS := $(SRCS) $(smtp_dummy_srcs)
71 CLEAN += $(TEST_BINARIES) $(addsuffix .o,$(TEST_BINARIES)) \
72 $(dir)/database-test.o \
73 $(dir)/corpus.mail $(dir)/test-results $(dir)/tmp.*