summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJF Ding <Jian-feng.Ding@intel.com>2011-07-21 06:07:16 +0800
committerJF Ding <Jian-feng.Ding@intel.com>2011-07-21 06:07:16 +0800
commitb49ffc03b01c4bd6429cf795ce3a50f8c5f22cbc (patch)
tree140e5c643e281ae8c4125b353b038ef4abc0d1b7 /Makefile
downloadmic-b49ffc03b01c4bd6429cf795ce3a50f8c5f22cbc.tar.gz
mic-b49ffc03b01c4bd6429cf795ce3a50f8c5f22cbc.tar.bz2
mic-b49ffc03b01c4bd6429cf795ce3a50f8c5f22cbc.zip
initial import code into git
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile35
1 files changed, 35 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..23a4b5c
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,35 @@
+PYTHON ?= python
+VERSION = $(shell cat VERSION)
+TAGVER = $(shell cat VERSION | sed -e "s/\([0-9\.]*\).*/\1/")
+
+PKGNAME = micng
+
+ifeq ($(VERSION), $(TAGVER))
+ TAG = $(TAGVER)
+else
+ TAG = "HEAD"
+endif
+
+
+all:
+ $(PYTHON) setup.py build
+
+dist-bz2:
+ git archive --format=tar --prefix=$(PKGNAME)-$(VERSION)/ $(TAG) | \
+ bzip2 > $(PKGNAME)-$(VERSION).tar.bz2
+
+dist-gz:
+ git archive --format=tar --prefix=$(PKGNAME)-$(VERSION)/ $(TAG) | \
+ gzip > $(PKGNAME)-$(VERSION).tar.gz
+
+install: all
+ $(PYTHON) setup.py install --root=${DESTDIR}
+
+develop: all
+ $(PYTHON) setup.py develop
+
+clean:
+ rm -f tools/*.py[co]
+ rm -rf *.egg-info
+ rm -rf build/
+ rm -rf dist/