forked from Mirrors/flatpak-builder
Add systemd user units corresponding to the D-Bus session services
Signed-off-by: Simon McVittie <smcv@debian.org>tingping/wmclass
parent
2f38ec6521
commit
9efe31e8d4
12
Makefile.am
12
Makefile.am
|
@ -14,9 +14,12 @@ endif
|
|||
%.service: %.service.in config.log
|
||||
$(AM_V_GEN) $(SED) -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
|
||||
|
||||
servicedir = $(DBUS_SERVICE_DIR)
|
||||
dbus_servicedir = $(DBUS_SERVICE_DIR)
|
||||
service_in_files = $(NULL)
|
||||
service_DATA = $(NULL)
|
||||
dbus_service_DATA = $(NULL)
|
||||
systemduserunit_DATA = $(NULL)
|
||||
CLEANFILES += $(dbus_service_DATA)
|
||||
CLEANFILES += $(systemduserunit_DATA)
|
||||
|
||||
AM_CPPFLAGS = \
|
||||
-DXDG_APP_BINDIR=\"$(bindir)\" \
|
||||
|
@ -64,7 +67,10 @@ EXTRA_DIST += $(completion_DATA)
|
|||
|
||||
profiledir = $(sysconfdir)/profile.d
|
||||
profile_DATA = xdg-app.sh
|
||||
EXTRA_DIST += profile/xdg-app.sh.in $(service_in_files)
|
||||
EXTRA_DIST += \
|
||||
$(dbus_service_in_files) \
|
||||
profile/xdg-app.sh.in \
|
||||
$(NULL)
|
||||
DISTCLEANFILES += xdg-app.sh
|
||||
|
||||
xdg-app.sh: profile/xdg-app.sh.in
|
||||
|
|
|
@ -60,6 +60,14 @@ AC_ARG_WITH(dbus_service_dir,
|
|||
DBUS_SERVICE_DIR=$with_dbus_service_dir
|
||||
AC_SUBST(DBUS_SERVICE_DIR)
|
||||
|
||||
AC_ARG_WITH([systemduserunitdir],
|
||||
[AS_HELP_STRING([--with-systemduserunitdir=DIR],
|
||||
[Directory for systemd user service files (default=PREFIX/lib/systemd/user)])],
|
||||
[],
|
||||
dnl This is deliberately not ${libdir}: systemd units always go in
|
||||
dnl .../lib, never .../lib64 or .../lib/x86_64-linux-gnu
|
||||
[with_systemduserunitdir='${prefix}/lib/systemd/user'])
|
||||
AC_SUBST([systemduserunitdir], [$with_systemduserunitdir])
|
||||
|
||||
AC_ARG_WITH(system_fonts_dir,
|
||||
AS_HELP_STRING([--with-system-fonts-dir=PATH],[Directory where system fonts are, [default=/usr/share/fonts]]),
|
||||
|
|
|
@ -23,9 +23,11 @@ document-portal/xdp-resources.c: document-portal/xdg-document-portal.gresource.x
|
|||
$(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) $< \
|
||||
--target=$@ --sourcedir=$(srcdir) --c-name _xdg_document --generate-source
|
||||
|
||||
service_in_files += document-portal/xdg-document-portal.service.in
|
||||
systemduserunit_DATA += document-portal/xdg-document-portal.service
|
||||
|
||||
service_in_files += document-portal/org.freedesktop.portal.Documents.service.in
|
||||
service_DATA += document-portal/org.freedesktop.portal.Documents.service
|
||||
DISTCLEANFILES += document-portal/org.freedesktop.portal.Documents.service
|
||||
dbus_service_DATA += document-portal/org.freedesktop.portal.Documents.service
|
||||
|
||||
EXTRA_DIST += document-portal/xdg-document-portal.gresource.xml
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
[D-BUS Service]
|
||||
Name=org.freedesktop.portal.Documents
|
||||
Exec=@libexecdir@/xdg-document-portal
|
||||
SystemdService=xdg-document-portal.service
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
[Unit]
|
||||
Description=xdg-app document portal service
|
||||
|
||||
[Service]
|
||||
BusName=org.freedesktop.portal.Documents
|
||||
ExecStart=@libexecdir@/xdg-document-portal
|
||||
Type=dbus
|
|
@ -12,9 +12,11 @@ session-helper/xdg-app-resources.c: session-helper/xdg-app.gresource.xml $(resou
|
|||
$(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) $< \
|
||||
--target=$@ --sourcedir=$(srcdir) --c-name _gtk --generate-source
|
||||
|
||||
service_in_files += session-helper/xdg-app-session-helper.service.in
|
||||
systemduserunit_DATA += session-helper/xdg-app-session-helper.service
|
||||
|
||||
service_in_files += session-helper/org.freedesktop.XdgApp.service.in
|
||||
service_DATA += session-helper/org.freedesktop.XdgApp.service
|
||||
DISTCLEANFILES += session-helper/org.freedesktop.XdgApp.service
|
||||
dbus_service_DATA += session-helper/org.freedesktop.XdgApp.service
|
||||
|
||||
EXTRA_DIST += session-helper/xdg-app.gresource.xml
|
||||
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
[Unit]
|
||||
Description=xdg-app session helper
|
||||
|
||||
[Service]
|
||||
BusName=org.freedesktop.XdgApp
|
||||
ExecStart=@libexecdir@/xdg-app-session-helper
|
||||
Type=dbus
|
Loading…
Reference in New Issue