meson: Handle man pages symlinks with a meson install script

This seems to be the common way to handle that, until meson decides to
address #1602: https://github.com/mesonbuild/meson/issues/1602

Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
This commit is contained in:
Arnaud Rebillout 2018-11-05 12:05:35 +07:00 committed by Arun Raghavan
parent 6826c60da5
commit b15428d4bb

View file

@ -1,5 +1,3 @@
# TODO How are symlinks installed by meson?
# We might need meson.add_install_script()
# man page name, section, [aliases]
manpages = [
@ -57,13 +55,8 @@ foreach tuple : manpages
)
foreach alias : aliases
link = custom_target(
alias,
output : alias,
command : ['ln', '-fs', man, '@OUTPUT@'],
install : true,
install_dir : mandirn,
)
dst = join_paths(mandirn, alias)
meson.add_install_script('ln', '-fs', man, dst)
endforeach
if xmllint.found()