summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author Heinz Wiesinger <HMWiesinger@gmx.at>2010-05-11 20:02:01 +0200
committer Robby Workman <rworkman@slackbuilds.org>2010-05-11 20:02:01 +0200
commitddce670a824a0416c17d9d5532c795b96815b548 (patch)
treed9a7a26ee35ec29f5203f221a1f131e5106a0199
parent16808fc8cf5aa630e98fff836dc6a34e3315d6ff (diff)
downloadslackbuilds-ddce670a824a0416c17d9d5532c795b96815b548.tar.gz
slackbuilds-ddce670a824a0416c17d9d5532c795b96815b548.tar.xz
system/lapsus: Added to 12.0 repository
-rw-r--r--system/lapsus/README13
-rw-r--r--system/lapsus/doinst.sh23
-rw-r--r--system/lapsus/lapsus.SlackBuild58
-rw-r--r--system/lapsus/lapsus.info8
-rw-r--r--system/lapsus/rc.lapsus40
-rw-r--r--system/lapsus/slack-desc12
6 files changed, 154 insertions, 0 deletions
diff --git a/system/lapsus/README b/system/lapsus/README
new file mode 100644
index 0000000000..4c35d032a5
--- /dev/null
+++ b/system/lapsus/README
@@ -0,0 +1,13 @@
+Lapsus is a program created to let laptops users use many of the
+features of their laptops which are supported by Linux. For now,
+there are two hardware-specific backends - Asus and IBM, and one
+'generic' backend for all unsupported hardware.
+
+Every user, who wants to use lapsus, needs to be in a group called
+'lapsus'. You can add that group via 'groupadd lapsus'.
+Alternatively, if you want to use a different group, you can edit
+/etc/dbus-1/system.d/lapsus.conf to specify a different one:
+Change the line that reads like this:
+ <policy group="lapsus">
+to whatever group you wish to use; for example, the 'power' group:
+ <policy group="power">
diff --git a/system/lapsus/doinst.sh b/system/lapsus/doinst.sh
new file mode 100644
index 0000000000..658afbcb90
--- /dev/null
+++ b/system/lapsus/doinst.sh
@@ -0,0 +1,23 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+# Keep same perms on rc.lapsus.new:
+if [ -e etc/rc.d/rc.lapsus ]; then
+ cp -a etc/rc.d/rc.lapsus etc/rc.d/rc.lapsus.new.incoming
+ cat etc/rc.d/rc.lapsus.new > etc/rc.d/rc.lapsus.new.incoming
+ mv etc/rc.d/rc.lapsus.new.incoming etc/rc.d/rc.lapsus.new
+fi
+
+config etc/rc.d/rc.lapsus.new
+config etc/dbus-1/system.d/lapsus.conf.new
+
diff --git a/system/lapsus/lapsus.SlackBuild b/system/lapsus/lapsus.SlackBuild
new file mode 100644
index 0000000000..aeb974ea86
--- /dev/null
+++ b/system/lapsus/lapsus.SlackBuild
@@ -0,0 +1,58 @@
+#!/bin/sh
+
+# Slackware build script for lapsus
+# Written by ppr:kut <hmwiesinger@gmx.at>
+
+PRGNAM=lapsus
+VERSION=0.0.5
+ARCH=${ARCH:-i486}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
+cd $PRGNAM-$VERSION
+chown -R root:root .
+chmod -R u+w,go+r-w,a-s .
+
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc/kde \
+ --localstatedir=/var \
+ --disable-static
+
+make
+make install-strip DESTDIR=$PKG
+
+mkdir -p $PKG/etc/{rc.d,dbus-1/system.d}
+install -m 0644 lapsus.conf $PKG/etc/dbus-1/system.d/lapsus.conf.new
+install -m 0755 $CWD/rc.lapsus $PKG/etc/rc.d/rc.lapsus.new
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS ChangeLog COPYING INSTALL NEWS README TODO \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
diff --git a/system/lapsus/lapsus.info b/system/lapsus/lapsus.info
new file mode 100644
index 0000000000..3fcd852c5b
--- /dev/null
+++ b/system/lapsus/lapsus.info
@@ -0,0 +1,8 @@
+PRGNAM="lapsus"
+VERSION="0.0.5"
+HOMEPAGE="http://lapsus.berlios.de"
+DOWNLOAD="http://download.berlios.de/lapsus/lapsus-0.0.5.tar.bz2"
+MD5SUM="a7579a3e92d94f7502053ee3566e619f"
+MAINTAINER="ppr:kut"
+EMAIL="HMWiesinger@gmx.at"
+APPROVED="rworkman"
diff --git a/system/lapsus/rc.lapsus b/system/lapsus/rc.lapsus
new file mode 100644
index 0000000000..a9c0c6ded7
--- /dev/null
+++ b/system/lapsus/rc.lapsus
@@ -0,0 +1,40 @@
+#!/bin/sh
+# Start/stop/restart lapsus.
+# $Id: rc.lapsus,v 1.0 2007/11/28
+# Author: Heinz Wiesinger <hmwiesinger@gmx.at>
+# ---------------------------------------------------------------------------
+
+# Start lapsus:
+lapsus_start() {
+ if [ -x /usr/sbin/lapsusd ]; then
+ echo "Starting lapsus daemon: /usr/sbin/lapsusd "
+ /usr/sbin/lapsusd
+ fi
+}
+
+# Stop lapsus:
+lapsus_stop() {
+ echo "Stopping lapsus daemon"
+ killall lapsusd 1> /dev/null 2> /dev/null
+}
+
+# Restart lapsus:
+lapsus_restart() {
+ lapsus_stop
+ sleep 1
+ lapsus_start
+}
+
+case "$1" in
+'start')
+ lapsus_start
+ ;;
+'stop')
+ lapsus_stop
+ ;;
+'restart')
+ lapsus_restart
+ ;;
+*)
+ echo "usage $0 start|stop|restart"
+esac
diff --git a/system/lapsus/slack-desc b/system/lapsus/slack-desc
new file mode 100644
index 0000000000..732d753c78
--- /dev/null
+++ b/system/lapsus/slack-desc
@@ -0,0 +1,12 @@
+ |-----handy-ruler---------------------------------------------------|
+lapsus: lapsus (program to use many of the features of laptops)
+lapsus:
+lapsus: Lapsus is a program created to let laptops users use many of the
+lapsus: features of their laptops which are supported by Linux. For now,
+lapsus: there are two hardware-specific backends - Asus and IBM, and one
+lapsus: 'generic' backend for all unsupported hardware.
+lapsus:
+lapsus: Homepage: http://lapsus.berlios.de
+lapsus:
+lapsus:
+lapsus: