diff --git a/pkgs/additional/phog/default.nix b/pkgs/additional/phog/default.nix index fd5ef437..8cd0a7bd 100644 --- a/pkgs/additional/phog/default.nix +++ b/pkgs/additional/phog/default.nix @@ -1,10 +1,12 @@ { lib , stdenv , fetchFromGitLab +, fetchpatch , meson , ninja , pkg-config , gcr +, gitUpdater , glib , gnome-desktop , gtk3 @@ -29,16 +31,28 @@ stdenv.mkDerivation rec { pname = "phog"; - version = "0.1.3"; + version = "0.1.4"; src = fetchFromGitLab { owner = "mobian1"; repo = "phog"; rev = version; - hash = "sha256-zny1FUYKwVXVSBGTh8AFVtMBS7dWZHTKO2gkPNPSL2M="; + hash = "sha256-Uy3u2xnfbO1G/xMLmgIbZZmhQR9vW51vmHoR/ykw8vc="; }; patches = [ + # (fetchpatch { + # # merged post 0.1.4 + # # https://gitlab.com/mobian1/phog/-/merge_requests/4 + # # fixes "json_node_unref: assertion 'JSON_NODE_IS_VALID (node)' failed" + # name = "greetd: Don't free reply_root"; + # url = "https://gitlab.com/mobian1/phog/-/commit/ad1a2b876a1205f0927c7c02e0471364d557e3fe.patch"; + # hash = "sha256-gYQLDCKNIc4xPtgKRMzH4fmayx5w2oED2FjkD7fKswA="; + # }) + # somehow ignoring session_info's w/o DesktopNames causes a segfault... + # this patch reverts part of the following change: + # TODO: probably i can fix up my sessions to include DesktopNames, and then remove this patch + ./dont-skip-sessions-without-DesktopNames.patch ./sway-compat.patch ]; @@ -93,6 +107,8 @@ stdenv.mkDerivation rec { wrapGAppsHook ]; + passthru.updateScript = gitUpdater {}; + meta = with lib; { description = "Greetd-compatible greeter for mobile phones"; homepage = "https://gitlab.com/mobian1/phog/"; diff --git a/pkgs/additional/phog/dont-skip-sessions-without-DesktopNames.patch b/pkgs/additional/phog/dont-skip-sessions-without-DesktopNames.patch new file mode 100644 index 00000000..6d8c65db --- /dev/null +++ b/pkgs/additional/phog/dont-skip-sessions-without-DesktopNames.patch @@ -0,0 +1,16 @@ +diff --git a/src/greetd.c b/src/greetd.c +index 71d0b68c..831a68a2 100644 +--- a/src/greetd.c ++++ b/src/greetd.c +@@ -146,11 +146,6 @@ greetd_list_sessions_in_folder (PhogGreetd *self, const gchar *path, const gchar + g_app_info_get_commandline (G_APP_INFO (session_info))); + + desktop_names = g_desktop_app_info_get_string (session_info, "DesktopNames"); +- if (!desktop_names) { +- g_warning ("No DesktopNames in %s - ignoring", session_id); +- continue; +- } +- + if (g_str_has_suffix (desktop_names, ";")) { + desktop_names[strlen (desktop_names) - 1] = '\0'; + }