[gnome-terminal/benzea/systemd-integration: 1/7] build: Add drop-in to configure scopes for child processes



commit 005bc336184518d92ae9f830486ab7ea5a8f11d4
Author: Benjamin Berg <bberg redhat com>
Date:   Mon Feb 3 14:39:04 2020 +0100

    build: Add drop-in to configure scopes for child processes
    
    This avoids explicitly setting these options and makes it
    self-explanatory how the defaults may be changed by the user.

 src/Makefile.am | 11 +++++++++++
 1 file changed, 11 insertions(+)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index e5a19d6c..a145b387 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -21,6 +21,9 @@ dbusservice_DATA = org.gnome.Terminal.service
 systemduserdir = $(prefix)/lib/systemd/user
 nodist_systemduser_DATA = gnome-terminal-server.service
 
+scopedefaultsdir = $(systemduserdir)/gnome-terminal-.scope.d
+nodist_scopedefaults_DATA = defaults.conf
+
 gnome_terminal_server_built = \
        terminal-marshal.c \
        terminal-marshal.h \
@@ -161,6 +164,13 @@ gnome-terminal-server.service: Makefile
                      echo "BusName=org.gnome.Terminal"; \
                      echo "ExecStart=${libexecdir}/gnome-terminal-server") > $@
 
+defaults.conf: Makefile
+       $(AM_V_GEN) ( echo "[Unit]"; \
+                     echo "CollectMode=inactive-or-failed"; \
+                     echo "[Scope]"; \
+                     echo "KillMode=process"; \
+                     echo "TimeoutStopSec=5s") > $@
+
 terminal-gdbus-generated.c terminal-gdbus-generated.h: org.gnome.Terminal.xml Makefile
        $(AM_V_GEN) $(GDBUS_CODEGEN) \
                        --interface-prefix=org.gnome.Terminal \
@@ -321,6 +331,7 @@ CLEANFILES = \
        stamp-terminal-type-builtins.h \
        org.gnome.Terminal.service \
        gnome-terminal-server.service \
+       gnome-terminal-.scope \
        $(BUILT_SOURCES)
 
 EXTRA_DIST = \


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]