From 32e61d2a23ad7808fd46db56141da22fff8bbf53 Mon Sep 17 00:00:00 2001 From: Leorize Date: Mon, 23 Jun 2025 20:31:53 -0500 Subject: [PATCH] flatpak: remove references to systemd unit Flatpak currently does not export systemd user units. As such, remove references to it from D-Bus services to prevent D-Bus daemon from trying to start a non-existent service. Additionally, make sure that the D-Bus service name is correct for debug builds. --- flatpak/com.mitchellh.ghostty-debug.yml | 7 +++++++ flatpak/com.mitchellh.ghostty.yml | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/flatpak/com.mitchellh.ghostty-debug.yml b/flatpak/com.mitchellh.ghostty-debug.yml index 8a2c0056e..0ac8851e0 100644 --- a/flatpak/com.mitchellh.ghostty-debug.yml +++ b/flatpak/com.mitchellh.ghostty-debug.yml @@ -52,6 +52,13 @@ modules: --prefix /app --search-prefix /app --system $PWD/vendor/p + + # Rename to match service and drop systemd references + - sed -e 's/^Name=.*/\0-debug/' + -e '/^SystemdService=/d' + /app/share/dbus-1/services/com.mitchellh.ghostty.service + > /app/share/dbus-1/services/com.mitchellh.ghostty-debug.service + - rm /app/share/dbus-1/services/com.mitchellh.ghostty.service sources: - type: dir path: .. diff --git a/flatpak/com.mitchellh.ghostty.yml b/flatpak/com.mitchellh.ghostty.yml index 1b119c11b..9ba64dc0e 100644 --- a/flatpak/com.mitchellh.ghostty.yml +++ b/flatpak/com.mitchellh.ghostty.yml @@ -47,6 +47,10 @@ modules: --prefix /app --search-prefix /app --system $PWD/vendor/p + + # Remove references to the user service. Flatpak does not export those. + - sed -i '/^SystemdService=/d' + /app/share/dbus-1/services/com.mitchellh.ghostty.service sources: - type: dir path: ..