From e8f41bbd285870605694e524bc23b4d65bb38ef9 Mon Sep 17 00:00:00 2001 From: Joel Selvaraj Date: Thu, 6 Feb 2025 17:42:47 -0600 Subject: [PATCH] gain/postmarketos-ui-phosh: use greetd phrog to start phosh Co-Authored-By: Achill Gilgenast Part-of: --- main/postmarketos-ui-phosh/APKBUILD | 27 ++++++++++++------- main/postmarketos-ui-phosh/greetd-phrog.conf | 4 +++ main/postmarketos-ui-phosh/greetd.confd | 7 +++++ .../postmarketos-ui-phosh-openrc.post-install | 2 +- .../postmarketos-ui-phosh.post-install | 2 -- 5 files changed, 29 insertions(+), 13 deletions(-) create mode 100644 main/postmarketos-ui-phosh/greetd-phrog.conf create mode 100644 main/postmarketos-ui-phosh/greetd.confd diff --git a/main/postmarketos-ui-phosh/APKBUILD b/main/postmarketos-ui-phosh/APKBUILD index 6936a7700..2df7c9e61 100644 --- a/main/postmarketos-ui-phosh/APKBUILD +++ b/main/postmarketos-ui-phosh/APKBUILD @@ -3,8 +3,8 @@ # Co-Maintainer: Pablo Correa Gomez # Co-Maintainer: Achill Gilgenast pkgname=postmarketos-ui-phosh -pkgver=25 -pkgrel=2 +pkgver=26 +pkgrel=0 pkgdesc="(Wayland) Mobile UI initially developed for the Librem 5" url="https://phosh.mobi" arch="noarch !armhf" @@ -15,14 +15,14 @@ depends=" !gnome-shell-mobile-schemas !mutter-mobile !mutter-mobile-schemas - cellbroadcastd bluez + cellbroadcastd + greetd-phrog phosh postmarketos-base-ui-gnome-mobile postmarketos-base-ui-qt-tweaks postmarketos-base-ui-qt-wayland sound-theme-phosh - tinydm udiskie xdg-desktop-portal-phosh xdg-desktop-portal-wlr @@ -36,6 +36,8 @@ source=" 01_postmarketos-ui-phosh.gschema.override mimeapps.list udiskie.desktop + greetd.confd + greetd-phrog.conf " options="!check pmb:drm pmb:systemd" subpackages="$pkgname-default-osk:default_osk $pkgname-openrc $pkgname-systemd" @@ -58,20 +60,25 @@ default_osk() { openrc() { install_if="$pkgname=$pkgver-r$pkgrel openrc" install="$subpkgname.post-install" - depends="tinydm-openrc" - mkdir "$subpkgdir" + depends="greetd-openrc" + replaces="greetd-openrc" + + install -Dm644 "$srcdir"/greetd.confd \ + "$subpkgdir"/etc/conf.d/greetd } systemd() { install_if="$pkgname=$pkgver-r$pkgrel systemd" - depends=" - libcap-utils - " - mkdir "$subpkgdir" + depends="libcap-utils" + + install -Dm644 "$srcdir"/greetd-phrog.conf \ + "$subpkgdir"/usr/lib/systemd/system/greetd.service.d/override.conf } sha512sums=" 3ce42ce9cd55fb80dbd5689bb2b4955b7b296f0487163a3a7ad4eeecc0f874d890aaba76071aabc103dd67d0c8258dc077f202e28325d05b77a610613d1878d9 01_postmarketos-ui-phosh.gschema.override a741e8db9e4232334b924326c48be4e4c8f7a2382a7608926918a7491c518b2dda551e55a00d4d5fcf58c7950a78dc35d5cc5eaab53ad93a56de40887071f242 mimeapps.list 53f5c565b4ca8a12f12b63ec84a0194ef530703565d123203d41582a35a54d66afaf3a676df158ae0effe327dcfc1c6496a082ce9dbe803b2547417c3c3fad6e udiskie.desktop +38724b931f4c94a7b716e6ed908babc81c42d7f540bf715eecccd17b82d558886f5816168171ca1c29fbe8bee9bc46ad31e55def44001047f8ac26b796a79eee greetd.confd +62e75d0cfc1ae8ea63fff43e5f08276c8cde00d7c39f46be17ac547827bdb3a5c09569b020daa54b8acb4dce05220cbb05a0c9ba915ded401ce47f39afcdd4f0 greetd-phrog.conf " diff --git a/main/postmarketos-ui-phosh/greetd-phrog.conf b/main/postmarketos-ui-phosh/greetd-phrog.conf new file mode 100644 index 000000000..4444977cf --- /dev/null +++ b/main/postmarketos-ui-phosh/greetd-phrog.conf @@ -0,0 +1,4 @@ +# Override the ExecStart line by the configuration file +[Service] +ExecStart= +ExecStart=greetd -c /etc/phrog/greetd-config.toml diff --git a/main/postmarketos-ui-phosh/greetd.confd b/main/postmarketos-ui-phosh/greetd.confd new file mode 100644 index 000000000..f9a3bdc08 --- /dev/null +++ b/main/postmarketos-ui-phosh/greetd.confd @@ -0,0 +1,7 @@ +# Configuration for greetd + +# Path to config file to use. +cfgfile="/etc/phrog/greetd-config.toml" + +# Uncomment to use process supervisor when using openrc. +# supervisor=supervise-daemon diff --git a/main/postmarketos-ui-phosh/postmarketos-ui-phosh-openrc.post-install b/main/postmarketos-ui-phosh/postmarketos-ui-phosh-openrc.post-install index 7fc751ab8..e0a0184ca 100644 --- a/main/postmarketos-ui-phosh/postmarketos-ui-phosh-openrc.post-install +++ b/main/postmarketos-ui-phosh/postmarketos-ui-phosh-openrc.post-install @@ -1,6 +1,6 @@ #!/bin/sh -rc-update add tinydm default +rc-update add greetd default rc-update add waked default exit 0 diff --git a/main/postmarketos-ui-phosh/postmarketos-ui-phosh.post-install b/main/postmarketos-ui-phosh/postmarketos-ui-phosh.post-install index b3ad58952..8de74e9e7 100644 --- a/main/postmarketos-ui-phosh/postmarketos-ui-phosh.post-install +++ b/main/postmarketos-ui-phosh/postmarketos-ui-phosh.post-install @@ -10,6 +10,4 @@ if [ -n "$default_user" ]; then usermod -aG feedbackd "$default_user" fi -tinydm-set-session -s /usr/share/wayland-sessions/phosh.desktop - exit 0