[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/2] bsd-user: Only process meson rules on BSD host

From: Paolo Bonzini
Subject: Re: [PATCH 1/2] bsd-user: Only process meson rules on BSD host
Date: Tue, 5 Oct 2021 21:23:39 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.1.0

On 27/09/21 11:54, Peter Maydell wrote:
True, but "meson.build is evaluated but just does nothing or
adds files to a sourceset that isn't used" is pretty common
(hw/pci/meson.build is evaluated even if we're not building
a system with PCI support, for example).

Selection of files from hw/pci/meson.build is based on per-target definitions, so there's no way around when:/if_true:. (Technically, hw/pci/meson.build also as an if_false, so there's *really* no way around parsing it).

Instead, when the definition is constant across all targets, it is possible to use either when:/if_true: or an "if" as in

if have_user

or the various "if m[0].found()" found in directories that build shared modules. In this case I personally lean more towards the latter, but when:/if_true: is a little more compact so both are acceptable.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]