summaryrefslogtreecommitdiffstats
path: root/doc/dbus/meson.build
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 14:41:01 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 14:41:01 +0000
commitcc02f613f361981a338db8916e7516e5001253c0 (patch)
tree2a83d7350ec7b2877249a1588891d718caf56c06 /doc/dbus/meson.build
parentInitial commit. (diff)
downloadgnome-session-cc02f613f361981a338db8916e7516e5001253c0.tar.xz
gnome-session-cc02f613f361981a338db8916e7516e5001253c0.zip
Adding upstream version 3.38.0.upstream/3.38.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'doc/dbus/meson.build')
-rw-r--r--doc/dbus/meson.build46
1 files changed, 46 insertions, 0 deletions
diff --git a/doc/dbus/meson.build b/doc/dbus/meson.build
new file mode 100644
index 0000000..12ebce6
--- /dev/null
+++ b/doc/dbus/meson.build
@@ -0,0 +1,46 @@
+ifaces_refs = []
+
+ifaces = [
+ 'org.gnome.SessionManager',
+ 'org.gnome.SessionManager.Client',
+ 'org.gnome.SessionManager.ClientPrivate',
+ 'org.gnome.SessionManager.Inhibitor',
+ 'org.gnome.SessionManager.Presence'
+]
+
+gnome_session_dir = join_paths(meson.source_root(), 'gnome-session')
+spec_to_docbook = files('spec-to-docbook.xsl')
+
+foreach iface: ifaces
+ iface_ref = iface + '.ref.xml'
+
+ ifaces_refs += custom_target(
+ iface_ref,
+ input: files(join_paths(gnome_session_dir, iface + '.xml')),
+ output: iface_ref,
+ command: [xsltproc, '--output', '@OUTPUT@', spec_to_docbook, '@INPUT@']
+ )
+endforeach
+
+session_conf = configuration_data()
+session_conf.set('VERSION', session_version)
+
+session = meson.project_name()
+
+xml_in = configure_file(
+ input: session + '.xml.in',
+ output: session + '.xml',
+ configuration: session_conf
+)
+
+config_xsl = files('config.xsl')
+
+custom_target(
+ session,
+ input: xml_in,
+ output: session + '.html',
+ command: [find_program('xmlto'), 'xhtml-nochunks', '-o', meson.current_build_dir(), '-m', config_xsl, '@INPUT@'],
+ depends: ifaces_refs,
+ install: true,
+ install_dir: join_paths(session_datadir, 'doc', meson.project_name(), 'dbus')
+)