qemu-commits
[Top][All Lists]
Advanced

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

[Qemu-commits] [qemu/qemu] 95e82f: meson: check in main meson.build for


From: Daniel Berrangé
Subject: [Qemu-commits] [qemu/qemu] 95e82f: meson: check in main meson.build for native Rust c...
Date: Mon, 14 Oct 2024 09:04:42 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 95e82f9b38a1fa5b2b99103e3685750b3c5a084b
      
https://github.com/qemu/qemu/commit/95e82f9b38a1fa5b2b99103e3685750b3c5a084b
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2024-10-14 (Mon, 14 Oct 2024)

  Changed paths:
    M meson.build
    M rust/qemu-api-macros/meson.build

  Log Message:
  -----------
  meson: check in main meson.build for native Rust compiler

A working native Rust compiler is always needed in order to compile Rust
code, even when cross compiling, in order to build the procedural macros
that QEMU uses.

Right now, the check is done in rust/qemu-api-macros/meson.build, but this
has two disadvantages.  First, it makes the build fail when the Meson "rust"
option is set to "auto" (instead, Rust support should be disabled).  Second,
add_languages() is one of the few functions that are executed even by
"meson introspect", except that "meson introspect" executes both branches
of "if" statements!  Therefore, "meson introspect" tries to look for a
Rust compiler even if the option is disabled---and then fails because
the compiler is required by rust/qemu-api-macros/meson.build.  This is
visible for example if the compilation host has a stale
scripts/meson-buildoptions.sh and no rustc installed.

Both issues can be fixed by moving the check to the main meson.build,
together with the check for the cross compiler.

Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


  Commit: 4aa94ae08d81329e41c109a6ca3bda293b14f93a
      
https://github.com/qemu/qemu/commit/4aa94ae08d81329e41c109a6ca3bda293b14f93a
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2024-10-14 (Mon, 14 Oct 2024)

  Changed paths:
    M configure
    M meson_options.txt

  Log Message:
  -----------
  configure, meson: synchronize defaults for configure and Meson Rust options

If the defaults for --enable-rust ($rust in configure) and Meson's rust
option are out of sync, incremental builds will pick Meson's default.

This happens because, on an incremental build, configure does not run
Meson, Make does instead.  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 used.

This will cause have_rust to be true if rustc is available; and the build
to fail because configure did not put a RUST_TARGET_TRIPLE in config-host.mak.

When in the Rust pull request I changed the $rust default from auto
to disabled, I should have made the same change to meson_options.txt;
do it now.

Cc: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
Reported-by: Peter Maydell <peter.maydell@linaro.org>
Reported-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Tested-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 20241014110113.173946-1-pbonzini@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


  Commit: aa54f5be44be786636a5d51cc1612ad208a24849
      
https://github.com/qemu/qemu/commit/aa54f5be44be786636a5d51cc1612ad208a24849
  Author: Daniel P. Berrangé <berrange@redhat.com>
  Date:   2024-10-14 (Mon, 14 Oct 2024)

  Changed paths:
    M .gitlab-ci.d/cirrus/freebsd-14.vars
    M tests/docker/dockerfiles/opensuse-leap.docker
    M tests/lcitool/libvirt-ci
    M tests/vm/generated/freebsd.json

  Log Message:
  -----------
  tests: update lcitool to fix freebsd py311-yaml rename

This addresses the py311-yaml -> py311-pyyaml rename in FreeBSD.

The change to the OpenSUSE dockerfile is something that will allow
QEMU to access rust bindgen in future.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-id: 20241014130255.10119-1-berrange@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


Compare: https://github.com/qemu/qemu/compare/3860a2a8de56...aa54f5be44be

To unsubscribe from these emails, change your notification settings at 
https://github.com/qemu/qemu/settings/notifications



reply via email to

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