qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Joel Granados <joel.granados@kernel.org>, qemu-devel@nongnu.org
Cc: "Alex Bennée" <alex.bennee@linaro.org>, "Thomas Huth" <thuth@redhat.com>
Subject: Re: [PATCH] build: Replace meson introspection argument with a builddir
Date: Mon, 24 Feb 2025 11:57:24 +0100	[thread overview]
Message-ID: <5ea3a240-1805-40f8-9c5d-af12794ea34c@redhat.com> (raw)
In-Reply-To: <20250204-jag-fix_meson-v1-1-ecb6bdb1db51@kernel.org>

On 2/4/25 21:10, Joel Granados wrote:
> Replace the meson introspect argument with the build directory instead
> of the meson.build file. The introspect command accepts an optional
> build directory not a file.
> 
> Signed-off-by: Joel Granados <joel.granados@kernel.org>
> ---
> For some reason this causes an error when I "remote" compile qemu.
> In any case, the introspect only accepts directories, so having it point
> the to the meson.build file is a mistake.

Unfortunately, the help for "meson introspect" doesn't tell the whole 
story...  Instead, https://mesonbuild.com/IDE-integration.html under 
"Build options" says:

    Since Meson 0.50.0 it is also possible to get the default
    buildoptions without a build directory by providing the root
    meson.build instead of a build directory to meson introspect
    --buildoptions.

    Running --buildoptions without a build directory produces the same
    output as running it with a freshly configured build directory.

The idea here is to make it possible to update the meson-buildoptions.sh 
script even in case the build directory if somehow hosed.  So I'd rather 
avoid this patch if possible.

What's the error that you have and do you have a reproducer?

Paolo

> Comments are greatly appreciated
> ---
>   Makefile | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Makefile b/Makefile
> index b65b0bd41a..da88d9bb31 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -129,7 +129,7 @@ Makefile.mtest: build.ninja scripts/mtest2make.py
>   .PHONY: update-buildoptions
>   all update-buildoptions: $(SRC_PATH)/scripts/meson-buildoptions.sh
>   $(SRC_PATH)/scripts/meson-buildoptions.sh: $(SRC_PATH)/meson_options.txt
> -	$(MESON) introspect --buildoptions $(SRC_PATH)/meson.build | $(PYTHON) \
> +	$(MESON) introspect --buildoptions $(BUILD_DIR) | $(PYTHON) \
>   	  scripts/meson-buildoptions.py > $@.tmp && mv $@.tmp $@
>   endif
>   
> 
> ---
> base-commit: d922088eb4ba6bc31a99f17b32cf75e59dd306cd
> change-id: 20250204-jag-fix_meson-43db4d290315
> 
> Best regards,



  parent reply	other threads:[~2025-02-24 10:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-04 20:10 [PATCH] build: Replace meson introspection argument with a builddir Joel Granados
2025-02-24  9:49 ` Thomas Huth
2025-02-24 10:57 ` Paolo Bonzini [this message]
2025-02-27 10:07   ` Joel Granados
2025-02-27 10:19     ` Paolo Bonzini
2025-02-27 10:38       ` Peter Maydell
2025-02-28 14:11         ` Joel Granados

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=5ea3a240-1805-40f8-9c5d-af12794ea34c@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=joel.granados@kernel.org \
    --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).