]> git.notmuchmail.org Git - notmuch/blobdiff - lib/Makefile.local
build: build parse-time-string as part of the notmuch lib and static cli
[notmuch] / lib / Makefile.local
index be51eaa1d0fa998b77b4c68ddf57f1513f8fd352..62d76b2285c2db163cef79e90433914d69cdae98 100644 (file)
@@ -5,7 +5,7 @@
 # the library interface, (such as the deletion of an API or a major
 # semantic change that breaks formerly functioning code).
 #
-LIBNOTMUCH_VERSION_MAJOR = 2
+LIBNOTMUCH_VERSION_MAJOR = 3
 
 # The minor version of the library interface. This should be incremented at
 # the time of release for any additions to the library interface,
@@ -30,7 +30,10 @@ LIBRARY_SUFFIX = so
 LINKER_NAME = libnotmuch.$(LIBRARY_SUFFIX)
 SONAME = $(LINKER_NAME).$(LIBNOTMUCH_VERSION_MAJOR)
 LIBNAME = $(SONAME).$(LIBNOTMUCH_VERSION_MINOR).$(LIBNOTMUCH_VERSION_RELEASE)
-LIBRARY_LINK_FLAG = -shared -Wl,--version-script=notmuch.sym,-soname=$(SONAME)
+LIBRARY_LINK_FLAG = -shared -Wl,--version-script=notmuch.sym,-soname=$(SONAME) -Wl,--no-undefined
+ifeq ($(PLATFORM),OPENBSD)
+LIBRARY_LINK_FLAG += -lc
+endif
 ifeq ($(LIBDIR_IN_LDCONFIG),1)
 ifeq ($(DESTDIR),)
 LIBRARY_INSTALL_POST_COMMAND=ldconfig
@@ -54,8 +57,7 @@ libnotmuch_c_srcs =           \
        $(dir)/message-file.c   \
        $(dir)/messages.c       \
        $(dir)/sha1.c           \
-       $(dir)/tags.c           \
-       $(dir)/xutil.c
+       $(dir)/tags.c
 
 libnotmuch_cxx_srcs =          \
        $(dir)/database.cc      \
@@ -71,7 +73,7 @@ $(dir)/libnotmuch.a: $(libnotmuch_modules)
        $(call quiet,AR) rcs $@ $^
 
 $(dir)/$(LIBNAME): $(libnotmuch_modules) notmuch.sym
-       $(call quiet,CXX $(CXXFLAGS)) $(libnotmuch_modules) $(FINAL_LIBNOTMUCH_LDFLAGS) $(LIBRARY_LINK_FLAG) -o $@
+       $(call quiet,CXX $(CXXFLAGS)) $(libnotmuch_modules) $(FINAL_LIBNOTMUCH_LDFLAGS) $(LIBRARY_LINK_FLAG) -o $@ util/libutil.a parse-time-string/libparse-time-string.a
 
 notmuch.sym: $(srcdir)/$(dir)/notmuch.h $(libnotmuch_modules)
        sh $(srcdir)/$(lib)/gen-version-script.sh $< $(libnotmuch_modules) > $@