mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-09 03:38:09 +02:00
meson: Improve api documentation build file
the `doc_module` variable has been removed. It was created because its used in the autotools build file but actually `nm_name` variable can be used easily. Different objects used in the documentation target have been grouped together. The content file `version.xml`, and different build files are now added properly.
This commit is contained in:
parent
9d4e1ad5e3
commit
f0b7041063
1 changed files with 30 additions and 23 deletions
|
|
@ -1,45 +1,52 @@
|
|||
doc_module = nm_name
|
||||
|
||||
settings = 'settings-spec'
|
||||
output = settings + '.xml'
|
||||
|
||||
if enable_introspection
|
||||
settings_xml = custom_target(
|
||||
settings = 'settings-spec'
|
||||
output = settings + '.xml'
|
||||
|
||||
inputs = [
|
||||
settings + '.xsl',
|
||||
nm_settings_docs,
|
||||
]
|
||||
|
||||
content_files += custom_target(
|
||||
output,
|
||||
input: nm_settings_docs,
|
||||
input: inputs,
|
||||
output: output,
|
||||
command: [xsltproc, '--output', '@OUTPUT@', join_paths(meson.current_source_dir(), settings + '.xsl'), '@INPUT@'],
|
||||
# FIXME: there is no target depending on this, so it will not be built
|
||||
command: [xsltproc, '--output', '@OUTPUT@', '@INPUT0@', '@INPUT1@'],
|
||||
build_by_default: true,
|
||||
)
|
||||
endif
|
||||
|
||||
configure_file(
|
||||
content_files += configure_file(
|
||||
input: 'version.xml.in',
|
||||
output: '@BASENAME@',
|
||||
configuration: version_conf,
|
||||
)
|
||||
|
||||
filecopier = find_program('cp')
|
||||
foreach intro : introspection_files
|
||||
path = intro[1].split('/')[-1]
|
||||
custom_target(path,
|
||||
input: intro[0],
|
||||
output: path,
|
||||
command: [filecopier, intro[1], '@OUTPUT@'],
|
||||
build_by_default: true,
|
||||
foreach intro: introspection_files
|
||||
output = intro[1].split('/')[-1]
|
||||
|
||||
content_files += custom_target(
|
||||
output,
|
||||
input: intro[0],
|
||||
output: output,
|
||||
command: [filecopier, intro[1], '@OUTPUT@'],
|
||||
build_by_default: true,
|
||||
)
|
||||
endforeach
|
||||
|
||||
custom_target('common.ent',
|
||||
input: common_ent_file,
|
||||
output: 'common.ent',
|
||||
command: [filecopier, '@INPUT@', '@OUTPUT@'],
|
||||
build_by_default: true,
|
||||
output = 'common.ent'
|
||||
|
||||
content_files += custom_target(
|
||||
output,
|
||||
input: common_ent_file,
|
||||
output: output,
|
||||
command: [filecopier, '@INPUT@', '@OUTPUT@'],
|
||||
build_by_default: true,
|
||||
)
|
||||
|
||||
gnome.gtkdoc(
|
||||
doc_module,
|
||||
nm_name,
|
||||
main_xml: 'network-manager-docs.xml',
|
||||
src_dir: meson.current_source_dir(),
|
||||
content_files: content_files,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue