wlroots-hidpi/PKGBUILD

66 lines
1.7 KiB
Bash

# Maintainer: Antonin Décimo <antonin dot decimo at gmail dot com>
# Contributor: Adrian Perez de Castro <aperez@igalia.com>
pkgname=wlroots-hidpi-git
pkgver=0.12.0.r378.g00bee2a6
pkgrel=1
license=(custom:MIT)
pkgdesc='Modular Wayland compositor library, with XWayland HiDPI (git version)'
url=https://github.com/swaywm/wlroots
arch=(x86_64)
provides=("wlroots-hidpi=${pkgver%%.r*}"
"wlroots=${pkgver%%.r*}"
"wlroots-git")
conflicts=(wlroots wlroots-git)
options=(debug)
depends=(
libinput
libxcb
libxkbcommon
opengl-driver
pixman
wayland
xcb-util-errors
xcb-util-renderutil
xcb-util-wm
systemd)
makedepends=(
git
meson
wayland-protocols
xorgproto)
source=("${pkgname}::git+${url}"
# "xwayland_hidpi.diff::https://github.com/swaywm/wlroots/pull/2064.diff"
"xwayland_hidpi.diff::https://github.com/swaywm/wlroots/compare/master...MisterDA:xwayland_hidpi.diff"
)
sha512sums=('SKIP'
'3f72a84ffdbdcafb40a28c563fabac9d231441cf17304121f2c083a35bdd477ea95a0baf26a08f77907d2d4e99f1c510d2d7f60b1896fb10fe1ce7164ae04c9e')
pkgver () {
cd "${pkgname}"
(
set -o pipefail
git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
)
}
prepare () {
cd "${pkgname}"
patch --forward --strip=1 --input="${srcdir}/xwayland_hidpi.diff"
}
build () {
arch-meson \
-Dlogind-provider=systemd \
-Dlibseat=disabled \
-Dwerror=false \
-Dexamples=false \
"${pkgname}" build
meson compile -C build
}
package () {
DESTDIR="${pkgdir}" meson install -C build
install -Dm644 "${pkgname}/"LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}