From: Zbigniew Jędrzejewski-Szmek Date: Sun, 16 May 2021 13:43:41 +0000 (+0200) Subject: meson: use custom configuration_data() object for man/man and man/html helpers X-Git-Tag: v249-rc1~210^2~24 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=195a8a93278632ca114c622366524f688ecc609a;p=thirdparty%2Fsystemd.git 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. --- diff --git a/man/meson.build b/man/meson.build index 2e3b858f4f3..b21631b873c 100644 --- a/man/meson.build +++ b/man/meson.build @@ -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) diff --git a/meson.build b/meson.build index f43e9a775c3..214096b726d 100644 --- a/meson.build +++ b/meson.build @@ -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) #####################################################################