device-pine64-pinenote: drop sway subpackage

Sway subpackage existed to provide a shim between 7-r0 and 8-r0, where
sway UI configuration was refactored to be under `$pkgname-sway-hrdl`
subpackage instead of `$pkgname-sway`. This refactor was for two reasons:
1) clean-up package so that just the necessary files were included for
   different UIs
2) Since sway subpackage was pulled by sxmo-de-sway, it made sense
   only sway-related files be packaged by that subpackage.

Since 96853032, sway subpackage depends directly on `$pkgname-sway-hrdl`
subpackage to automatically pull sway-UI opinionated configuration by
default. This was a mistake, as it broke `sxmo-de-sway` that conflicts
with `iio-sensor-proxy` due to depending on conflicting polkit packages.

This commit drops sway subpackage, as the shim is not necessary anyway,
and adds `install_if` to `$pkgname-sway-hrdl` to automatically install
package when installing `postmarketos-ui-sway`. This means
`$pkgname-sway-hrdl` is never pulled when installing
`postmarketos-ui-sxmo-de-sway`, thus never pulling `iio-sensor-proxy`.

Fixes #4612

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8784>
This commit is contained in:
Antoine Martin
2026-06-11 04:13:08 +00:00
parent bac7f24803
commit 07c9b98eb7
2 changed files with 4 additions and 35 deletions
@@ -2,7 +2,7 @@ maintainer="Antoine Martin (ayakael) <dev@ayakael.net>"
pkgname=device-pine64-pinenote
pkgdesc="Pine64 PineNote"
pkgver=15
pkgrel=0
pkgrel=1
_commit="42cf0c3dc26d6e0b2a32ef5a00e7ca4ae77034c7"
_swayconfver="v1.1.0"
url="https://postmarketos.org"
@@ -51,7 +51,6 @@ subpackages="
$pkgname-nonfree-firmware-openrc:firmware_openrc
$pkgname-nonfree-firmware-systemd:firmware_systemd
$pkgname-openrc
$pkgname-sway
$pkgname-sway-hrdl
$pkgname-systemd
$pkgname-xournalpp
@@ -121,8 +120,11 @@ package() {
-t "$pkgdir"/usr/lib/modprobe.d
}
# since pinenote requires such an opinionated UI, hrdl's sway configuration is packaged that offers
# an optimized configuration for sway that matches the featureset offered by their Arch Linux image
hrdl() {
pkgdesc="Opinionated sway UI by hrdl optimized for the Pinenote"
install_if="$pkgname=$pkgver-r$pkgrel postmarketos-ui-sway"
install="$subpkgname.post-install $subpkgname.post-deinstall"
depends="
adwaita-icon-theme
@@ -139,7 +141,6 @@ hrdl() {
network-manager-applet
nwg-menu
papirus-icon-theme
postmarketos-ui-sway
py3-crcmod
py3-dbus-next
py3-i3ipc
@@ -234,20 +235,6 @@ firmware() {
ln -s ../cypress/cyfmac43455-sdio.bin.zst "$subpkgdir"/usr/lib/firmware/brcm/brcmfmac43455-sdio.pine64,pinenote-v1.2.bin.zst
}
sway() {
install_if="$pkgname=$pkgver-r$pkgrel sway"
install="$subpkgname.post-upgrade"
# since pinenote requires such an opinionated UI, UI configurations ar
# packaged from community developpers who are leading these efforts, and since
# there is the possibility of multiple UI configurations per UI, aport
# is architectured in a way to support multiple configurations. Since only hrdl's
# configuration is integrated, automatically depend on its subpackage for now.
depends="device-pine64-pinenote-sway-hrdl"
mkdir -p "$subpkgdir"
}
openrc() {
# rockchip_ebc sometimes fails to load the initial waveform.
# This forces a reload before starting tinydm
@@ -1,18 +0,0 @@
#!/bin/sh
# if device-pine64-pinenote-sway-hrdl isn't installed, and tinydm default session is sway_hrdl
# should set back to sway.desktop and give a message announcing end of default sway_hrdl
if ! apk info device-pine64-pinenote-sway-hrdl --installed -q && [ "$(readlink /var/lib/tinydm/default-session.desktop)" == "sway_hrdl" ]; then
cat >&2 <<-EOF
Starting with 8-r0 device package version, the opinionated configuration
from hrdl is not installed by default with sway, and packaged under a
different subpackage. To keep it, please execute the following
apk add device-pine64-pinenote-sway-hrdl
EOF
tinydm-set-session -f -s /usr/share/wayland-sessions/sway.desktop
fi