1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-24 11:45:18 +03:00
aports/community/phoc/APKBUILD
2023-03-02 16:19:14 +00:00

99 lines
3 KiB
Text

# Contributor: Bart Ribbers <bribbers@disroot.org>
# Contributor: Danct12 <danct12@disroot.org>
# Contributor: Clayton Craft <clayton@craftyguy.net>
# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Newbyte <newbie13xd@gmail.com>
pkgname=phoc
pkgver=0.25.0
pkgrel=0
_wlrootsver="0.15.1-2pureos1_oct3"
_gmobile_commit="f4d4e5740c3e4b2de40864ab8a9e7b7f957d6aec"
pkgdesc="wlroots based Phone compositor for the Phosh shell"
arch="all !s390x" # blocked by gnome-desktop
url="https://gitlab.gnome.org/World/Phosh/phoc"
license="GPL-3.0-only"
depends="
dbus
mutter-schemas
gsettings-desktop-schemas
"
_wlrootsmakedepends="
eudev-dev
libcap-dev
libseat-dev
libxcb-dev
xcb-util-image-dev
xcb-util-renderutil-dev
xcb-util-wm-dev
xkeyboard-config-dev
xwayland-dev
"
makedepends="
glib-dev
gnome-desktop-dev
json-glib-dev
libdrm-dev
libinput-dev
libxkbcommon-dev
mesa-dev
meson
pixman-dev
wayland-dev
wayland-protocols
$_wlrootsmakedepends
"
checkdepends="xvfb-run"
subpackages="$pkgname-dbg"
options="!check" # Needs fullblown EGL
source="
https://gitlab.gnome.org/World/Phosh/phoc/-/archive/v$pkgver/phoc-v$pkgver.tar.gz
https://source.puri.sm/Librem5/wlroots/-/archive/pureos/$_wlrootsver/wlroots-pureos-$_wlrootsver.tar.gz
https://gitlab.gnome.org/guidog/gmobile/-/archive/$_gmobile_commit/gmobile-$_gmobile_commit.tar.gz
clear-back-buffer.patch.noauto
"
replaces="wlroots-phosh"
builddir="$srcdir/$pkgname-v$pkgver"
prepare() {
default_prepare
mv "$srcdir/wlroots-pureos-$_wlrootsver"/* subprojects/wlroots
mv "$srcdir/gmobile-$_gmobile_commit"/* subprojects/gmobile
patch -Np1 < "$srcdir"/clear-back-buffer.patch.noauto -d subprojects/wlroots
# apply wlroots patches
cd "$builddir/subprojects/wlroots"
grep "\.patch$" debian/patches/series | \
xargs -I {} -t -r -n1 patch -p1 -i debian/patches/{}
}
build() {
abuild-meson \
-Dembed-wlroots=enabled \
--default-library=static \
. output
meson compile ${JOBS:+-j ${JOBS}} -C output
}
check() {
xvfb-run -a meson test --no-rebuild --print-errorlogs -C output
}
package() {
DESTDIR="$pkgdir/" meson install --no-rebuild -C output
install -Dm755 helpers/scale-to-fit \
-t "$pkgdir"/usr/bin
# remove unneeded wlroots dev. files
rm -r "$pkgdir"/usr/include
rm -r "$pkgdir"/usr/lib/libwlroots.a
rm -r "$pkgdir"/usr/lib/pkgconfig
}
sha512sums="
5751edf2e5adeeeb053db2779c2402dea5c4cdd0acd01103543cf832a0dbb5768697ef58d95026e18c9a866f98a545b9d20fec3601c5868237c9ec085185edad phoc-v0.25.0.tar.gz
b71a8e81473841b45e0c718ca97454a8f95649d08d5b2ddd5766e55fbaa4e103cf3ee28c38953e48ed81d0ab0060646a3aaf57c5d39f46bac7e20ba2d007e338 wlroots-pureos-0.15.1-2pureos1_oct3.tar.gz
c7854b210aeb8995382637cc9907d26fa90d87ef530738a54d96efe0f2dce06afe6d169251242775866d6450bb285e1f084ad5c0e25c183d862ab72c193a43c0 gmobile-f4d4e5740c3e4b2de40864ab8a9e7b7f957d6aec.tar.gz
5e163ed2b918287397cd7485207ea3ee19ef5585771c709f937b4dc442aa86153d9c8414295d336a9379896e1c9728614e6126d768c3efa6da41ef961d480970 clear-back-buffer.patch.noauto
"