qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Bulekov <alxndr@bu.edu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Cc: Laurent Vivier <lvivier@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>,
	Thomas Huth <thuth@redhat.com>,
	qemu-devel@nongnu.org
Subject: Re: [PATCH] qtest/libqos/meson: Restrict architecture specific objects
Date: Sun, 14 Mar 2021 19:25:11 -0400	[thread overview]
Message-ID: <20210314232511.4ylyi3jnseec6jps@mozz.bu.edu> (raw)
In-Reply-To: <20210314225308.2582284-1-f4bug@amsat.org>

On 210314 2353, Philippe Mathieu-Daudé wrote:
> Various libqos files are architecture specific.
> Restrict the ARM/PPC/X86 units to their targets.
> 
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---

I thought qos-test is reused for all the machines, and all the arch
checking is done at runtime. Also, are these variables actually defined
when building tests? There seem to be some link failures:

ninja -j`nproc` tests/qtest/qos-test
clang-11  -o tests/qtest/qos-test ...
/usr/bin/ld: tests/qtest/qos-test.p/virtio-blk-test.c.o: in function `pci_hotplug':
undefined reference to `qpci_unplug_acpi_device_test

-Alex

>  tests/qtest/libqos/meson.build | 51 ++++++++++++++++++++++------------
>  1 file changed, 34 insertions(+), 17 deletions(-)
> 
> diff --git a/tests/qtest/libqos/meson.build b/tests/qtest/libqos/meson.build
> index 1cddf5bdaa1..817c2cc2c20 100644
> --- a/tests/qtest/libqos/meson.build
> +++ b/tests/qtest/libqos/meson.build
> @@ -1,4 +1,8 @@
> -libqos_srcs = files('../libqtest.c',
> +libqos_ss = ss.source_set()
> +
> +libqos_ss.add(genh)
> +
> +libqos_ss.add(files('../libqtest.c',
>          'qgraph.c',
>          'qos_external.c',
>          'pci.c',
> @@ -6,18 +10,6 @@
>          'malloc.c',
>          'libqos.c',
>  
> -        # spapr
> -        'malloc-spapr.c',
> -        'libqos-spapr.c',
> -        'rtas.c',
> -        'pci-spapr.c',
> -
> -        # pc
> -        'pci-pc.c',
> -        'malloc-pc.c',
> -        'libqos-pc.c',
> -        'ahci.c',
> -
>          # usb
>          'usb.c',
>  
> @@ -39,7 +31,28 @@
>          'virtio-rng.c',
>          'virtio-scsi.c',
>          'virtio-serial.c',
> +))
>  
> +libqos_ss.add(when: 'TARGET_I386', if_true: files(
> +        'pci-pc.c',
> +        'malloc-pc.c',
> +        'libqos-pc.c',
> +
> +        'ahci.c',
> +
> +        # qgraph machines:
> +        'x86_64_pc-machine.c',
> +))
> +libqos_ss.add(when: 'TARGET_PPC64', if_true: files(
> +        'malloc-spapr.c',
> +        'libqos-spapr.c',
> +        'rtas.c',
> +        'pci-spapr.c',
> +
> +        # qgraph machines:
> +        'ppc64_pseries-machine.c',
> +))
> +libqos_ss.add(when: 'TARGET_ARM', if_true: files(
>          # qgraph machines:
>          'aarch64-xlnx-zcu102-machine.c',
>          'arm-imx25-pdk-machine.c',
> @@ -49,11 +62,15 @@
>          'arm-smdkc210-machine.c',
>          'arm-virt-machine.c',
>          'arm-xilinx-zynq-a9-machine.c',
> -        'ppc64_pseries-machine.c',
> -        'x86_64_pc-machine.c',
> -)
> +))
> +libqos_ss.add(when: 'TARGET_AARCH64', if_true: files(
> +        # qgraph machines:
> +        'aarch64-xlnx-zcu102-machine.c',
> +))
>  
> -libqos = static_library('qos', libqos_srcs + genh,
> +libqos_ss = libqos_ss.apply(config_host, strict: false)
> +
> +libqos = static_library('qos', libqos_ss.sources() + genh,
>                          name_suffix: 'fa',
>                          build_by_default: false)
>  
> -- 
> 2.26.2
> 


      reply	other threads:[~2021-03-14 23:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-14 22:53 [PATCH] qtest/libqos/meson: Restrict architecture specific objects Philippe Mathieu-Daudé
2021-03-14 23:25 ` Alexander Bulekov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210314232511.4ylyi3jnseec6jps@mozz.bu.edu \
    --to=alxndr@bu.edu \
    --cc=f4bug@amsat.org \
    --cc=lvivier@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).