[glib: 2/9] doc: Add back gdbus-object-manager-example



commit 6e8a7c2cd4859a731c21dd259d01c587fe0614ab
Author: Xavier Claessens <xavier claessens collabora com>
Date:   Tue Jul 9 14:57:54 2019 -0400

    doc: Add back gdbus-object-manager-example
    
    This requires Meson 0.52.0 for the return value of gnome.gtkdoc().

 docs/reference/gio/gdbus-object-manager-example/meson.build | 10 ++++++++++
 docs/reference/gio/meson.build                              |  6 ++++--
 docs/reference/gio/migrating-gdbus.xml                      |  4 ++--
 gio/tests/gdbus-object-manager-example/meson.build          |  6 ++++--
 gio/tests/meson.build                                       |  5 +++++
 5 files changed, 25 insertions(+), 6 deletions(-)
---
diff --git a/docs/reference/gio/gdbus-object-manager-example/meson.build 
b/docs/reference/gio/gdbus-object-manager-example/meson.build
new file mode 100644
index 000000000..126e67731
--- /dev/null
+++ b/docs/reference/gio/gdbus-object-manager-example/meson.build
@@ -0,0 +1,10 @@
+gdbus_object_manager_example_doc = gnome.gtkdoc('gdbus-object-manager-example',
+  main_xml : 'gdbus-object-manager-example-docs.xml',
+  namespace : 'example',
+  dependencies : [libgdbus_example_objectmanager_dep],
+  src_dir : 'gio/tests/gdbus-object-manager-example',
+  scan_args : gtkdoc_common_scan_args + [
+    '--rebuild-types',
+  ],
+)
+
diff --git a/docs/reference/gio/meson.build b/docs/reference/gio/meson.build
index a93296de7..c8b44a0aa 100644
--- a/docs/reference/gio/meson.build
+++ b/docs/reference/gio/meson.build
@@ -1,4 +1,5 @@
 if get_option('gtk_doc')
+  subdir('gdbus-object-manager-example')
   subdir('xml')
 
   ignore_headers = [
@@ -132,8 +133,6 @@ if get_option('gtk_doc')
     'xdp-dbus.c',
   ]
 
-  # FIXME: ExampleAnimal docs aren't built
-
   docpath = join_paths(glib_datadir, 'gtk-doc', 'html')
   version_conf = configuration_data()
   version_conf.set('VERSION', meson.project_version())
@@ -188,6 +187,9 @@ if get_option('gtk_doc')
       'gresource.xml',
       'gdbus.xml',
       'gdbus-codegen.xml',
+      gdbus_example_objectmanager_xml,
+      gdbus_example_objectmanager_sources,
+      gdbus_object_manager_example_doc,
     ],
     expand_content_files : [
       'overview.xml',
diff --git a/docs/reference/gio/migrating-gdbus.xml b/docs/reference/gio/migrating-gdbus.xml
index 75855522c..5e2d46474 100644
--- a/docs/reference/gio/migrating-gdbus.xml
+++ b/docs/reference/gio/migrating-gdbus.xml
@@ -297,8 +297,8 @@ gdbus-codegen --interface-prefix org.gtk.GDBus.Example.ObjectManager. \
 
   </section>
 
-  <xi:include 
href="../gdbus-example-objectmanager-generated-org.gtk.GDBus.Example.ObjectManager.Animal.xml"/>
-  <xi:include href="../gdbus-example-objectmanager-generated-org.gtk.GDBus.Example.ObjectManager.Cat.xml"/>
+  <xi:include 
href="../../../../gio/tests/gdbus-object-manager-example/objectmanager-gen-org.gtk.GDBus.Example.ObjectManager.Animal.xml"/>
+  <xi:include 
href="../../../../gio/tests/gdbus-object-manager-example/objectmanager-gen-org.gtk.GDBus.Example.ObjectManager.Cat.xml"/>
   <xi:include href="../gdbus-object-manager-example/xml/ExampleAnimal.xml"/>
   <xi:include href="../gdbus-object-manager-example/xml/ExampleCat.xml"/>
   <xi:include href="../gdbus-object-manager-example/xml/ExampleObject.xml"/>
diff --git a/gio/tests/gdbus-object-manager-example/meson.build 
b/gio/tests/gdbus-object-manager-example/meson.build
index 404c37788..4cfb848d3 100644
--- a/gio/tests/gdbus-object-manager-example/meson.build
+++ b/gio/tests/gdbus-object-manager-example/meson.build
@@ -1,6 +1,7 @@
 # FIXME: set UNINSTALLED_GLIB_{SRC|BUILD}DIR=top_{src|build}dir ?
+gdbus_example_objectmanager_xml = files('gdbus-example-objectmanager.xml')
 gdbus_example_objectmanager_generated = custom_target('objectmanager-gen',
-  input  : ['gdbus-example-objectmanager.xml'],
+  input  : gdbus_example_objectmanager_xml,
   output : ['objectmanager-gen.h',
             'objectmanager-gen.c',
             'objectmanager-gen-org.gtk.GDBus.Example.ObjectManager.Animal.xml',
@@ -23,4 +24,5 @@ libgdbus_example_objectmanager = library('gdbus-example-objectmanager',
 
 libgdbus_example_objectmanager_dep = declare_dependency(
   sources : gdbus_example_objectmanager_generated[0],
-  link_with : libgdbus_example_objectmanager)
+  link_with : libgdbus_example_objectmanager,
+  dependencies : [libgio_dep])
diff --git a/gio/tests/meson.build b/gio/tests/meson.build
index 6345eab7f..c639c0292 100644
--- a/gio/tests/meson.build
+++ b/gio/tests/meson.build
@@ -431,6 +431,11 @@ test_extra_programs += {
   },
 }
 
+gdbus_example_objectmanager_sources = files(
+  'gdbus-example-objectmanager-client.c',
+  'gdbus-example-objectmanager-server.c',
+)
+
 if cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
   test_extra_programs += {
     # These three are manual-run tests because they need a session bus but don't bring one up themselves


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