From 45f1eecdd63f9e4fa93fef01dd826e7706ac6d7b Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 27 May 2022 16:35:46 +0100 Subject: configure, meson: move symlinking of ROMs to meson MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is useful because pc-bios/meson.build already has a list of all ROM files, and thus does not need to use wildcards. The problems with wildcards are mentioned above the definition of the LINKS variable, but then the recommendation is disattended. Reviewed-by: Richard Henderson Signed-off-by: Paolo Bonzini Message-Id: <20220517092616.1272238-6-pbonzini@redhat.com> Signed-off-by: Alex Bennée Message-Id: <20220527153603.887929-17-alex.bennee@linaro.org> --- pc-bios/meson.build | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'pc-bios') diff --git a/pc-bios/meson.build b/pc-bios/meson.build index c86dedf..41ba1c0 100644 --- a/pc-bios/meson.build +++ b/pc-bios/meson.build @@ -23,7 +23,7 @@ if unpack_edk2_blobs endforeach endif -blobs = files( +blobs = [ 'bios.bin', 'bios-256k.bin', 'bios-microvm.bin', @@ -83,11 +83,18 @@ blobs = files( 'npcm7xx_bootrom.bin', 'vof.bin', 'vof-nvram.bin', -) +] -if get_option('install_blobs') - install_data(blobs, install_dir: qemu_datadir) -endif +ln_s = [find_program('ln', required: true), '-sf'] +foreach f : blobs + roms += custom_target(f, + build_by_default: have_system, + output: f, + input: files('meson.build'), # dummy input + install: get_option('install_blobs'), + install_dir: qemu_datadir, + command: [ ln_s, meson.project_source_root() / 'pc-bios' / f, '@OUTPUT@' ]) +endforeach subdir('descriptors') subdir('keymaps') -- cgit v1.1