aboutsummaryrefslogtreecommitdiff
path: root/desktop/devilspie2
diff options
context:
space:
mode:
authorMarek Šrejma <marek@modweb.de>2023-02-01 22:02:47 +0000
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2023-02-04 07:19:53 +0700
commit22e4f4bdf2cb4986141e9bdd98ec6e1195f6a4fb (patch)
tree6c245a3141be1ba2ae2154feb2e394684df78a50 /desktop/devilspie2
parent6a1f2280f5c8b55bbd533c997ed99205b810abcf (diff)
desktop/devilspie2: Added (window-matching utility)
Signed-off-by: bedlam <dave@slackbuilds.org> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'desktop/devilspie2')
-rw-r--r--desktop/devilspie2/README24
-rw-r--r--desktop/devilspie2/devilspie2.SlackBuild90
-rw-r--r--desktop/devilspie2/devilspie2.info10
-rw-r--r--desktop/devilspie2/slack-desc19
4 files changed, 143 insertions, 0 deletions
diff --git a/desktop/devilspie2/README b/desktop/devilspie2/README
new file mode 100644
index 0000000000000..6b9c2be55ba7e
--- /dev/null
+++ b/desktop/devilspie2/README
@@ -0,0 +1,24 @@
+Devil's Pie 2 - A window-matching utility
+
+Devilspie2 is a window-matching utility, allowing the user to perform
+scripted actions on windows as they are created. For example, you can
+script a terminal program to always be positioned at a specific screen
+position, or position a window on a specific workspace.
+
+Devilspie2 is based on the program Devilspie by Ross Burton. The
+difference is that Devilspie2 has replaced the symbolic expressions of
+the original with a Lua interpreter, making it much easier to maintain
+and extend.
+
+Please note that the rules of Devilspie2 are not compatible with the
+symbolic expressions of the original Devilspie.
+
+Please see the README for more information and examples of use.
+
+This script will build the package with support for GTK 3 and Lua 5.1,
+but if you prefer building it with other versions,
+i.e GTK 2 and Lua 5.4, use
+
+ GTK2=on LUA=5.4 devilspie2.SlackBuild
+
+Also the compiler can be set optionally, i.e CC=clang.
diff --git a/desktop/devilspie2/devilspie2.SlackBuild b/desktop/devilspie2/devilspie2.SlackBuild
new file mode 100644
index 0000000000000..cfdab8fa1f2ae
--- /dev/null
+++ b/desktop/devilspie2/devilspie2.SlackBuild
@@ -0,0 +1,90 @@
+#!/bin/bash
+
+# Slackware build script for devilspie
+# Written by Phillip Warner <pc_warner@yahoo.com>
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PRGNAM=devilspie2
+VERSION=${VERSION:-0.44}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i586" ] || [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march="$ARCH" -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ] || [ "$ARCH" = "aarch64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 \
+ -o -perm 400 \) -exec chmod 644 {} \;
+
+sed -i "s#share/man#man#" Makefile
+
+CFLAGS="$SLKCFLAGS" \
+CPPFLAGS="$SLKCFLAGS" \
+CC=${CC:-gcc} \
+PREFIX=/usr \
+LUA=lua${LUA:-5.1} \
+GTK2=${GTK2:-off} \
+make
+
+PREFIX=/usr \
+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
+
+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
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -ar AUTHORS COPYING ChangeLog GPL3.txt README* TODO doc/examples \
+ $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
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/desktop/devilspie2/devilspie2.info b/desktop/devilspie2/devilspie2.info
new file mode 100644
index 0000000000000..84032d8412fd7
--- /dev/null
+++ b/desktop/devilspie2/devilspie2.info
@@ -0,0 +1,10 @@
+PRGNAM="devilspie2"
+VERSION="0.44"
+HOMEPAGE="https://www.nongnu.org/devilspie2/"
+DOWNLOAD="http://download.savannah.nongnu.org/releases/devilspie2/devilspie2-0.44.tar.xz"
+MD5SUM="60194adb85b935158c7c15017d3ab9df"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES="lua"
+MAINTAINER="Marek Šrejma"
+EMAIL="marek@modweb.de"
diff --git a/desktop/devilspie2/slack-desc b/desktop/devilspie2/slack-desc
new file mode 100644
index 0000000000000..ff329c29aa0b1
--- /dev/null
+++ b/desktop/devilspie2/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+devilspie2: devilspie2 (window-matching utility)
+devilspie2:
+devilspie2: Devil's Pie can be configured to detect windows as they are created,
+devilspie2: and match the window to a set of rules. If the window matches the
+devilspie2: rules, it can perform a series of actions on that window.
+devilspie2:
+devilspie2: Please note that the rules of Devilspie2 are not compatible with the
+devilspie2: symbolic expressions of the original Devilspie.
+devilspie2:
+devilspie2:
+devilspie2: