1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-22 13:33:56 +03:00

meson: use custom configuration_data() object for man/man and man/html helpers

I want to stop using 'substs'. But in this case, configure_file() is nicer
than custom_target(), because it causes meson to immediately generate the
helpers after configuration, so it's possible to do
'meson build && build/man/man ...', without building anything first.

We only substitute one variable here, so let's use a custom configuration_data()
object.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2021-05-16 15:43:41 +02:00 committed by Yu Watanabe
parent 44ff8df777
commit 195a8a9327
2 changed files with 5 additions and 3 deletions

View File

@ -200,12 +200,15 @@ endif
############################################################
buildroot_substs = configuration_data()
buildroot_substs.set_quoted('BUILD_ROOT', project_build_root)
configure_file(
input : 'man.in',
output : 'man',
configuration : substs)
configuration : buildroot_substs)
configure_file(
input : 'html.in',
output : 'html',
configuration : substs)
configuration : buildroot_substs)

View File

@ -319,7 +319,6 @@ substs.set('RC_LOCAL_PATH', get_option('rc-loc
substs.set('MEMORY_ACCOUNTING_DEFAULT', memory_accounting_default ? 'yes' : 'no')
substs.set('STATUS_UNIT_FORMAT_DEFAULT', status_unit_format_default)
substs.set('HIGH_RLIMIT_NOFILE', conf.get('HIGH_RLIMIT_NOFILE'))
substs.set('BUILD_ROOT', project_build_root)
#####################################################################