summaryrefslogtreecommitdiffstats
path: root/desktop/weston/weston.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'desktop/weston/weston.SlackBuild')
-rw-r--r--desktop/weston/weston.SlackBuild66
1 files changed, 23 insertions, 43 deletions
diff --git a/desktop/weston/weston.SlackBuild b/desktop/weston/weston.SlackBuild
index d44a73d774..362c5d6954 100644
--- a/desktop/weston/weston.SlackBuild
+++ b/desktop/weston/weston.SlackBuild
@@ -1,8 +1,8 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for Weston
-# Copyright 2019-2020 Logan Rathbone <poprocks@gmail.com>
+# Copyright 2019-2023 Logan Rathbone <poprocks@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -22,10 +22,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=weston
-VERSION=${VERSION:-7.0.0}
-BUILD=${BUILD:-2}
+VERSION=${VERSION:-10.0.5}
+BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,7 +38,11 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+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}
@@ -60,18 +67,11 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
+tar xvf $CWD/$PRGNAM-$VERSION.tar.?z
cd $PRGNAM-$VERSION
-# If you have PAM installed on your system and would like to make use
-# of it, run this as USE_PAM=true ./weston.Slackbuild
-# otherwise, a patch will be applied to remove the PAM dependency.
-
-USE_PAM=${USE_PAM:-false}
-
-if [ "$USE_PAM" != 'true' ]; then
- patch -p1 < $CWD/weston-7.0.0-nopam.patch
-fi
+# Patches
+patch -p1 < $CWD/weston-10.0.0-elogind.patch
# Make sure ownerships and permissions are sane:
chown -R root:root .
@@ -81,27 +81,18 @@ 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 {} \;
-# "./configure"
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
-meson build/ \
+meson \
+ --buildtype=release \
--prefix=/usr \
--mandir=man \
--libdir=lib${LIBDIRSUFFIX} \
- -Dlauncher-logind=false \
- -Dbackend-rdp=false \
-Dsystemd=false \
- -Dpipewire=false \
- -Dsimple-dmabuf-drm=auto \
- -Dcolor-management-colord=${USE_COLORD:-false}
-
-# "make"
-CFLAGS="$SLKCFLAGS" \
-CXXFLAGS="$SLKCFLAGS" \
-ninja -C build
-
-# "make install"
-DESTDIR=$PKG ninja -C build/ install
+ -Dcolor-management-colord=${USE_COLORD:-false} \
+ build/
+"${NINJA:=ninja}" -v -C build/
+DESTDIR=$PKG $NINJA -C build/ install
# strip
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
@@ -171,16 +162,6 @@ EOF
# config-ify the profile.d stuff
-# FIXME - I tried many things to try to creatively preserve the perms
-# of weston-launch as well (ie, in case someone suid's it and wants to
-# keep it that way upon upgrade), but this is really difficult if not
-# impossible to implement with Slackware's packaging system without
-# allowing for stray binaries (which would have been setuid by the
-# user) lingering around, which I'd really rather avoid, for safety.
-#
-# At this juncture, users will simply have to manually setuid-root the
-# binary upon each upgrade.
-
cat << EOF >> $PKG/install/doinst.sh
preserve_perms etc/profile.d/${PRGNAM}.sh.new
preserve_perms etc/profile.d/${PRGNAM}.csh.new
@@ -189,11 +170,10 @@ EOF
# Install some documentation and finish up.
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a COPYING README.md CONTRIBUTING.md $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a CONTRIBUTING.md COPYING DCO-1.1.txt README.md notes.txt $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
-cat $CWD/README > $PKG/usr/doc/$PRGNAM-$VERSION/README.Slackware
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE