mirror of
https://gitlab.gnome.org/GNOME/gitg
synced 2024-10-01 05:33:49 +00:00
meson: Fix valadoc documentation generation
autotools is able to generate documentation by using the `valadoc` program. However, meson is not able to generate this documentation. meson build files has been fixed to be able to generate `valadoc` documentation.
This commit is contained in:
parent
8e7da995f9
commit
5a32e34935
|
@ -84,7 +84,7 @@ pkg.generate(
|
|||
)
|
||||
|
||||
# FIXME: does not work due to missing proper valadoc support
|
||||
if enable_docs
|
||||
if get_option('docs')
|
||||
vala_pkgs = [
|
||||
'--pkg', 'ggit-1.0',
|
||||
'--pkg', 'gio-2.0',
|
||||
|
@ -94,18 +94,20 @@ if enable_docs
|
|||
]
|
||||
|
||||
valaproc_cmd = [
|
||||
valadoc,
|
||||
find_program('valadoc'),
|
||||
'--directory', join_paths(source_root, 'docs'),
|
||||
'--package-name', 'gitgext',
|
||||
vala_pkgs,
|
||||
'--basedir', source_root,
|
||||
'--vapidir', join_paths(build_root, 'gitg'),
|
||||
sources,
|
||||
'--vapidir', vapi_dir,
|
||||
'--vapidir', libgitg_dir,
|
||||
sources + [join_paths(libgitg_build_dir, libgitg_vapi_name)],
|
||||
]
|
||||
|
||||
run_target(
|
||||
'libgitg-ext-docs',
|
||||
command: valaproc_cmd,
|
||||
depends: libgitg,
|
||||
)
|
||||
endif
|
||||
|
||||
|
|
|
@ -47,6 +47,7 @@ pkg = import('pkgconfig')
|
|||
source_root = meson.current_source_dir()
|
||||
build_root = meson.current_build_dir()
|
||||
|
||||
libgitg_dir = join_paths(source_root, 'libgitg')
|
||||
po_dir = join_paths(source_root, 'po')
|
||||
vapi_dir = join_paths(source_root, 'vapi')
|
||||
|
||||
|
@ -173,12 +174,6 @@ config_h.set_quoted('PLATFORM_NAME', platform_name)
|
|||
|
||||
g_ir_compiler = find_program('g-ir-compiler')
|
||||
|
||||
enable_docs = get_option('docs')
|
||||
if enable_docs
|
||||
docs_dir = join_paths(source_root, 'docs')
|
||||
valadoc = find_program('valadoc')
|
||||
endif
|
||||
|
||||
subdir('po')
|
||||
subdir('contrib/xml')
|
||||
subdir('contrib/ide')
|
||||
|
|
Loading…
Reference in a new issue