summaryrefslogtreecommitdiff
path: root/mesonbuild/modules
AgeCommit message (Collapse)Author
2025-12-08qt.compile_moc: look for targets in dependenciesDavid Véron
If qt.compile_moc dependencies contain targets. The generated build does not exibit this dependency ie it is possible that the dependency build is run concurrently with MOC. Tell the generator that the MOC calls depends on targets in dependencies to be generated.
2025-12-05modules/cuda: Cuda 13.0 doesn't support the 10.1 profileDylan Baker
Even thought 12.8 and 12.9 do. So don't add then when we have 13
2025-12-05modules/cuda: Update arch flags for versions through 13.0Dylan Baker
This includes adding Blackwell support, as well as the deprecation of many older architectures in 12.9 and 13.0
2025-12-05modules/cuda: Update versions up through 13.0.2Dylan Baker
There is currently no Windows versions for 13.0.x I've marked with comments versions where a new release has the same version as the previous release. This should help reduce the number of list iterations, but also make easier to keep this list up to date.
2025-12-05modules/cuda: Pull driver table out of class bodyDylan Baker
This makes use of a small class to simplify the implementation
2025-11-30Revert "Detect dependency changes in Windows rc compiler"Jussi Pakkanen
This reverts commit 632115ecff3bd7f9cb519098e04e0467b0cfd3a1.
2025-11-28modules/snippets: Define a macro for public APIs on OS/2KO Myung-Hun
2025-11-19compilers: Remove Environment parameter from RustCompiler.get_rustdocDylan Baker
2025-11-19compilers: Remove Environment parameter from Compiler.has_headerDylan Baker
2025-11-19compilers: Remove Environment parameter from Compiler.sizeofDylan Baker
This also fixes the `_cross_sizeof` helper
2025-11-19compilers: Remove Environment parameter from Compiler.sanitizer_argsDylan Baker
2025-11-19compilers: Remove Environment parameter from Compiler.has_multi_argumentsDylan Baker
2025-11-18modules/windows: Also search for llvm-rc and llvm-windresLuca Bacci
Fixes #15011
2025-11-18rust.proc_macro: fix type of kwargs["native"]Paolo Bonzini
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-11-14Add `shortname' kwarg for a short DLL name on OS/2KO Myung-Hun
Give an user opportunities to mangle a custom short name for a DLL on OS/2.
2025-11-12compilers: pass target and env to sanitizer_*_argsPaolo Bonzini
The Rust compiler will need these to check the rust_nightly option. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-11-05interpreter: Add rust_crate_type to kwargs TypeDictDylan Baker
2025-11-05modules/codegen: fix typo bug introduced by rebaseDylan Baker
When the mechanism to set the name of methods was changed this bug was introduced.
2025-10-29Add snippets.symbol_visibility_header() methodXavier Claessens
Defining public API in a cross platform library is painful, especially on Windows. Since every library have to define pretty much the same macros, better do it in Meson.
2025-10-29modules: Fix state.project_name valueXavier Claessens
It was the name of root project instead of current subproject. This is only used by pkgconfig generator. While at it, simplify the way we get the project version.
2025-10-24modules/codegen: Add support for bison/byacc/yaccDylan Baker
This adds a similar wrapper to the Lex wrapper for yacc/bison/byacc. The interface is equivalent.
2025-10-24modules/codegen: Add wrapper for lex/flex/reflexDylan Baker
This module is a bit of a dumping ground for code generators, particularly ones that are important and non-trivial to wrap, either due to multiple implementations, major command line changes, or complex outputs (such as those that may output a directory structure). The initially provided method is for lex. It provides a simple wrapper that handles win_flex, reflex, flex, and generic lex.
2025-10-20interpreter: fix more default_options annotationsDylan Baker
2025-10-20interpreter: use typed_kwargs for checking disabler dependencyDylan Baker
2025-10-20interpreter: remove permittedKwargs from dependencyDylan Baker
This is also the ideal time to remove the `allow_unknown` from `typed_kwargs`, as permittedKwargs was providing extra key checking, so now `typed_kwargs` can do that instead.
2025-10-20modules/python: port dependency embed to typed_kwargsDylan Baker
2025-10-20interpreter: port dependency required to typed_kwargsDylan Baker
2025-10-20interpreter: port dependency native to typed_kwargsDylan Baker
2025-10-20interpreter: port dependency modules to typed_kwargsDylan Baker
2025-10-20interpreter: port dependency method to typed_kwargsDylan Baker
This allows us a bunch of nice things: 1. We can use the DependencyMethods enum everywhere 2. The deprecated methods can be checked in the Interpreter, so we can now emit deprecation warnings for stuff that was deperecated in 0.44! 3. We can share this more strongly typed method everywhere
2025-10-20interpreter: port dependency include_type to typed_kargsDylan Baker
The cleanup this allows lower down points out that we don't properly validate the value passed to `as_system()`. I have no idea what happens if you pass a non-valid value, but it's a bug and I've simply made it a hard error. We can re-assess if necessary.
2025-10-20dependency: Use a TypedDict to describe the keyword arguments to DependencyDylan Baker
This allows us to check that all of the keyword arguments are of the correct type.
2025-10-16build: do not pass Interpreter to Generator.process_filesPaolo Bonzini
All that is needed is the subdir, pass it explicitly (and make it an optional argument so that the backend does not have to pass it). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-10-16build: store Environment in GeneratorPaolo Bonzini
Objects like targets already store the environment in which they were created, do the same for Generator: pass it to the constructor and use it in process_files. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-10-16qt: remove stale commentPaolo Bonzini
There is no generator list in the Interpreter. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-10-15revert local_program()Eli Schwartz
This reverts https://github.com/mesonbuild/meson/pull/15107 Explicit objections regarding the design were raised and not answered, so it shouldn't have been merged. It needs to be discussed and revisited.
2025-10-15build: remove validation for name prefix and suffixDylan Baker
2025-10-15build: use a TypedDict for Executable kwargsDylan Baker
2025-10-15build: Add a TypedDict for BuildTarget keyword argumentsDylan Baker
This has the "processed" keyword arguments that the interpreter is supposed to create for us, or that we expect internal users to build by build. This requires some hacking around in the rust module for the moment because we suddenly have a type.
2025-10-15Add common ABC for ExternalProgram and LocalProgramXavier Claessens
2025-10-15Replace OverrideExecutable and OverrideProgram with LocalProgramXavier Claessens
2025-10-15Add support for LocalProgram to override_find_program()Xavier Claessens
2025-10-15module/rust: set _FILE_OFFSET_BITS=64 for bindgenDavid Rheinsberg
Meson sets 64-bit offsets as the default for all platforms but MSVC. Lets do the same for bindgen, to ensure we get compatible definitions. Do this by calling `get_always_args()` on the first C'ish host compiler we can find. Note that the `libc` crate does not expose 64-bit types as the default and there is no intention to do so. Instead, it exposes 32-bit default types, plus the 64-bit extended types with the `*64` suffix. This is quite unfortunate, but it seems unlikely to change [1]. However, use of `bindgen` is usually not tied to the `libc` crate. Instead, it is tied to whatever other C code in the same project does. And Meson sets `_FILE_OFFSET_BITS=64` unconditionally for all this C code. It thus seems much more plausible for Meson to also imply it for bindgen. Given that Rust code that uses the `libc` crate very likely already uses the `*64` suffixed variants, they are unaffected by whether `_FILE_OFFSET_BITS=64` is set. If they use `libc::off_t`, they already explicitly state that they use the 32-bit variant on 32-bit platforms. Hence, it is inherently incompatible to C code that uses `_FILE_OFFSET_BITS=64`. And lastly, if a Meson project is Rust-only, but generates its internal code from its public C headers, then it is better suited to actually call `add_language('c')` and ensure that Meson knows what the compiler configuration for the target platform actually is. Otherwise, bindgen cannot know what platform options to enable. Hence, warn loudly if `rust.bindgen()` is used without a configured C compiler (even if the compiler used by bindgen does not necessarily match the configured one). [1] https://github.com/rust-lang/libc/issues/3223#issuecomment-2033298952
2025-10-14Detect dependency changes in Windows rc compilerCharles Brunet
The `rc.exe` resource compiler neither provides *depfile* support nor allows showing includes, as is possible with C or C++ compilers. Therefore, changes to files included by the `.rc` file did not trigger recompilation of the resource file. A workaround was added to *meson* by calling the preprocessor on the `.rc` file to detect the included headers and adding the result as a dependency to the resource compilation.
2025-10-14Make use of build TypeAliasesDylan Baker
There are a lot of spelled out unions for these types, lets reduce that number
2025-10-14pkgconfig: Improve handling of empty string depsEyal Itkin
Fix the original bug fix for #13950 to only warn about empty required strings, instead of failing the entire build. This will simplify the workflow for users that build the string from a possibly empty list, and save them the need for the added if-check. Signed-off-by: Eyal Itkin <eyal.itkin@gmail.com>
2025-10-11pkgconfig: Handle malformatted string dependenciesEyal Itkin
Add missing checks for correctness of string dependency, including case for malformatted versioned dependency. Resolves #13950. Signed-off-by: Eyal Itkin <eyal.itkin@gmail.com>
2025-10-06hotdoc: remove HotdocTargetBuilder.get_valuePaolo Bonzini
The method is unused since commit c8aecc768 ("hotdoc module: add partially typed kwargs", 2022-10-24). Found while looking for callers of OptionStore.get_value. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-10-06options: replace get_value with get_value_forPaolo Bonzini
The two methods are identical. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2025-10-01Allow CustomTarget source for i18n.xgettextCharles Brunet
Fixes #15054