On Mon, Oct 14, 2024 at 12:40 PM Peter Maydell <peter.mayd...@linaro.org> wrote: > > On Mon, 14 Oct 2024 at 11:12, Peter Maydell <peter.mayd...@linaro.org> wrote: > > > > On Fri, 11 Oct 2024 at 18:13, Paolo Bonzini <pbonz...@redhat.com> wrote: > > > v2->v3: new patches > > > - scripts/archive-source: find directory name for subprojects > > > - docs: fix invalid footnote syntax > > > - docs: avoid footnotes consisting of just URLs > > > - docs: use consistent markup for footnotes > > > > > > ---------------------------------------------------------------- > > > * first commit for Rust support > > > * add CI job using Fedora + Rust nightly > > > * fix detection of ATOMIC128 on x86_64 > > > * fix compilation with Sphinx 8.1.0 > > > Applied, thanks. > > With this applied, I find that on one of my personal > local dev branches an incremental rebuild fails, because > meson complains about not finding a new enough bindgen, > even though I did not --enable-rust. Meson also complains > about a bogus coredata.dat and we end up running meson > three times before it eventually decides the error is fatal.
The report of coredata.dat is just a warning that it's not able to use any cached data, which is expected when bumping the Meson version. It's definitely going in the "if have_rust and have_system" path. If you have the meson-logs/meson-log.txt and meson-private/cmd_line.txt files, they can help debugging. I'd expect a "rust = disabled" line in the latter... but yes I see what's happening. The test "$rust" != "auto" && meson_option_add "-Drust=$rust" line is only executed when configure runs meson. Here it doesn't, and Makefile just tells Meson to reconfigure itself. Meson then gets the command line options from either coredata.dat (which has everything cached in Python's pickle format) or cmd_line.txt (slow path when Meson version is upgraded), but neither knows about the rust option; and the meson_options.txt default is 'auto'. To sum up: 1) this is specific to incremental builds 2) this is *not* specific to the Meson version change, the coredata.dat warning is a red herring 3) this (mangled) patch would fix it: diff --git a/configure b/configure index 3e38a91616a..8a9a4153310 100755 --- a/configure +++ b/configure @@ -1987,7 +1987,7 @@ if test "$skip_meson" = no; then fi # QEMU options - test "$rust" != "auto" && meson_option_add "-Drust=$rust" + test "$rust" != "disabled" && meson_option_add "-Drust=$rust" test "$cfi" != false && meson_option_add "-Dcfi=$cfi" "-Db_lto=$cfi" test "$docs" != auto && meson_option_add "-Ddocs=$docs" test -n "${LIB_FUZZING_ENGINE+xxx}" && meson_option_add "-Dfuzzing_engine=$LIB_FUZZING_ENGINE" diff --git a/meson_options.txt b/meson_options.txt index 2211f291b2d..fc6d5526d58 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -372,5 +372,5 @@ option('hexagon_idef_parser', type : 'boolean', value : true, option('x86_version', type : 'combo', choices : ['0', '1', '2', '3', '4'], value: '1', description: 'tweak required x86_64 architecture version beyond compiler default') -option('rust', type: 'feature', value: 'auto', +option('rust', type: 'feature', value: 'disabled', description: 'Rust support') and I can send it shortly; fortunately your tree never got a working coredata.dat, so it hasn't stored anywhere the rust=auto value. Paolo Paolo