sm-discuss AT lists.ibiblio.org
Subject: Public SourceMage Discussion List
List archive
[SM-Discuss] [PATCH] Replace install.sh with a Makefile
- From: Ismael Luceno <ismael AT sourcemage.org>
- To: sm-discuss AT lists.ibiblio.org
- Cc: Ismael Luceno <ismael AT sourcemage.org>
- Subject: [SM-Discuss] [PATCH] Replace install.sh with a Makefile
- Date: Mon, 20 May 2013 21:54:13 +0000
Signed-off-by: Ismael Luceno <ismael AT sourcemage.org>
---
Makefile | 9 +++++++++
install.sh | 24 ------------------------
2 files changed, 9 insertions(+), 24 deletions(-)
create mode 100644 Makefile
delete mode 100755 install.sh
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..20dd205
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,9 @@
+.PHONY: install uninstall
+DIRS = /usr/share/doc/quill /var/lib/quill/modules
+
+install:
+ cp -r usr var $(DESTDIR)/
+
+uninstall:
+ rm $(DESTDIR)/usr/bin/quill
+ rm -r $(DIRS:%=$(DESTDIR)%)
diff --git a/install.sh b/install.sh
deleted file mode 100755
index 4500ed6..0000000
--- a/install.sh
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/bash
-
-if [[ $2 ]] ; then
- INSTALL_ROOT="$2"
-else
- INSTALL_ROOT=""
-fi
-
-if [[ "$1" == "install" ]]; then
- if ! grep -q "\./install.sh$" <<< "$0"; then
- echo "This script must be ran from the quill checkout dir!"
- exit 1
- fi
- mkdir -vp $INSTALL_ROOT/usr/bin
- mkdir -vp $INSTALL_ROOT/usr/share/doc/quill
- mkdir -vp $INSTALL_ROOT/var/lib/quill/modules
- cp -vr usr var $INSTALL_ROOT/
-fi
-
-if [[ "$1" == "uninstall" ]]; then
- rm -v $INSTALL_ROOT/usr/bin/quill
- rm -rv $INSTALL_ROOT/var/lib/quill/
- rm -rv $INSTALL_ROOT/usr/share/doc/quill
-fi
--
1.8.2.3
-
[SM-Discuss] [PATCH v2] Allow specifying source url on command line,
Ismael Luceno, 05/20/2013
- [SM-Discuss] [PATCH] Replace install.sh with a Makefile, Ismael Luceno, 05/20/2013
- Re: [SM-Discuss] [PATCH v2] Allow specifying source url on command line, Jaka Kranjc, 05/25/2013
Archive powered by MHonArc 2.6.24.