aboutsummaryrefslogtreecommitdiff
path: root/install.sh
diff options
context:
space:
mode:
Diffstat (limited to 'install.sh')
-rwxr-xr-xinstall.sh16
1 files changed, 9 insertions, 7 deletions
diff --git a/install.sh b/install.sh
index 4c16960..55600ac 100755
--- a/install.sh
+++ b/install.sh
@@ -1,6 +1,13 @@
#!/bin/bash
-PREFIX=/usr/local
+echo $@
+if [[ x"$1" = "x--prefix" ]]
+then
+ PREFIX=$2
+else
+ PREFIX=/usr/local
+fi
+
BINDIR=${PREFIX}/bin
DATADIR=${PREFIX}/share
MANDIR=${DATADIR}/man
@@ -9,7 +16,7 @@ DOCDIR=${DATADIR}/doc/dotwm
EXAMPLEDIR=${DOCDIR}/examples
SYSCONFDIR=/etc
CONFIGDIR=${SYSCONFDIR}/xdg/dotwm
-XSESSIONDIR=${DATADIR}/share/xsessions
+XSESSIONDIR=${DATADIR}/xsessions
fail_dependencies() {
cat <<EOF
@@ -34,11 +41,6 @@ _build() {
}
_install() {
- echo $@
- if [[ x"$1" = "x--prefix" ]]
- then
- PREFIX=$2
- fi
echo "Base dir for installation: ${PREFIX}"
install -m 755 target/release/dotwm $BINDIR
install -m 644 dotwm.1 ${MAN1DIR}