[wayland/river|wlr-randr] add

This commit is contained in:
Gwenhael Le Moine 2021-09-08 11:08:07 +02:00
parent 1866aba637
commit df0ade3b48
No known key found for this signature in database
GPG key ID: FDFE3669426707A7
2 changed files with 79 additions and 1 deletions

View file

@ -33,7 +33,7 @@ cd $TMP/$PRGNAM/
[ "x$VERSION" == "xtrunk" ] && VERSION="git_$(git log -1 --format=%h_%ad --date=format:%Y.%m.%d)" || git checkout $VERSION
zig build -Drelease-safe --prefix $PKG$PREFIX install
zig build -Dxwayland -Drelease-safe --prefix $PKG$PREFIX install
mv $PKG$PREFIX/share/man $PKG$PREFIX/
@ -59,6 +59,12 @@ export SDL_VIDEODRIVER=wayland
export XDG_CURRENT_DESKTOP=river
# export XKB_DEFAULT_MODEL
export XKB_DEFAULT_LAYOUT "us(intl)"
# export XKB_DEFAULT_VARIANT
export XKB_DEFAULT_OPTIONS "compose:caps,ctrl:nocaps,eurosign:e"
# export XKB_DEFAULT_RULES
[ -e $HOME/.profile ] && . $HOME/.profile
exec /usr/bin/river

72
wayland/wlr-randr/SlackBuild Executable file
View file

@ -0,0 +1,72 @@
#!/bin/bash
# variables
VERSION=${VERSION:-"trunk"}
BUILD=1
TAG=gwh
OUTPUT=/tmp
TMP=/tmp/$TAG
CWD=$(pwd)
PRGNAM=$(basename $CWD)
PKG=$TMP/pkg-$PRGNAM
ARCH=$(uname -m)
REPOSITORY=/home/installs/SlackBuilds/repositories/$PRGNAM
PREFIX=/usr
# nettoyage préalable
rm -fr $PKG $TMP/$PRGNAM
mkdir -p $PKG
# mise en place
[ ! -e $REPOSITORY ] && git clone https://github.com/emersion/wlr-randr $REPOSITORY
cd $REPOSITORY
git pull --all
cp -R $REPOSITORY $TMP/
cd $TMP/$PRGNAM/
[ "x$VERSION" == "xtrunk" ] && VERSION="git_$(git log -1 --format=%h_%ad --date=format:%Y.%m.%d)" || git checkout $VERSION
meson setup \
--prefix /usr \
--mandir /usr/man/ \
build/
ninja -C build/
cd build/
meson install --destdir=$PKG
cd ../
mkdir -p $PKG$PREFIX/doc/$PRGNAM
cp LICENSE *.md $PKG$PREFIX/doc/$PRGNAM/
# correction
cd $PKG
chown -R root:root *
find $PKG$PREFIX/man -name "*.?" -type f -exec gzip -9 {} \;
# embaumement
mkdir -p $PKG/install
cat <<EOF > $PKG/install/slack-desc
|-----handy-ruler------------------------------------------------------|
$PRGNAM: $PRGNAM (An xrandr clone for wlroots compositors)
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: https://wayland.emersion.fr/wlr-randr/
EOF
# empaquetage
rm -f $PKG/{,usr/}lib$(uname -m | grep -o 64)/*.la
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz