summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2025-05-29AstInterpreter: Fix evaluate_* functionsVolker Weißmann
Some of the evaluate_* functions in AstInterpreter seem very broken and do not even evaluate all of the AST. I do not know what the original author thought, so I just fixed it.
2025-05-29rewriter: Refactoring of assignment trackingVolker Weißmann
Replace `AstInterpreter.reverse_assignment` with `AstInterpreter.all_assignment_nodes`. This does not give us an immediate advantage but will be useful in future commits.
2025-05-29rewriter: Replace assignments with cur_assignmentsVolker Weißmann
Replace the variable tracking of `AstInterpreter.assignments` with a slightly better variable tracking called `AstInterpreter.cur_assignments`. We now have a class `UnknownValue` for more explicit handling of situations that are too complex/impossible.
2025-05-29Add AstInterpreter.nestingVolker Weißmann
The AstInterpreter now stores how deep into if/elif/else we are. This is currently dead code, but it will be read in future commits.
2025-05-29rewriter.py: make type safeVolker Weißmann
2025-05-29rewriter: Add IntrospectionDependencyVolker Weißmann
To improve type-safety and readability we replace a dictionary with a new class `IntrospectionDependency`.
2025-05-29rewriter: Add IntrospectionBuildTargetVolker Weißmann
To improve type-safety and readability we replace a dictionary with a new class `IntrospectionBuildTarget`.
2025-05-29rewritetests.py: Ignore order of listed sourcesVolker Weißmann
The order in which the rewriter outputs the listed sources is more or less arbitrary anyways, so we ignore it to prevent the tests from breaking after small irrelevant changes.
2025-05-29Refactoring and removal of dead codeVolker Weißmann
2025-05-29parser: Fix colno after multiline stringsVolker Weißmann
Without this commit, meson thinks that the `var` token in the code below starts at a different column number than it actually starts, because the old author forgot to account for the length of the triple quotes. ``` ''' some multiline strings abc''' + var ```
2025-05-29AstPrinter: Add parenthesis where neccessaryVolker Weißmann
2025-05-29parser: Simplify precedence levelsVolker Weißmann
The parser should behave exactly as before, but the code is a bit easier to understand now.
2025-05-29AstPrinter: Use str.translate instead of str.replaceVolker Weißmann
2025-05-29rewriter: Don't ignore the `name_prefix` kwargVolker Weißmann
2025-05-26vs2010backend: fix EmbedManifest state when /MANIFEST:EMBED is usedPeter Harris
With introduction of dfd8cfbd8d9c VS compile is broken for cases where /MANIFEST:EMBED linker flag is actually used. The fix keeps the default creation of <EmbedManifest> but adopts the same strategy as e3db7af0ea41, that is to scan the link flags for the embed case to decide state is emit 'true' or 'false' for EmbedManifest.
2025-05-26vs2010backend: Escape linker argumentsPeter Harris
This allows linker arguments containing a space (or other special character) to pass through to the linker correctly. For example, the spaces in "test cases/windows/25 embed manifest" when using meson.project_source_root().
2025-05-25ci: ubuntu-rolling: update for zig distfile renamingSam James
They've changed it from "linux-x86_64" to "x86-64-linux".
2025-05-25tests: don't skip frameworks/17 mpi for auto/pkgconfigSam James
This is fixed in Ubuntu rolling now and Bionic wasn't affected to begin with. Bug: https://bugs.debian.org/1078026
2025-05-25Unbreak "Fix setuptools 49 test. (fixes #7452)"Eli Schwartz
This unbreaks commit 59910c437a81b94c72e3cbdfc2c3612fae576d6e. It kind of maybe appears to fix something but does break it all quite terribly too. Totally random subdirectories of site-packages/ should certainly not be added to PYTHONPATH regardless of anything else as that may include mesonbuild/, leading to `import ast` finding mesonbuild.ast instead... The underlying issue here is that egg .pth is not loaded from PYTHONPATH at all, which means depending on versions of e.g. setuptools this test may end up solely testing system-installed meson, or fail entirely. So we can fix this by manually adding eggs specifically.
2025-05-23cmake: Fix toolchain including unsupported languagesL. E. Segovia
The most egregious cases are Nasm (which needs to be transformed to `ASM_NASM`) and Rust (which is not yet supported by CMake). See https://cmake.org/cmake/help/v4.0/command/project.html
2025-05-23options: process project options before machine optionsPaolo Bonzini
Restore the behavior from before commit d37d649b0 ("Make all Meson level options overridable per subproject.", 2025-02-13). The old code was: options: T.MutableMapping[OptionKey, T.Any] = OrderedDict() # process project default options for k, v in default_options.items(): if not subproject or k.subproject == subproject: options[k] = v # override them with machine default and command line options options.update(env.options) env.options = options Fixes: #14608 Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-23ci: do not update pip on macosPaolo Bonzini
The workaround in commit 2f146775e ("Work around the mising RECORD file with homebrew pip.", 2025-05-04) is brittle and has broken again. Do not bother updating setuptool and pip at all, they should be relatively up to date on homebrew. Suggested-by: Eli Schwartz <eschwartz93@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-23gnome: initialize CFLAGS environment variable to linker argumentsPaolo Bonzini
The CFLAGS environment variable is used for g-ir-scanner's linking pass, It is emptied since commit 237513dff ("modules/gnome, modules/Python: Allow injecting RPATH flags through LDFLAGS if needed", 2025-04-09); which could even be considered a bugfix if it didn't break Fedora quite badly. I could not write a testcase, but the culprit seems to be the -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 that Fedora places in CFLAGS. The file contains *cc1_options: + %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}} and the lack of -fPIE option upsets the linker. Fix by priming the contents of the CFLAGS variable with the c_link_args being used for the build. Fixes: #14631 Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-23gnome: fix typo in creating gir flagsPaolo Bonzini
Append to scan_env_ldflags instead of overwriting it. Fixes: #14631 Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-23vulkan: Add regression test with VULKAN_SDK variableArjan Molenaar
Add test cases that target the Vulkan system dependeny resolver explicitly.
2025-05-23vulkan: Extract Vulkan version in SDK pathArjan Molenaar
This change ensures that Vulkan will be found in the path defined by the VULKAN_SDK env var. This is the case when the Vulkan SDK is not installed in a well-known location (/usr, /usr/local), but in a user's home folder.
2025-05-23vulkan: Make VK_SDK_PATH optionalArjan Molenaar
VULKAN_SDK is the preferred environment variable to point to the Vulkan installation. With this change the old variable (VK_SDK_PATH) is made optional.
2025-05-22Use two hashes in snippet.Jussi Pakkanen
2025-05-22docs: Add response files entryL. E. Segovia
See https://github.com/mesonbuild/meson/pull/14391
2025-05-22support .version() for overridden executablesFlorian "sp1rit"​
Also ensure that .get_version() can be called on the output of _find_tool by the modules (kind of required for #14422).
2025-05-22gnome.mkenums: Allow passthrough of ExternalPrograms to enable converting ↵L. E. Segovia
only the real arguments to response file
2025-05-22gnome.mkenums: Use rspfiles on Windows when possibleL. E. Segovia
Fixes #6710
2025-05-21options: accept build options in --reconfigure or "meson configure"Paolo Bonzini
Make more of the first-invocation logic apply to subsequent configuration of the build tree. This also opens the door for using set_option_maybe_root for the first invocation. This is a huge cleanup but also a larger change, and therefore not something for stable branches. Leave it for later. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-21options: accept compiler and built-in options in --reconfigure and "meson ↵Paolo Bonzini
configure" Follow the same logic that is used at the end of the first invocation. This fixes meson setup --reconfigure -Db_ndebug=true on a project that has no language that defines b_ndebug. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-21options: commonize code to accept unknown optionsPaolo Bonzini
The check for unknown options is duplicated in OptionStore and MesonApp. Place the better version of the two as a new method of OptionStore, and use it in OptionStore.validate_cmd_line_options. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-21options: remove unnecessary Union[OptionKey, str]Paolo Bonzini
classify_D_arguments returns a list with OptionKeys in it. Rename the function so that the difference with set_option is clear. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-21cuda: add test for libs in stubs/David Seifert
2025-05-21cuda: look for stubbed libraries tooDavid Seifert
Some libraries in CUDA are stubbed out to load the actual implementation from the driver at runtime. One example is NVML, that only exists in `stubs/`. Ensure that the stubs dir is searched last, like FindCUDAToolkit.cmake: https://github.com/Kitware/CMake/blob/4f2482700b6a6231c697b1178239acf76955bfeb/Modules/FindCUDAToolkit.cmake#L1163-L1173
2025-05-21cuda: avoid `-l` arguments for linkingDavid Seifert
When trying to pick between a CUDA library that has both shared and static libraries and the same basename, e.g. `libnvidia-ml.a` and `libnvidia-ml.so`, it becomes impossible to pick a specific variant with `-l` arguments.
2025-05-21compilers: add option for ignoring system dirsDavid Seifert
2025-05-21wrap: Support gzip Content-Encoding when fetching WrapDB metadataBenjamin Gilbert
When fetching wrap files and releases.json, ask for gzipped data and decompress it if the server obliges. Wrap files come from GitHub releases, thus from Azure blob storage, and Azure currently doesn't compress these responses. releases.json comes from Git master, and GitHub does support compression there, reducing the response body from ~64 KiB to ~10 KiB. That's a small change in absolute terms, but straightforward to support.
2025-05-20Update email address in .mailmap.Jussi Pakkanen
2025-05-20CI: always install llvm for MSYS2Christoph Reiter
Due to some recent package splits llvm is no longer installed when clang is installed and the meson test suite was depending on the transitive dependency. Instead explicitly install llvm in all cases.
2025-05-19docs: Note that debug=false does not define NDEBUGPaul Caprioli
2025-05-15docs: mention masm support in release notesZephyr Lykos
2025-05-15test masm compilation on vs backendZephyr Lykos
2025-05-15vs2010backend: Initial MASM language supportZephyr Lykos
2025-05-15coredata: remove unused argumentsPaolo Bonzini
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-15coredata: assert compiler OptionKeys have the right shapePaolo Bonzini
The subproject and machine should already be correct, thanks to form_compileropt_key. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-05-15introspection: do not reinvent process_compiler_optionsPaolo Bonzini
Let add_compiler_options and process_compiler_options handle subprojects, and also run it for the main project to ensure that pending_options are properly processed. This exposes a bug because "comp" could have been None, so fix that. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>