[Spice-devel] [PATCH spice-gtk 01/12] meson: improve gtk-doc build
Frediano Ziglio
fziglio at redhat.com
Mon Jan 21 14:43:49 UTC 2019
>
> From: Marc-André Lureau <marcandre.lureau at redhat.com>
>
> - Fix the following warnings:
> ./spice-gtk-sections.txt:467: warning: No declaration found for
> SPICE_GTK_CHECK_VERSION.
> ./spice-gtk-sections.txt:468: warning: No declaration found for
> SPICE_GTK_MAJOR_VERSION.
> ./spice-gtk-sections.txt:469: warning: No declaration found for
> SPICE_GTK_MICRO_VERSION.
> ./spice-gtk-sections.txt:470: warning: No declaration found for
> SPICE_GTK_MINOR_VERSION.
>
> - fixxref for glib and gtk (thus requires gtk+ to build doc)
>
> - And other minor simplifications.
>
> After autotools is removed, we should try to use --rebuild-types. For
> now I prefer not to touch it :)
>
This last sentence is not related to this commit.
> Signed-off-by: Marc-André Lureau <marcandre.lureau at redhat.com>
> ---
> doc/reference/meson.build | 29 +++++++++++++++++++++++------
> 1 file changed, 23 insertions(+), 6 deletions(-)
>
> diff --git a/doc/reference/meson.build b/doc/reference/meson.build
> index a121e66..c1abeb9 100644
> --- a/doc/reference/meson.build
> +++ b/doc/reference/meson.build
> @@ -38,14 +38,31 @@ ignore_headers = [
>
> spice_gtk_doc_dep = declare_dependency(link_with : [spice_client_gtk_lib,
> spice_client_glib_lib])
>
> -gnome.gtkdoc('spice-gtk',
> - content_files : ['spice-gtk-overrides.txt',
> 'spice-gtk-overrides.txt'],
> +glib_prefix = dependency('glib-2.0').get_pkgconfig_variable('prefix')
> +glib_docpath = join_paths(glib_prefix, 'share', 'gtk-doc', 'html')
> +gtk_prefix = dependency('gtk+-3.0').get_pkgconfig_variable('prefix')
> +gtk_docpath = join_paths(gtk_prefix, 'share', 'gtk-doc', 'html')
> +docpath = join_paths(spice_gtk_datadir, 'gtk-doc', 'html')
> +
> +gnome.gtkdoc(meson.project_name(),
> dependencies : spice_gtk_doc_dep,
> - main_xml : 'spice-gtk-docs.xml',
> - gobject_typesfile : files('spice-gtk.types'),
> + main_xml : meson.project_name() + '-docs.xml',
> + gobject_typesfile : meson.project_name() + '.types',
> ignore_headers : ignore_headers,
> include_directories: spice_gtk_include,
> c_args : '-DSPICE_COMPILATION',
> install : true,
> - scan_args : ['--deprecated-guards="SPICE_DISABLE_DEPRECATED"',
> '--ignore-decorators="G_GNUC_INTERNAL"'],
> - src_dir : join_paths(meson.source_root(), 'src'))
> + scan_args : [
> + '--deprecated-guards="SPICE_DISABLE_DEPRECATED"',
> + '--ignore-decorators="G_GNUC_INTERNAL"',
> + join_paths(meson.build_root(), 'src', 'spice-version.h')
> + ],
> + src_dir : join_paths(meson.source_root(), 'src'),
These last lines were changed since previous version.
What's the reason?
> + fixxref_args: [
> + '--html-dir=@0@'.format(docpath),
> + '--extra-dir=@0@'.format(join_paths(glib_docpath, 'glib')),
> + '--extra-dir=@0@'.format(join_paths(glib_docpath,
> 'gobject')),
> + '--extra-dir=@0@'.format(join_paths(glib_docpath, 'gio')),
> + '--extra-dir=@0@'.format(join_paths(gtk_docpath, 'gtk3')),
> + ],
> + )
Frediano
More information about the Spice-devel
mailing list