2010-03-21 10:54:08 +01:00
|
|
|
# -*- makefile -*-
|
|
|
|
|
2010-04-02 20:55:09 +02:00
|
|
|
# Here's the (hopefully simple) versioning scheme.
|
|
|
|
#
|
|
|
|
# Releases of notmuch have a two-digit version (0.1, 0.2, etc.). We
|
|
|
|
# increment the second digit for each release and increment the first
|
|
|
|
# digit when we reach particularly major milestones of usability.
|
|
|
|
#
|
|
|
|
# Between releases, (such as when compiling notmuch from the git
|
2010-04-16 01:17:32 +02:00
|
|
|
# repository), we let git append identification of the actual commit.
|
2010-04-06 00:43:51 +02:00
|
|
|
PACKAGE=notmuch
|
2010-04-16 19:37:32 +02:00
|
|
|
|
2010-04-16 20:24:43 +02:00
|
|
|
IS_GIT=$(shell if [ -d .git ] ; then echo yes ; else echo no; fi)
|
|
|
|
|
2011-11-18 03:26:25 +01:00
|
|
|
ifeq ($(IS_GIT),yes)
|
|
|
|
DATE:=$(shell git log --date=short -1 --pretty=format:%cd)
|
|
|
|
else
|
|
|
|
DATE:=$(shell date +%F)
|
|
|
|
endif
|
|
|
|
|
2011-03-10 00:02:42 +01:00
|
|
|
VERSION:=$(shell cat ${srcdir}/version)
|
2011-11-18 03:26:25 +01:00
|
|
|
ifeq ($(filter release release-message pre-release update-versions,$(MAKECMDGOALS)),)
|
2010-04-16 20:24:43 +02:00
|
|
|
ifeq ($(IS_GIT),yes)
|
2011-11-17 17:40:50 +01:00
|
|
|
VERSION:=$(shell git describe --match '[0-9.]*'|sed -e s/_/~/ -e s/-/+/ -e s/-/~/)
|
2010-04-16 20:24:43 +02:00
|
|
|
endif
|
2010-04-16 19:37:32 +02:00
|
|
|
endif
|
2011-07-29 17:45:12 +02:00
|
|
|
|
|
|
|
UPSTREAM_TAG=$(subst ~,_,$(VERSION))
|
|
|
|
DEB_TAG=debian/$(UPSTREAM_TAG)-1
|
2010-04-02 20:55:09 +02:00
|
|
|
|
2010-04-06 00:26:08 +02:00
|
|
|
RELEASE_HOST=notmuchmail.org
|
|
|
|
RELEASE_DIR=/srv/notmuchmail.org/www/releases
|
2010-04-06 01:37:44 +02:00
|
|
|
RELEASE_URL=http://notmuchmail.org/releases
|
2010-04-06 00:43:51 +02:00
|
|
|
TAR_FILE=$(PACKAGE)-$(VERSION).tar.gz
|
2011-07-17 14:55:50 +02:00
|
|
|
DEB_TAR_FILE=$(PACKAGE)_$(VERSION).orig.tar.gz
|
2010-04-06 00:43:51 +02:00
|
|
|
SHA1_FILE=$(TAR_FILE).sha1
|
|
|
|
GPG_FILE=$(SHA1_FILE).asc
|
2010-04-02 20:55:09 +02:00
|
|
|
|
2011-09-05 13:45:28 +02:00
|
|
|
PV_FILE=bindings/python/notmuch/version.py
|
|
|
|
|
2010-04-01 07:12:01 +02:00
|
|
|
# Smash together user's values with our extra values
|
2013-10-15 09:30:45 +02:00
|
|
|
FINAL_CFLAGS = -DNOTMUCH_VERSION=$(VERSION) $(CPPFLAGS) $(CFLAGS) $(WARN_CFLAGS) $(extra_cflags) $(CONFIGURE_CFLAGS)
|
|
|
|
FINAL_CXXFLAGS = $(CPPFLAGS) $(CXXFLAGS) $(WARN_CXXFLAGS) $(extra_cflags) $(extra_cxxflags) $(CONFIGURE_CXXFLAGS)
|
2011-10-23 17:05:13 +02:00
|
|
|
FINAL_NOTMUCH_LDFLAGS = $(LDFLAGS) -Lutil -lutil -Llib -lnotmuch $(AS_NEEDED_LDFLAGS) $(GMIME_LDFLAGS) $(TALLOC_LDFLAGS)
|
2010-04-16 20:51:56 +02:00
|
|
|
FINAL_NOTMUCH_LINKER = CC
|
2010-10-30 22:20:33 +02:00
|
|
|
ifneq ($(LINKER_RESOLVES_LIBRARY_DEPENDENCIES),1)
|
2010-04-15 01:29:50 +02:00
|
|
|
FINAL_NOTMUCH_LDFLAGS += $(CONFIGURE_LDFLAGS)
|
2010-04-16 20:51:56 +02:00
|
|
|
FINAL_NOTMUCH_LINKER = CXX
|
2010-04-15 01:29:50 +02:00
|
|
|
endif
|
2010-06-05 01:52:56 +02:00
|
|
|
ifeq ($(LIBDIR_IN_LDCONFIG),0)
|
2010-10-30 21:55:09 +02:00
|
|
|
FINAL_NOTMUCH_LDFLAGS += $(RPATH_LDFLAGS)
|
2010-06-05 01:52:56 +02:00
|
|
|
endif
|
2010-11-02 07:17:48 +01:00
|
|
|
FINAL_LIBNOTMUCH_LDFLAGS = $(LDFLAGS) $(AS_NEEDED_LDFLAGS) $(CONFIGURE_LDFLAGS)
|
2010-04-01 07:12:01 +02:00
|
|
|
|
2010-04-05 21:59:06 +02:00
|
|
|
.PHONY: all
|
2011-12-20 21:35:13 +01:00
|
|
|
all: notmuch notmuch-shared
|
2010-04-01 07:12:01 +02:00
|
|
|
ifeq ($(MAKECMDGOALS),)
|
2010-04-16 21:10:23 +02:00
|
|
|
ifeq ($(shell cat .first-build-message 2>/dev/null),)
|
2010-04-02 23:06:32 +02:00
|
|
|
@NOTMUCH_FIRST_BUILD=1 $(MAKE) --no-print-directory all
|
2010-04-01 07:12:01 +02:00
|
|
|
@echo ""
|
|
|
|
@echo "Compilation of notmuch is now complete. You can install notmuch with:"
|
|
|
|
@echo ""
|
|
|
|
@echo " make install"
|
|
|
|
@echo ""
|
|
|
|
@echo "Note that depending on the prefix to which you are installing"
|
|
|
|
@echo "you may need root permission (such as \"sudo make install\")."
|
|
|
|
@echo "See \"./configure --help\" for help on setting an alternate prefix."
|
2010-04-02 23:06:32 +02:00
|
|
|
@echo Printed > .first-build-message
|
|
|
|
endif
|
2010-04-01 07:12:01 +02:00
|
|
|
endif
|
|
|
|
|
2010-04-06 00:43:51 +02:00
|
|
|
$(TAR_FILE):
|
2011-07-03 22:28:47 +02:00
|
|
|
if git tag -v $(VERSION) >/dev/null 2>&1; then \
|
|
|
|
ref=$(VERSION); \
|
|
|
|
else \
|
|
|
|
ref="HEAD" ; \
|
|
|
|
echo "Warning: No signed tag for $(VERSION)"; \
|
|
|
|
fi ; \
|
|
|
|
git archive --format=tar --prefix=$(PACKAGE)-$(VERSION)/ $$ref > $(TAR_FILE).tmp
|
2010-04-16 19:37:32 +02:00
|
|
|
echo $(VERSION) > version.tmp
|
|
|
|
tar --append -f $(TAR_FILE).tmp --transform s_^_$(PACKAGE)-$(VERSION)/_ --transform 's_.tmp$$__' version.tmp
|
|
|
|
rm version.tmp
|
2010-04-08 13:49:22 +02:00
|
|
|
gzip < $(TAR_FILE).tmp > $(TAR_FILE)
|
2010-04-16 20:24:43 +02:00
|
|
|
@echo "Source is ready for release in $(TAR_FILE)"
|
2010-04-06 00:26:08 +02:00
|
|
|
|
2010-04-06 00:43:51 +02:00
|
|
|
$(SHA1_FILE): $(TAR_FILE)
|
|
|
|
sha1sum $^ > $@
|
|
|
|
|
|
|
|
$(GPG_FILE): $(SHA1_FILE)
|
|
|
|
@echo "Please enter your GPG password to sign the checksum."
|
|
|
|
gpg --armor --sign $^
|
|
|
|
|
2010-04-05 23:22:00 +02:00
|
|
|
.PHONY: dist
|
2010-04-06 00:43:51 +02:00
|
|
|
dist: $(TAR_FILE)
|
|
|
|
|
2011-11-18 03:26:25 +01:00
|
|
|
.PHONY: update-versions
|
|
|
|
|
2011-12-20 21:35:13 +01:00
|
|
|
update-versions: update-man-versions
|
2011-11-18 03:26:25 +01:00
|
|
|
sed -i "s/^__VERSION__[[:blank:]]*=.*$$/__VERSION__ = \'${VERSION}\'/" $(PV_FILE)
|
|
|
|
|
2010-04-06 01:37:44 +02:00
|
|
|
# We invoke make recursively only to force ordering of our phony
|
|
|
|
# targets in the case of parallel invocation of make (-j).
|
2010-04-16 19:37:32 +02:00
|
|
|
#
|
|
|
|
# We carefully ensure that our VERSION variable is passed down to any
|
2011-03-10 00:02:42 +01:00
|
|
|
# sub-ordinate make invocations (which won't otherwise know that they
|
2010-04-16 19:37:32 +02:00
|
|
|
# are part of the release and need to take the version from the
|
|
|
|
# version file).
|
2010-04-06 00:26:08 +02:00
|
|
|
.PHONY: release
|
2010-04-16 22:00:35 +02:00
|
|
|
release: verify-source-tree-and-version
|
2010-04-16 20:03:25 +02:00
|
|
|
$(MAKE) VERSION=$(VERSION) verify-newer
|
2011-07-17 14:52:05 +02:00
|
|
|
$(MAKE) VERSION=$(VERSION) clean
|
2010-04-16 19:37:32 +02:00
|
|
|
$(MAKE) VERSION=$(VERSION) test
|
2011-07-29 17:45:12 +02:00
|
|
|
git tag -s -m "$(PACKAGE) $(VERSION) release" $(UPSTREAM_TAG)
|
2010-04-16 19:37:32 +02:00
|
|
|
$(MAKE) VERSION=$(VERSION) $(GPG_FILE)
|
2011-07-17 14:55:50 +02:00
|
|
|
ln -sf $(TAR_FILE) $(DEB_TAR_FILE)
|
2011-07-29 17:45:12 +02:00
|
|
|
pristine-tar commit $(DEB_TAR_FILE) $(UPSTREAM_TAG)
|
|
|
|
git tag -s -m "$(PACKAGE) Debian $(VERSION)-1 upload (same as $(VERSION))" $(DEB_TAG)
|
2010-04-16 01:28:13 +02:00
|
|
|
mkdir -p releases
|
|
|
|
mv $(TAR_FILE) $(SHA1_FILE) $(GPG_FILE) releases
|
2010-04-16 19:37:32 +02:00
|
|
|
$(MAKE) VERSION=$(VERSION) release-message > $(PACKAGE)-$(VERSION).announce
|
2011-07-04 13:39:04 +02:00
|
|
|
ifeq ($(REALLY_UPLOAD),yes)
|
|
|
|
git push origin $(VERSION)
|
|
|
|
cd releases && scp $(TAR_FILE) $(SHA1_FILE) $(GPG_FILE) $(RELEASE_HOST):$(RELEASE_DIR)
|
2011-12-05 12:39:32 +01:00
|
|
|
ssh $(RELEASE_HOST) "rm -f $(RELEASE_DIR)/LATEST-$(PACKAGE)-* ; ln -s $(TAR_FILE) $(RELEASE_DIR)/LATEST-$(TAR_FILE)"
|
2011-07-04 13:39:04 +02:00
|
|
|
endif
|
2010-04-16 17:33:31 +02:00
|
|
|
@echo "Please send a release announcement using $(PACKAGE)-$(VERSION).announce as a template."
|
2010-04-06 00:26:08 +02:00
|
|
|
|
2011-07-29 17:45:12 +02:00
|
|
|
.PHONY: pre-release
|
|
|
|
pre-release:
|
|
|
|
$(MAKE) VERSION=$(VERSION) clean
|
|
|
|
$(MAKE) VERSION=$(VERSION) test
|
|
|
|
git tag -s -m "$(PACKAGE) $(VERSION) release" $(UPSTREAM_TAG)
|
|
|
|
git tag -s -m "$(PACKAGE) Debian $(VERSION)-1 upload (same as $(VERSION))" $(DEB_TAG)
|
|
|
|
$(MAKE) VERSION=$(VERSION) $(TAR_FILE)
|
|
|
|
ln -sf $(TAR_FILE) $(DEB_TAR_FILE)
|
|
|
|
pristine-tar commit $(DEB_TAR_FILE) $(UPSTREAM_TAG)
|
|
|
|
mkdir -p releases
|
|
|
|
mv $(TAR_FILE) $(DEB_TAR_FILE) releases
|
|
|
|
|
2011-10-13 03:23:33 +02:00
|
|
|
.PHONY: debian-snapshot
|
|
|
|
debian-snapshot:
|
|
|
|
make VERSION=$(VERSION) clean
|
2011-12-18 04:16:51 +01:00
|
|
|
TMPFILE=$$(mktemp /tmp/notmuch.XXXXXX); \
|
|
|
|
cp debian/changelog $${TMPFILE}; \
|
|
|
|
EDITOR=/bin/true dch -b -v $(VERSION)+1 \
|
|
|
|
-D UNRELEASED 'test build, not for upload'; \
|
|
|
|
echo '3.0 (native)' > debian/source/format; \
|
|
|
|
debuild -us -uc; \
|
|
|
|
mv -f $${TMPFILE} debian/changelog; \
|
|
|
|
echo '3.0 (quilt)' > debian/source/format
|
2011-10-13 03:23:33 +02:00
|
|
|
|
2010-04-06 01:37:44 +02:00
|
|
|
.PHONY: release-message
|
|
|
|
release-message:
|
|
|
|
@echo "To: notmuch@notmuchmail.org"
|
|
|
|
@echo "Subject: $(PACKAGE) release $(VERSION) now available"
|
|
|
|
@echo ""
|
2010-04-06 02:24:20 +02:00
|
|
|
@echo "Where to obtain notmuch $(VERSION)"
|
2010-04-06 01:37:44 +02:00
|
|
|
@echo "==========================="
|
|
|
|
@echo " $(RELEASE_URL)/$(TAR_FILE)"
|
|
|
|
@echo ""
|
|
|
|
@echo "Which can be verified with:"
|
|
|
|
@echo ""
|
|
|
|
@echo " $(RELEASE_URL)/$(SHA1_FILE)"
|
|
|
|
@echo -n " "
|
|
|
|
@cat releases/$(SHA1_FILE)
|
|
|
|
@echo ""
|
|
|
|
@echo " $(RELEASE_URL)/$(GPG_FILE)"
|
|
|
|
@echo " (signed by `getent passwd "$$USER" | cut -d: -f 5 | cut -d, -f 1`)"
|
2010-04-06 02:24:20 +02:00
|
|
|
@echo ""
|
|
|
|
@echo "What's new in notmuch $(VERSION)"
|
|
|
|
@echo "========================="
|
2010-04-16 17:31:46 +02:00
|
|
|
@sed -ne '/^[Nn]otmuch $(VERSION)/{n;n;b NEWS}; d; :NEWS /^===/q; {p;n;b NEWS}' < NEWS | head -n -2
|
2010-04-06 02:24:20 +02:00
|
|
|
@echo ""
|
|
|
|
@echo "What is notmuch"
|
|
|
|
@echo "==============="
|
|
|
|
@echo "Notmuch is a system for indexing, searching, reading, and tagging"
|
|
|
|
@echo "large collections of email messages in maildir or mh format. It uses"
|
|
|
|
@echo "the Xapian library to provide fast, full-text search with a convenient"
|
|
|
|
@echo "search syntax."
|
|
|
|
@echo ""
|
|
|
|
@echo "For more about notmuch, see http://notmuchmail.org"
|
|
|
|
|
2010-04-16 22:00:35 +02:00
|
|
|
# This is a chain of dependencies rather than a simple list simply to
|
|
|
|
# avoid the messages getting interleaved in the case of a parallel
|
|
|
|
# make invocation.
|
|
|
|
.PHONY: verify-source-tree-and-version
|
|
|
|
verify-source-tree-and-version: verify-no-dirty-code
|
|
|
|
|
2010-04-16 05:03:30 +02:00
|
|
|
.PHONY: verify-no-dirty-code
|
2012-09-04 16:49:13 +02:00
|
|
|
verify-no-dirty-code: release-checks
|
2010-04-16 20:24:43 +02:00
|
|
|
ifeq ($(IS_GIT),yes)
|
2010-04-16 05:03:30 +02:00
|
|
|
@printf "Checking that source tree is clean..."
|
|
|
|
ifneq ($(shell git ls-files -m),)
|
|
|
|
@echo "No"
|
|
|
|
@echo "The following files have been modified since the most recent git commit:"
|
|
|
|
@echo ""
|
|
|
|
@git ls-files -m
|
|
|
|
@echo ""
|
|
|
|
@echo "The release will be made from the committed state, but perhaps you meant"
|
|
|
|
@echo "to commit this code first? Please clean this up to make it more clear."
|
|
|
|
@false
|
|
|
|
else
|
|
|
|
@echo "Good"
|
|
|
|
endif
|
2010-04-16 20:24:43 +02:00
|
|
|
endif
|
2010-04-06 01:37:44 +02:00
|
|
|
|
2012-09-04 16:49:13 +02:00
|
|
|
.PHONY: release-checks
|
|
|
|
release-checks:
|
|
|
|
devel/release-checks.sh
|
2010-04-06 00:26:08 +02:00
|
|
|
|
2010-04-16 01:23:57 +02:00
|
|
|
.PHONY: verify-newer
|
2010-04-16 01:28:13 +02:00
|
|
|
verify-newer:
|
2010-04-06 00:43:51 +02:00
|
|
|
@echo -n "Checking that no $(VERSION) release already exists..."
|
2011-07-03 20:18:30 +02:00
|
|
|
@wget -q -O /dev/null $(RELEASE_URL)/$(TAR_FILE) ; \
|
|
|
|
case $$? in \
|
|
|
|
8) echo "Good." ;; \
|
|
|
|
0) echo "Ouch."; \
|
|
|
|
echo "Found: $(RELEASE_URL)/$(TAR_FILE)"; \
|
|
|
|
echo "Refusing to replace an existing release."; \
|
|
|
|
echo "Don't forget to update \"version\" as described in RELEASING before release." ; \
|
|
|
|
false ;; \
|
|
|
|
*) echo "An unexpected error occured"; \
|
|
|
|
false;; esac
|
2010-04-05 23:22:00 +02:00
|
|
|
|
2010-04-01 07:12:01 +02:00
|
|
|
# The user has not set any verbosity, default to quiet mode and inform the
|
|
|
|
# user how to enable verbose compiles.
|
|
|
|
ifeq ($(V),)
|
|
|
|
quiet_DOC := "Use \"$(MAKE) V=1\" to see the verbose compile lines.\n"
|
2010-04-06 19:00:30 +02:00
|
|
|
quiet = @printf $(quiet_DOC)$(eval quiet_DOC:=)"$1 $@\n"; $($(shell echo $1 | sed -e s'/ .*//'))
|
2010-04-01 07:12:01 +02:00
|
|
|
endif
|
|
|
|
# The user has explicitly enabled quiet compilation.
|
|
|
|
ifeq ($(V),0)
|
2010-04-06 19:00:30 +02:00
|
|
|
quiet = @printf "$1 $@\n"; $($(shell echo $1 | sed -e s'/ .*//'))
|
2010-04-01 07:12:01 +02:00
|
|
|
endif
|
|
|
|
# Otherwise, print the full command line.
|
2010-04-06 19:00:30 +02:00
|
|
|
quiet ?= $($(shell echo $1 | sed -e s'/ .*//'))
|
2010-04-01 07:12:01 +02:00
|
|
|
|
|
|
|
%.o: %.cc $(global_deps)
|
2013-11-03 15:05:35 +01:00
|
|
|
@mkdir -p $(patsubst %/.,%,.deps/$(@D))
|
2013-05-26 03:28:13 +02:00
|
|
|
$(call quiet,CXX $(CPPFLAGS) $(CXXFLAGS)) -c $(FINAL_CXXFLAGS) $< -o $@ -MD -MP -MF .deps/$*.d
|
2010-04-01 07:12:01 +02:00
|
|
|
|
|
|
|
%.o: %.c $(global_deps)
|
2013-11-03 15:05:35 +01:00
|
|
|
@mkdir -p $(patsubst %/.,%,.deps/$(@D))
|
2013-05-26 03:28:13 +02:00
|
|
|
$(call quiet,CC $(CPPFLAGS) $(CFLAGS)) -c $(FINAL_CFLAGS) $< -o $@ -MD -MP -MF .deps/$*.d
|
2010-04-01 07:12:01 +02:00
|
|
|
|
|
|
|
.PHONY : clean
|
|
|
|
clean:
|
2012-08-02 14:27:26 +02:00
|
|
|
rm -rf $(CLEAN); rm -rf .deps
|
2010-04-01 07:12:01 +02:00
|
|
|
|
2010-04-06 23:18:05 +02:00
|
|
|
.PHONY: distclean
|
|
|
|
distclean: clean
|
2012-08-02 14:30:31 +02:00
|
|
|
rm -rf $(DISTCLEAN)
|
2010-04-06 23:18:05 +02:00
|
|
|
|
2009-11-10 21:03:05 +01:00
|
|
|
notmuch_client_srcs = \
|
2011-12-01 01:27:26 +01:00
|
|
|
command-line-arguments.c\
|
2009-11-22 01:44:31 +01:00
|
|
|
debugger.c \
|
|
|
|
gmime-filter-reply.c \
|
2011-12-08 23:48:29 +01:00
|
|
|
hooks.c \
|
2009-11-10 21:03:05 +01:00
|
|
|
notmuch.c \
|
2013-10-02 22:30:47 +02:00
|
|
|
notmuch-compact.c \
|
2009-11-12 02:01:55 +01:00
|
|
|
notmuch-config.c \
|
2009-11-21 08:15:07 +01:00
|
|
|
notmuch-count.c \
|
2009-11-10 21:03:05 +01:00
|
|
|
notmuch-dump.c \
|
2013-06-23 14:20:45 +02:00
|
|
|
notmuch-insert.c \
|
2009-11-10 21:03:05 +01:00
|
|
|
notmuch-new.c \
|
2009-11-06 19:00:38 +01:00
|
|
|
notmuch-reply.c \
|
2009-11-10 21:03:05 +01:00
|
|
|
notmuch-restore.c \
|
|
|
|
notmuch-search.c \
|
|
|
|
notmuch-setup.c \
|
|
|
|
notmuch-show.c \
|
|
|
|
notmuch-tag.c \
|
|
|
|
notmuch-time.c \
|
2012-07-23 12:39:45 +02:00
|
|
|
sprinter-json.c \
|
2012-12-06 22:12:11 +01:00
|
|
|
sprinter-sexp.c \
|
2012-07-23 12:39:45 +02:00
|
|
|
sprinter-text.c \
|
2009-11-06 19:00:38 +01:00
|
|
|
query-string.c \
|
2011-12-24 19:52:44 +01:00
|
|
|
mime-node.c \
|
2012-05-26 20:45:41 +02:00
|
|
|
crypto.c \
|
2012-11-13 02:54:16 +01:00
|
|
|
tag-util.c
|
2009-11-10 21:03:05 +01:00
|
|
|
|
|
|
|
notmuch_client_modules = $(notmuch_client_srcs:.c=.o)
|
2010-04-02 00:03:40 +02:00
|
|
|
|
2012-10-30 21:32:36 +01:00
|
|
|
notmuch: $(notmuch_client_modules) lib/libnotmuch.a util/libutil.a parse-time-string/libparse-time-string.a
|
2010-04-12 01:44:51 +02:00
|
|
|
$(call quiet,CXX $(CFLAGS)) $^ $(FINAL_LIBNOTMUCH_LDFLAGS) -o $@
|
2010-04-02 00:03:40 +02:00
|
|
|
|
2010-04-12 01:44:53 +02:00
|
|
|
notmuch-shared: $(notmuch_client_modules) lib/$(LINKER_NAME)
|
2010-04-16 20:51:56 +02:00
|
|
|
$(call quiet,$(FINAL_NOTMUCH_LINKER) $(CFLAGS)) $(notmuch_client_modules) $(FINAL_NOTMUCH_LDFLAGS) -o $@
|
2009-11-10 16:14:49 +01:00
|
|
|
|
2010-04-05 21:59:06 +02:00
|
|
|
.PHONY: install
|
2011-12-20 21:35:13 +01:00
|
|
|
install: all install-man
|
2011-01-26 14:29:15 +01:00
|
|
|
mkdir -p "$(DESTDIR)$(prefix)/bin/"
|
|
|
|
install notmuch-shared "$(DESTDIR)$(prefix)/bin/notmuch"
|
2010-03-10 19:48:47 +01:00
|
|
|
ifeq ($(MAKECMDGOALS), install)
|
2010-03-10 19:07:34 +01:00
|
|
|
@echo ""
|
2010-04-06 19:35:20 +02:00
|
|
|
@echo "Notmuch is now installed to $(DESTDIR)$(prefix)"
|
2010-03-10 19:07:34 +01:00
|
|
|
@echo ""
|
2010-06-01 19:46:52 +02:00
|
|
|
@echo "New users should simply run \"notmuch\" to be guided"
|
|
|
|
@echo "through the process of configuring notmuch and creating"
|
|
|
|
@echo "a database of existing email messages. The \"notmuch\""
|
|
|
|
@echo "command will also offer some sample search commands."
|
2011-01-23 14:33:43 +01:00
|
|
|
ifeq ($(WITH_EMACS), 1)
|
2010-06-01 19:46:52 +02:00
|
|
|
@echo ""
|
|
|
|
@echo "Beyond the command-line interface, notmuch also offers"
|
|
|
|
@echo "a full-featured interface for reading and writing mail"
|
|
|
|
@echo "within emacs. To use this, each user should add the"
|
|
|
|
@echo "following line to the ~/.emacs file:"
|
2010-03-10 19:07:34 +01:00
|
|
|
@echo ""
|
2010-04-06 19:35:20 +02:00
|
|
|
@echo " (require 'notmuch)"
|
2010-03-10 19:48:47 +01:00
|
|
|
@echo ""
|
2010-06-01 19:46:52 +02:00
|
|
|
@echo "And then run emacs as \"emacs -f notmuch\" or invoke"
|
|
|
|
@echo "the command \"M-x notmuch\" from within emacs."
|
2010-03-10 19:48:47 +01:00
|
|
|
endif
|
2011-01-23 14:33:43 +01:00
|
|
|
endif
|
2009-11-10 16:14:49 +01:00
|
|
|
|
2010-04-05 21:59:06 +02:00
|
|
|
.PHONY: install-desktop
|
2009-11-22 22:17:11 +01:00
|
|
|
install-desktop:
|
2011-01-26 14:29:15 +01:00
|
|
|
mkdir -p "$(DESTDIR)$(desktop_dir)"
|
|
|
|
desktop-file-install --mode 0644 --dir "$(DESTDIR)$(desktop_dir)" notmuch.desktop
|
2009-11-22 22:17:11 +01:00
|
|
|
|
2009-11-10 21:03:05 +01:00
|
|
|
SRCS := $(SRCS) $(notmuch_client_srcs)
|
2011-12-20 21:35:13 +01:00
|
|
|
CLEAN := $(CLEAN) notmuch notmuch-shared $(notmuch_client_modules) notmuch.elc
|
2012-01-15 21:20:23 +01:00
|
|
|
|
2012-08-02 14:30:31 +02:00
|
|
|
DISTCLEAN := $(DISTCLEAN) .first-build-message Makefile.config
|
|
|
|
|
2012-01-15 21:20:23 +01:00
|
|
|
DEPS := $(SRCS:%.c=.deps/%.d)
|
|
|
|
DEPS := $(DEPS:%.cc=.deps/%.d)
|
|
|
|
-include $(DEPS)
|