On Thu, 27 Feb 2025 at 10:20, Paolo Bonzini <pbonz...@redhat.com> wrote: > > On 2/27/25 11:07, Joel Granados wrote: > > Here is the error I see: > > cmd: > > meson introspect --buildoptions /home/joel/src/qemu/meson.build > > > > output: > > meson.build:88:12: ERROR: Unknown compiler(s): [['rustc']] > > The following exception(s) were encountered: > > Running `rustc --version` gave "[Errno 2] No such file or directory: > > 'rustc'" > > Thanks, this helps. > > > When I pass it a builddir it actually gives me all the buildoptions > > (which is what I expect) > > cmd: > > meson introspect --buildoptions /home/joel/src/qemu/bdir > > Yes, the difference is that the builddir version uses the results of > actually executing meson.build, whereas the srcdir version only does > some cursory parsing and always looks at both branches of "if" statements. > > This is actually not a bug, and in fact now I remember why it is using > the srcdir version... Looking at the required languages is needed in > order to figure out language-dependent build options, and the srcdir > version includes the options for all languages that QEMU could use. > > None of the language-dependent options (for example c_std) are surfaced > in meson-buildoptions.sh, which is why your patch works in the first > place. But I think it's a better fix for you to install rustc, since it > will anyway become mandatory sooner or later.
It's not mandatory *now*, though. So I think it would be better to fix whatever this problem is rather than papering over it... -- PMM