From 9c1d808ef2a45393dd1b8d8950411707b04617e7 Mon Sep 17 00:00:00 2001 From: RĂ©mi Flamary Date: Mon, 24 Oct 2016 14:18:27 +0200 Subject: add makefile --- Makefile | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 Makefile (limited to 'Makefile') 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 -- cgit v1.2.3