libei/doc/protocol/meson.build
Peter Hutterer 2671079754 doc: drop the special sha for the hugo theme, update hugo instead
The special sha is no longer needed, let's bump to a recent version of
hugo instead and that should make it all work nicely (for a while).

Updating hugo requires changing to hugo.toml and forcing mermaid to be
enabled, without those changes the build failed with
 `failed to extract shortcode: template for shortcode "mermaid" not found`

This reverts commit 5909717700

Part-of: <https://gitlab.freedesktop.org/libinput/libei/-/merge_requests/358>
2025-08-28 14:35:59 +10:00

25 lines
678 B
Meson

if 'protocol' not in get_option('documentation')
subdir_done()
endif
hugo = find_program('hugo', required : false)
if not hugo.found()
error('Program "hugo" not found or not executable. Try building with -Ddocumentation=false')
endif
src_script = files('generate-protocol-docs.sh')
hugo_script = find_program(src_script)
src_hugo = files(
'hugo.toml',
'interface.md.tmpl',
) + src_script
custom_target('hugo',
input : src_hugo + [protocol_xml],
output : [ 'doc' ],
command : [ hugo_script, '--git-repo', meson.project_source_root(), '--output-dir', meson.current_build_dir() ],
install : false,
build_by_default : true,
)