1if get_option('gtk_doc') 2 subdir('gdbus-object-manager-example') 3 subdir('xml') 4 5 ignore_headers = [ 6 'fam', 7 'fen', 8 'gdbus-2.0', 9 'gvdb', 10 'inotify', 11 'kqueue', 12 'libasyncns', 13 'tests', 14 'win32', 15 'xdgmime', 16 'gappinfoprivate.h', 17 'gapplicationimpl.h', 18 'gasynchelper.h', 19 'gcontenttypeprivate.h', 20 'gcontextspecificgroup.h', 21 'gcredentialsprivate.h', 22 'gdbus-daemon-generated.h', 23 'gdbusactiongroup-private.h', 24 'gdbusauth.h', 25 'gdbusauthmechanismanon.h', 26 'gdbusauthmechanismexternal.h', 27 'gdbusauthmechanism.h', 28 'gdbusauthmechanismsha1.h', 29 'gdbusdaemon.h', 30 'gdbusprivate.h', 31 'gdelayedsettingsbackend.h', 32 'gdocumentportal.h', 33 'gdummyfile.h', 34 'gdummyproxyresolver.h', 35 'gdummytlsbackend.h', 36 'gfileattribute-priv.h', 37 'gfileinfo-priv.h', 38 'ghttpproxy.h', 39 'giomodule-priv.h', 40 'gioprivate.h', 41 'giowin32-priv.h', 42 'gio_probes.h', 43 'gio_trace.h', 44 'gio-tool.h', 45 'glocaldirectorymonitor.h', 46 'glocalfileenumerator.h', 47 'glocalfile.h', 48 'glocalfileinfo.h', 49 'glocalfileinputstream.h', 50 'glocalfileiostream.h', 51 'glocalfilemonitor.h', 52 'glocalfileoutputstream.h', 53 'glocalvfs.h', 54 'gmemorymonitordbus.h', 55 'gmemorymonitorportal.h', 56 'gmountprivate.h', 57 'gnativevolumemonitor.h', 58 'gnetworkingprivate.h', 59 'gnetworkmonitorbase.h', 60 'gnetworkmonitornetlink.h', 61 'gnetworkmonitornm.h', 62 'gnetworkmonitorportal.h', 63 'gnotificationbackend.h', 64 'gnotification-private.h', 65 'gopenuriportal.h', 66 'gpollfilemonitor.h', 67 'gportalsupport.h', 68 'gpowerprofilemonitordbus.h', 69 'gpowerprofilemonitorportal.h', 70 'gproxyresolverportal.h', 71 'gregistrysettingsbackend.h', 72 'gresourcefile.h', 73 'gsettingsbackendinternal.h', 74 'gsettings-mapping.h', 75 'gsettingsschema-internal.h', 76 'gsocketinputstream.h', 77 'gsocketoutputstream.h', 78 'gsocks4aproxy.h', 79 'gsocks4proxy.h', 80 'gsocks5proxy.h', 81 'gsubprocesslauncher-private.h', 82 'gthreadedresolver.h', 83 'gtrashportal.h', 84 'gunionvolumemonitor.h', 85 'gunixmount.h', 86 'gunixresolver.h', 87 'gunixvolume.h', 88 'gunixvolumemonitor.h', 89 'gwin32networkmonitor.h', 90 'gwin32api-application-activation-manager.h', 91 'gwin32api-iterator.h', 92 'gwin32api-misc.h', 93 'gwin32api-package.h', 94 'gwin32api-storage.h', 95 'gwin32appinfo.h', 96 'gwin32file-sync-stream.h', 97 'gwin32mount.h', 98 'gwin32packageparser.h', 99 'gwin32resolver.h', 100 'gwin32volumemonitor.h', 101 'thumbnail-verify.h', 102 'xdp-dbus.h', 103 ] 104 105 sections_files = files('gio-sections-common.txt') 106 107 if host_system == 'windows' 108 ignore_headers += [ 109 'gfiledescriptorbased.h', 110 'gunixconnection.h', 111 'gunixcredentialsmessage.h', 112 'gunixmounts.h', 113 'gunixfdlist.h', 114 'gunixfdmessage.h', 115 'gunixinputstream.h', 116 'gunixoutputstream.h', 117 'gunixsocketaddress.h', 118 'gdesktopappinfo.h', 119 'gosxappinfo.h', 120 ] 121 sections_files += files('gio-sections-win32.txt') 122 platform_file = files('gio-docs-win32.xml') 123 else 124 if glib_have_cocoa 125 ignore_headers += ['gdesktopappinfo.h'] 126 else 127 ignore_headers += ['gosxappinfo.h'] 128 endif 129 130 ignore_headers += [ 131 'gwin32inputstream.h', 132 'gwin32outputstream.h', 133 'gwin32registrykey.h', 134 ] 135 platform_file = files('gio-docs-unix.xml') 136 endif 137 138 ignore_sources = [ 139 'kqueue', 140 'tests', 141 'gdbus-daemon-generated.c', 142 'xdp-dbus.c', 143 ] 144 145 docpath = join_paths(glib_datadir, 'gtk-doc', 'html') 146 version_conf = configuration_data() 147 version_conf.set('VERSION', meson.project_version()) 148 configure_file( 149 input: 'version.xml.in', 150 output: 'version.xml', 151 configuration: version_conf 152 ) 153 154 # FIXME: configure_file() does not support more than one file in input 155 # argument. If input argument is omitted then meson checks that all items in 156 # the command array are strings. But if we have an input then extra files 157 # can be passed in command array. 158 # See https://github.com/mesonbuild/meson/issues/5893 159 concat_files_helper = find_program('concat-files-helper.py') 160 configure_file( 161 output : 'gio-sections.txt', 162 input : sections_files[0], 163 command : [concat_files_helper, '@OUTPUT@'] + sections_files, 164 ) 165 166 configure_file( 167 output : 'gio-docs-platform.xml', 168 input : platform_file, 169 copy : true, 170 ) 171 172 content_files = [ 173 'overview.xml', 174 'migrating-posix.xml', 175 'migrating-gnome-vfs.xml', 176 'migrating-gconf.xml', 177 'migrating-gdbus.xml', 178 'gio-querymodules.xml', 179 'glib-compile-schemas.xml', 180 'glib-compile-resources.xml', 181 'gapplication.xml', 182 'gsettings.xml', 183 'gresource.xml', 184 'gdbus.xml', 185 'gdbus-codegen.xml', 186 ] 187 188 content_files += [ 189 gdbus_example_objectmanager_xml, 190 gdbus_example_objectmanager_sources, 191 gdbus_object_manager_example_doc 192 ] 193 194 gnome.gtkdoc('gio', 195 main_xml : 'gio-docs.xml', 196 namespace : 'g', 197 mode : 'none', 198 dependencies : [libgio_dep, libgobject_dep, libglib_dep], 199 src_dir : 'gio', 200 scan_args : gtkdoc_common_scan_args + [ 201 '--rebuild-types', 202 '--ignore-headers=' + ' '.join(ignore_headers), 203 ], 204 mkdb_args : [ 205 '--ignore-files=' + ' '.join(ignore_sources), 206 ], 207 content_files : content_files, 208 expand_content_files : [ 209 'overview.xml', 210 'migrating-posix.xml', 211 'migrating-gnome-vfs.xml', 212 'migrating-gconf.xml', 213 'migrating-gdbus.xml', 214 'gdbus-codegen.xml', 215 ], 216 html_assets : [ 217 'gvfs-overview.png', 218 'menu-example.png', 219 'menu-model.png', 220 ], 221 fixxref_args: [ 222 '--html-dir=' + docpath, 223 '--extra-dir=' + join_paths('gio', '..', 'glib', 'html'), 224 '--extra-dir=' + join_paths('gio', '..', 'gobject', 'html'), 225 ], 226 install: true, 227 check: true, 228 ) 229endif 230 231 232if get_option('man') 233 manpages = ['gapplication', 'gio-querymodules', 'glib-compile-schemas', 234 'glib-compile-resources', 'gsettings', 'gresource', 'gdbus', 235 'gio', 'gdbus-codegen'] 236 foreach page : manpages 237 custom_target(page + '-man', 238 input: page + '.xml', 239 output: page + '.1', 240 command: xsltproc_command, 241 install: true, 242 install_dir: man1_dir) 243 endforeach 244endif 245