meson: Use @BASENAME@ more

This patch takes care of just the obvious cases: there are
many more situations where the data we pass to configure_file()
could likely be obtained in a more effective way, but we can
address the low-hanging fruits as a first approximation.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
This commit is contained in:
Andrea Bolognani 2020-08-25 18:30:57 +02:00
parent 31fb929eca
commit 88c3490aa1
5 changed files with 11 additions and 11 deletions

View File

@ -25,7 +25,7 @@ include_conf.merge_from(conf)
libvirt_common_h = configure_file(
input: libvirt_common_h_in,
output: 'libvirt-common.h',
output: '@BASENAME@',
configuration: include_conf,
)

View File

@ -106,7 +106,7 @@ configmake_conf.set_quoted('SYSCONFDIR', sysconfdir)
configure_file(
input: 'configmake.h.in',
output: 'configmake.h',
output: '@BASENAME@',
configuration: configmake_conf,
)
@ -2335,7 +2335,7 @@ run_conf = configuration_data()
run_conf.set('abs_builddir', meson.build_root())
configure_file(
input: 'run.in',
output: 'run',
output: '@BASENAME@',
configuration: run_conf,
)
run_command('chmod', 'a+x', meson.current_build_dir() / 'run')

View File

@ -6,7 +6,7 @@ potfiles_conf.set('BUILDDIR', '')
potfiles = configure_file(
input: 'POTFILES.in',
output: 'POTFILES',
output: '@BASENAME@',
configuration: potfiles_conf,
)

View File

@ -93,7 +93,7 @@ if conf.has('WITH_NETWORK')
configure_file(
input: 'default.xml.in',
output: 'default.xml',
output: '@BASENAME@',
command: [
'sed', '-e', 's|</name>|</name>\\n <uuid>@0@</uuid>|'.format(uuid),
'@INPUT@',
@ -105,7 +105,7 @@ if conf.has('WITH_NETWORK')
else
configure_file(
input: 'default.xml.in',
output: 'default.xml',
output: '@BASENAME@',
copy: true,
install: true,
install_dir: confdir / 'qemu' / 'networks',

View File

@ -235,7 +235,7 @@ tools_conf.set('sysconfdir', sysconfdir)
configure_file(
input: 'virt-xml-validate.in',
output: 'virt-xml-validate',
output: '@BASENAME@',
configuration: tools_conf,
install: true,
install_dir: bindir,
@ -244,7 +244,7 @@ configure_file(
configure_file(
input: 'virt-pki-validate.in',
output: 'virt-pki-validate',
output: '@BASENAME@',
configuration: tools_conf,
install: true,
install_dir: bindir,
@ -254,7 +254,7 @@ configure_file(
if conf.has('WITH_SANLOCK')
configure_file(
input: 'virt-sanlock-cleanup.in',
output: 'virt-sanlock-cleanup',
output: '@BASENAME@',
configuration: tools_conf,
install: true,
install_dir: sbindir,
@ -264,7 +264,7 @@ endif
configure_file(
input: 'libvirt-guests.sh.in',
output: 'libvirt-guests.sh',
output: '@BASENAME@',
configuration: tools_conf,
install: true,
install_dir: libexecdir,
@ -280,7 +280,7 @@ if init_script == 'systemd'
configure_file(
input: 'libvirt-guests.service.in',
output: 'libvirt-guests.service',
output: '@BASENAME@',
configuration: tools_conf,
install: true,
install_dir: prefix / 'lib' / 'systemd' / 'system',