On Mon, 18 Oct 2021, Michael S. Tsirkin wrote:
> Only rebuild AML for configured targets.
>
> Signed-off-by: Michael S. Tsirkin <m...@redhat.com>
Reviewed-by: Ani Sinha <a...@anisinha.ca>
> ---
> tests/data/acpi/rebuild-expected-aml.sh | 22 +++++++++++++++++++++-
> 1 file changed, 21 insertions(+), 1 deletion(-)
>
> diff --git a/tests/data/acpi/rebuild-expected-aml.sh
> b/tests/data/acpi/rebuild-expected-aml.sh
> index fc78770544..dcf2e2f221 100755
> --- a/tests/data/acpi/rebuild-expected-aml.sh
> +++ b/tests/data/acpi/rebuild-expected-aml.sh
> @@ -12,7 +12,7 @@
> # This work is licensed under the terms of the GNU GPLv2.
> # See the COPYING.LIB file in the top-level directory.
>
> -qemu_bins="./qemu-system-x86_64 ./qemu-system-aarch64"
> +qemu_arches="x86_64 aarch64"
>
> if [ ! -e "tests/qtest/bios-tables-test" ]; then
> echo "Test: bios-tables-test is required! Run make check before this
> script."
> @@ -20,6 +20,26 @@ if [ ! -e "tests/qtest/bios-tables-test" ]; then
> exit 1;
> fi
>
> +if grep TARGET_DIRS= config-host.mak; then
> + for arch in $qemu_arches; do
> + if grep TARGET_DIRS= config-host.mak | grep "$arch"-softmmu;
> + then
> + qemu_bins="$qemu_bins ./qemu-system-$arch"
> + fi
> + done
> +else
> + echo "config-host.mak missing!"
> + echo "Run this script from the build directory."
> + exit 1;
> +fi
> +
> +if [ -z "$qemu_bins" ]; then
> + echo "Only the following architectures are currently supported:
> $qemu_arches"
> + echo "None of these configured!"
> + echo "To fix, run configure --target-list=x86_64-softmmu,aarch64-softmmu"
> + exit 1;
> +fi
> +
> for qemu in $qemu_bins; do
> if [ ! -e $qemu ]; then
> echo "Run 'make' to build the following QEMU executables: $qemu_bins"
> --
> MST
>
>