aboutsummaryrefslogtreecommitdiff
path: root/desktop/obsession
diff options
context:
space:
mode:
authorEdinaldo P. Silva <edps.mundognu@gmail.com>2015-11-15 09:04:35 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2015-11-17 20:56:41 +0700
commit36e737c01338a749076c85b00d5d1324179f5bb5 (patch)
treefc0a7589747e82f36d483c163a0ae6b94b4b423f /desktop/obsession
parent6db47505459adf0ae750d89c2d211d4c96cc046d (diff)
desktop/obsession: Update script.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'desktop/obsession')
-rw-r--r--desktop/obsession/0001-make-clean-now-revert-to-pre-configure-state.patch29
-rw-r--r--desktop/obsession/README10
-rw-r--r--desktop/obsession/obsession.SlackBuild15
3 files changed, 52 insertions, 2 deletions
diff --git a/desktop/obsession/0001-make-clean-now-revert-to-pre-configure-state.patch b/desktop/obsession/0001-make-clean-now-revert-to-pre-configure-state.patch
new file mode 100644
index 000000000000..21918c8bb074
--- /dev/null
+++ b/desktop/obsession/0001-make-clean-now-revert-to-pre-configure-state.patch
@@ -0,0 +1,29 @@
+From: Fabien Givors <f+debian@chezlefab.net>
+Date: Mon, 13 Oct 2014 19:26:11 +0200
+Subject: make clean now revert to pre-configure state
+-
+Author: Fabien Givors <f+debian@chezlefab.net>
+Forwarded: yes
+Last-Update: 2014-10-13
+
+
+ * make clean remove makefile.mk file
+ * make clean restore default PREFIX in config.h
+---
+ Makefile | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/Makefile b/Makefile
+index a241804..e8924fd 100644
+--- a/Makefile
++++ b/Makefile
+@@ -48,6 +48,9 @@ mrproper: clean
+
+ clean:
+ rm -f obsession-exit obsession-logout xdg-autostart *.o $(I18N_MO)
++ sed -i 's#define PREFIX.*#define PREFIX "/usr/local"#' config.h
++
++ rm -f makefile.mk
+
+ configure:
+ sed -i 's#define PREFIX.*#define PREFIX "$(PREFIX)"#' config.h
diff --git a/desktop/obsession/README b/desktop/obsession/README
index 3bb7fd86362a..2de2a5be94c1 100644
--- a/desktop/obsession/README
+++ b/desktop/obsession/README
@@ -2,3 +2,13 @@ obsession (Openbox session tools)
Obsession displays dialog where you can choose if you
want to quit, power off, suspend or hibernate the computer.
+
+And provides:
+
+ * obsession-logout displays a dialog where you can choose
+if you want to quit the session, power off, suspend or
+hibernate the computer.
+ * obsession-exit: this is the command line version of
+obsession-logout.
+ * xdg-autostart start automatically programs defined in
+/etc/xdg/autostart and ~/.config/autostart.
diff --git a/desktop/obsession/obsession.SlackBuild b/desktop/obsession/obsession.SlackBuild
index 0b8fc54d3bec..2a34c6a88501 100644
--- a/desktop/obsession/obsession.SlackBuild
+++ b/desktop/obsession/obsession.SlackBuild
@@ -1,6 +1,7 @@
#!/bin/sh
+#
# Slackware build script for obsession.
-
+#
# Copyright 2015 Edinaldo P. Silva, Rio de Janeiro, Brazil.
# All rights reserved.
#
@@ -23,7 +24,7 @@
PRGNAM=obsession
VERSION=${VERSION:-20140608}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -68,9 +69,13 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+rm -rf {archlinux,.hg*}
+
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
+patch -p1 < $CWD/0001-make-clean-now-revert-to-pre-configure-state.patch
+
make configure PREFIX=/usr
make
make install DESTDIR=$PKG
@@ -78,6 +83,12 @@ make install DESTDIR=$PKG
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+mkdir -p $PKG/usr/man/man1
+install -D -m644 {obsession-exit.1,obsession-logout.1,xdg-autostart.1} $PKG/usr/man/man1
+
+find $PKG/usr/man -type f -exec gzip -9 {} \;
+for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+
DOCS="AUTHORS COPYING INSTALL README.md TODO"
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION