summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorRémi Flamary <remi.flamary@gmail.com>2016-10-24 14:18:27 +0200
committerRémi Flamary <remi.flamary@gmail.com>2016-10-24 14:18:27 +0200
commit9c1d808ef2a45393dd1b8d8950411707b04617e7 (patch)
tree099f6c0673c6bffca046dee0f1b7f37e84effe47 /Makefile
parentcfdfd3d4d2791d45cde0bf4512c15039c725bd3e (diff)
add makefile
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile32
1 files changed, 32 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..4345854
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,32 @@
+
+
+PYTHON=python
+
+help :
+ @echo "The following make targets are available:"
+ @echo " help - print this message"
+ @echo " build - build python package"
+ @echo " install - install python package (local user)"
+ @echo " sinstall - install python package (system with sudo)"
+ @echo " remove - remove the package (local user)"
+ @echo " sremove - remove the package (system with sudo)"
+ @echo " clean - remove any temporary files"
+
+build :
+ $(PYTHON) setup.py build
+
+install :
+ $(PYTHON) setup.py install --user
+
+sinstall :
+ sudo $(PYTHON) setup.py install
+
+remove :
+ $(PYTHON) setup.py install --user --record files.txt
+ tr '\n' '\0' < files.txt | xargs -0 rm -f --
+ rm files.txt
+
+sremove :
+ $(PYTHON) setup.py install --record files.txt
+ tr '\n' '\0' < files.txt | sudo xargs -0 rm -f --
+ rm files.txt