[libsoup/wip/meson: 59/93] Add support for building the documentation



commit f0b481582cf019720ebb7d3519bf5da48c28b1b1
Author: Tomas Popela <tpopela redhat com>
Date:   Mon Nov 6 16:28:28 2017 +0100

    Add support for building the documentation

 docs/reference/meson.build |   75 ++++++++++++++++++++++++++++++++++++++++++++
 meson.build                |    4 ++
 meson_options.txt          |    6 +++
 3 files changed, 85 insertions(+), 0 deletions(-)
---
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
new file mode 100644
index 0000000..57b2509
--- /dev/null
+++ b/docs/reference/meson.build
@@ -0,0 +1,75 @@
+ignore_headers = [
+  'soup.h',
+  'soup-autocleanups.h',
+  'soup-enum-types.h',
+  'soup-message-private.h',
+  'soup-session-private.h',
+  'soup-auth-basic.h',
+  'soup-auth-digest.h',
+  'soup-auth-ntlm.h',
+  'soup-auth-negotiate.h',
+  'soup-connection.h',
+  'soup-connection-auth.h',
+  'soup-message-queue.h',
+  'soup-path-map.h',
+  'soup-gnome-features.h',
+  'soup-proxy-resolver.h',
+  'soup-proxy-resolver-gnome.h',
+  'soup-proxy-resolver-static.h',
+  'soup-directory-input-stream.h',
+  'soup-http-input-stream.h',
+  'soup-password-manager.h',
+  'soup-password-manager-gnome.h',
+  'soup-converter-wrapper.h',
+  'soup-body-input-stream.h',
+  'soup-body-output-stream.h',
+  'soup-client-input-stream.h',
+  'soup-content-processor.h',
+  'soup-content-sniffer-stream.h',
+  'soup-io-stream.h',
+  'soup-cache-input-stream.h',
+  'soup-filter-input-stream.h',
+  'soup-cookie-jar-sqlite.h',
+  'soup-requester.h',
+  'soup-tld-private.h',
+  'soup-misc-private.h',
+  'soup-proxy-uri-resolver.h',
+  'soup-proxy-resolver-wrapper.h',
+  'soup-proxy-uri-resolver.h',
+  'soup-cache-private.h',
+  'soup-cache-client-input-stream.h',
+  'soup-socket-private.h',
+  'soup-value-utils.h',
+  'soup-xmlrpc-old.h'
+]
+
+mkdb_args = [
+  '--sgml-mode',
+  '--output-format=xml'
+]
+
+scan_args = [
+  '--deprecated-guards=SOUP_DISABLE_DEPRECATED',
+  '--rebuild-types',
+  '--ignore-decorators="SOUP_DEPRECATED\w*\s*\([^)]*\)|SOUP_DEPRECATED\w*|SOUP_AVAILABLE\w*"'
+]
+
+gnome.gtkdoc('libsoup',
+  main_sgml : 'libsoup-2.4-docs.sgml',
+  src_dir : join_paths(meson.source_root(), 'libsoup'),
+  ignore_headers : ignore_headers,
+  mkdb_args : mkdb_args,
+  scan_args : scan_args,
+  dependencies : [
+    glib_dep,
+    libxml_dep
+  ],
+  install : true,
+  content_files: [
+    'build-howto.xml',
+    'client-howto.xml',
+    'request-howto.xml',
+    'server-howto.xml',
+    'session-porting.xml',
+  ]
+)
diff --git a/meson.build b/meson.build
index 759c38f..b3eb14b 100644
--- a/meson.build
+++ b/meson.build
@@ -206,3 +206,7 @@ endif
 subdir('libsoup')
 subdir('examples')
 subdir('tests')
+
+if get_option('enable-gtk-doc')
+  subdir('docs/reference')
+endif
diff --git a/meson_options.txt b/meson_options.txt
index 6ba39ea..4a76937 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -45,3 +45,9 @@ option('enable-vala',
   value : false,
   description : 'Build Vala bindings'
 )
+
+option('enable-gtk-doc',
+  type: 'boolean',
+  value: false,
+  description: 'Enable generating the API reference'
+)


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