2010-03-10 19:59:57 +01:00
|
|
|
dir := lib
|
2010-03-12 14:47:34 +01:00
|
|
|
extra_cflags += -I$(dir) -fPIC
|
2009-11-10 16:14:49 +01:00
|
|
|
|
2009-11-10 17:04:54 +01:00
|
|
|
libnotmuch_c_srcs = \
|
|
|
|
$(dir)/libsha1.c \
|
|
|
|
$(dir)/message-file.c \
|
2009-11-15 08:05:17 +01:00
|
|
|
$(dir)/messages.c \
|
2009-11-10 17:04:54 +01:00
|
|
|
$(dir)/sha1.c \
|
|
|
|
$(dir)/tags.c \
|
|
|
|
$(dir)/xutil.c
|
2009-11-10 16:14:49 +01:00
|
|
|
|
2009-11-10 17:04:54 +01:00
|
|
|
libnotmuch_cxx_srcs = \
|
|
|
|
$(dir)/database.cc \
|
2010-01-05 22:29:23 +01:00
|
|
|
$(dir)/directory.cc \
|
2009-11-10 17:04:54 +01:00
|
|
|
$(dir)/index.cc \
|
|
|
|
$(dir)/message.cc \
|
|
|
|
$(dir)/query.cc \
|
|
|
|
$(dir)/thread.cc
|
|
|
|
|
|
|
|
libnotmuch_modules = $(libnotmuch_c_srcs:.c=.o) $(libnotmuch_cxx_srcs:.cc=.o)
|
2010-03-12 14:47:34 +01:00
|
|
|
$(dir)/libnotmuch.so : $(libnotmuch_modules)
|
|
|
|
$(call quiet,CXX,$(LDFLAGS)) $^ $(FINAL_LDFLAGS) -shared -Wl,-soname=$(SONAME) -o $@
|
|
|
|
ln -sf $(SONAME) $@
|
2009-11-10 16:14:49 +01:00
|
|
|
|
2009-11-10 17:04:54 +01:00
|
|
|
SRCS := $(SRCS) $(libnotmuch_c_srcs) $(libnotmuch_cxx_srcs)
|
2010-03-12 14:47:34 +01:00
|
|
|
CLEAN := $(CLEAN) $(libnotmuch_modules) $(dir)/libnotmuch.so *.so
|