aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorLibravatar Leandro Ramos <leandroramos@disroot.org>2022-02-07 17:23:10 -0300
committerLibravatar Leandro Ramos <leandroramos@disroot.org>2022-02-07 17:23:10 -0300
commit6f8741acd10ce1a1c85884ecdc0fd32f7f3ba330 (patch)
tree688e8e07cde3033076843f7c665fc40bf494cef8 /configure
downloadxfce4-panel-profiles-6f8741acd10ce1a1c85884ecdc0fd32f7f3ba330.tar.gz
xfce4-panel-profiles-6f8741acd10ce1a1c85884ecdc0fd32f7f3ba330.zip
Import Upstream version 1.0.13
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure64
1 files changed, 64 insertions, 0 deletions
diff --git a/configure b/configure
new file mode 100755
index 0000000..55fa3d0
--- /dev/null
+++ b/configure
@@ -0,0 +1,64 @@
+#!/bin/sh
+
+APPNAME=xfce4-panel-profiles
+VERSION=1.0.13
+
+PYTHON=python3
+
+help () {
+ echo "Supported options are:"
+ echo " --help print this help and exit"
+ echo " --prefix=<path> specify installation prefix"
+ echo " <path>/bin - will hold all executables"
+ echo " default <path> is /usr/local"
+ echo " --python=<python executable> specify python version"
+ echo " python or python3"
+ echo " default <python executable> is $PYTHON"
+ echo " --docdir=<path> specify docdir"
+ echo " default <path> is \$PREFIX/share/doc/$APPNAME"
+}
+
+PREFIX=${PREFIX:-"/usr/local"}
+
+while [ $# -gt 0 ]; do
+ case $1 in
+ --help)
+ help
+ exit 0
+ ;;
+ --prefix=*)
+ PREFIX=`echo $1 | sed 's/--prefix=//'`
+ ;;
+ --python=*)
+ PYTHON=`echo $1 | sed 's/--python=//'`
+ ;;
+ --mandir=*)
+ MANDIR=`echo $1 | sed 's/--mandir=//'`
+ ;;
+ --docdir=*)
+ DOCDIR=`echo $1 | sed 's/--docdir=//'`
+ ;;
+ *)
+ echo "Unknown option $1"
+ help
+ exit 1
+ ;;
+ esac
+ shift
+done
+
+DOCDIR=${DOCDIR:-"$PREFIX/share/doc/$APPNAME"}
+MANDIR=${MANDIR:-"$PREFIX/share/man"}
+
+echo "Creating Makefile..."
+sed -e s,@prefix@,$PREFIX, Makefile.in.in > Makefile.in
+sed \
+ -e s,@appname@,$APPNAME,g \
+ -e s,@version@,$VERSION,g \
+ -e s,@mandir@,$MANDIR,g \
+ -e s,@docdir@,$DOCDIR,g \
+ -e s,@python@,$PYTHON,g \
+ Makefile.in > Makefile
+echo "Installation prefix is $PREFIX"
+echo "Installation mandir is $MANDIR"
+echo "Installation docdir is $DOCDIR"