summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJF Ding <jian-feng.ding@intel.com>2011-10-27 17:16:35 +0800
committerJF Ding <jian-feng.ding@intel.com>2011-10-27 17:20:13 +0800
commit3f06af2c4a7bd7e36863cf28f079cbc326b32d1e (patch)
treed02dc382dfa82a10caf2b2c0ecc95396284f1c26
parentb646615d5133375d319ed1bcd5063632c9696922 (diff)
downloadmic-3f06af2c4a7bd7e36863cf28f079cbc326b32d1e.tar.gz
mic-3f06af2c4a7bd7e36863cf28f079cbc326b32d1e.tar.bz2
mic-3f06af2c4a7bd7e36863cf28f079cbc326b32d1e.zip
Makefile: update manpage automatically
-rw-r--r--Makefile9
1 files changed, 8 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index e3e5292..81659ab 100644
--- a/Makefile
+++ b/Makefile
@@ -17,9 +17,10 @@ endif
all:
$(PYTHON) setup.py build
-dist-common:
+dist-common: man
git archive --format=tar --prefix=$(PKGNAME)-$(TAGVER)/ $(TAG) | tar xpf -
git show $(TAG) --oneline | head -1 > $(PKGNAME)-$(TAGVER)/commit-id
+ mkdir $(PKGNAME)-$(TAGVER)/doc; mv mic.1 $(PKGNAME)-$(TAGVER)/doc
dist-bz2: dist-common
tar jcpf $(PKGNAME)-$(TAGVER).tar.bz2 $(PKGNAME)-$(TAGVER)
@@ -29,6 +30,9 @@ dist-gz: dist-common
tar zcpf $(PKGNAME)-$(TAGVER).tar.gz $(PKGNAME)-$(TAGVER)
rm -rf $(PKGNAME)-$(TAGVER)
+man: README.rst
+ rst2man $< >mic.1
+
install: all
$(PYTHON) setup.py install --prefix=$(DESTDIR)/$(PREFIX)
@@ -36,7 +40,10 @@ develop: all
$(PYTHON) setup.py develop
clean:
+ rm -f *.tar.gz
+ rm -f *.tar.bz2
rm -f tools/*.py[co]
+ rm -f mic.1
rm -rf *.egg-info
rm -rf build/
rm -rf dist/