aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild
AgeCommit message (Collapse)AuthorFilesLines
2021-10-26message: Allow boolXavier Claessens1-2/+2
It has always been working even if not documented and there is no reason to not accept it. However, change "True/False" to "true/false" to be consistent with meson language. Fixes: #9436
2021-10-26dep.name(): return dependency name even if dependency is not foundThomas Heijligen4-6/+5
The dep.name() function schould always return the name of the dependency as documented. No matter if it was found or not. https://mesonbuild.com/Reference-manual_returned_dep.html#depfound
2021-10-25Add sccache support.Jussi Pakkanen2-2/+26
2021-10-25mcompile: Load coredata first because it checks major versionXavier Claessens1-9/+3
Fixes: #9444
2021-10-24Bump version number for new development.Jussi Pakkanen1-1/+1
2021-10-24Bump version number for release.0.60.0Jussi Pakkanen1-1/+2
2021-10-24Add stdc++20 support for Visual Studio 2019 v16.11Moroz Oleg1-0/+4
fix #9242
2021-10-24interpreter: Fix missing featuer check (fixes #9425)Daniel Mensinger2-0/+10
2021-10-24cmake: Add support for the Linux CMake registry (fixes #9418)Daniel Mensinger1-0/+6
2021-10-21compilers/rust: fix typo in standard descriptionDylan Baker1-1/+1
2021-10-21compilers/rust: add support for the 2021 editionDylan Baker1-1/+1
2021-10-21Add entries for new CUDA Toolkit versions.Olexa Bilaniuk1-0/+2
2021-10-20Add support for win-arm64 to MSVCGabor Kertesz1-1/+5
For Windows on Arm win-arm64 platform, the corresponding vcvars is called now.
2021-10-19Update version number for rc2.0.60.0rc2Jussi Pakkanen1-1/+1
2021-10-19Fix NamedTemporaryFile file reopen issue on Win #9412Gabor Kertesz1-2/+4
NamedTemporaryFile can't be opened by name on Windows. For Windows the created temporary bat file is now closed before passing to a subprocess, prevented from removal automatically upon close and deleted explicitly upon finish.
2021-10-18linkers: detect LLD when built with PACKAGE_VENDORPaolo Bonzini1-3/+3
https://github.com/Homebrew/homebrew-core/commit/e7c972b6062af753e564104e58d1fa20c0d1ad7a added PACKAGE_VENDOR to lld, causing the -v output to start with "Homebrew LLD" rather than just "LLD". Meson no longer detects it and fails the test_ld_environment_variable_lld unit test. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-10-18mtest: limit "magic" CTRL+C behavior to process group leadersPaolo Bonzini1-1/+4
If meson is not a process group leader, a SIGINT will be delivered also to its parent process (and possibly other processes). The parent process then will probably exit and mtest will continue running in the background, without any way to interrupt the run completely. To fix this, treat SIGINT and SIGTERM the same way unless mtest is a process group leader. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-10-16Add missing but expected as exception clauseMatthew Brett1-1/+1
The `except` line was missing its `as e` clause. As a result, when erroring out, after not finding a compiler, Meson gives an error ending: ``` File "C:\Users\Matthew\AppData\Roaming\Python\Python39\site-packages\mesonbuild\mesonlib\vsenv.py", line 100, in setup_vsenv mlog.warning('Failed to activate VS environment:', str(e)) ```
2021-10-15wrap: move FeatureNew checks to a more natural placeEli Schwartz2-14/+18
Now, warnings are unconditionally raised when parsing the wrap file, whether they are used or not. That being said, these warnings literally just check for a couple of keys used in the .wrap ini file. Moving these checks from the time of use to the time of loading, means that we no longer report warnings only when originally downloading or extracting the file or VCS repo. It also means we no longer report warnings in one subproject, when a wrap file is picked up from a different subproject because the first subproject actually does a dependency lookup. This caused issues for the WrapDB tooling, which uses patch_directory everywhere and the superproject requires a suitable minimum version of meson for this... but individual wraps might use a much lower version, and would then raise a warning (in strict mode, converted to an error) when it resolved a dependency from another WrapDB project. Fixes #9118
2021-10-14cuda: Override std=none to avoid host_compiler to emit -std argumentXavier Claessens1-6/+3
2021-10-14optinterpreter: Fix builtin option names not being reserved anymoreXavier Claessens1-18/+2
2021-10-14introspect: include choices for array optionsPaolo Bonzini1-0/+2
There was even a test covering this, but it did not fail due to a typo.
2021-10-13optinterpreter: Downgrade error to deprecationXavier Claessens1-1/+1
2021-10-12interpreter: Fix missing holder entry (fixes #9389)Daniel Mensinger1-0/+2
2021-10-11Bump version number for rc1.0.60.0.rc1Jussi Pakkanen1-1/+1
2021-10-10pkg-config: do not ever successfully detect Strawberry Perl.Eli Schwartz1-0/+4
This is broken and terrible and thus completely unusable. Don't torture users by finding pkg-config on Windows, thus permitting the pkg-config lookup of several dependencies that do not actually work -- which then fails at build time. This also breaks CI for the wrapdb, because Strawberry Perl is provided as part of the base image for the OS (yes, even though it is terribly broken!!!) and anything that depends on e.g. zlib will "find" zlib because of this broken disaster, even though it should use the wrapdb subproject of zlib. It is assumed no one actually wants to mix Strawberry Perl and meson. In fact, some projects, such as gst-build, already unconditionally error out if Strawberry Perl is detected in PATH: error('You have Strawberry Perl in PATH which is known to cause build issues with gst-build. Please remove it from PATH or uninstall it.') Other projects (postgresql) actually do want to build perl extensions, and link to the perl dlls, but absolutely under no circumstances ever want to use its pkg-config implementation. ;) Let's solve this problem by just considering this to not be a valid pkg-config, let the user find another or not have one at all. This change "solves" https://github.com/StrawberryPerl/Perl-Dist-Strawberry/issues/11
2021-10-10simplify some log formatting by splitting out a commonly used format stringEli Schwartz1-5/+4
There are a bunch of cases in a single function where we would want to log the detected path of pkg-config. Formatting this is awkward. Define it once, then use f-strings everywhere. :D
2021-10-10Add --vsenv command line option and active VS only when neededXavier Claessens10-106/+132
2021-10-10improve wraptool searchDaniel Jacobs1-2/+6
2021-10-10Fix typos discovered by codespellChristian Clauss37-69/+69
2021-10-10clangformat: Only format files tracked by git by defaultXavier Claessens1-4/+12
2021-10-10ar linker: generate thin archives for uninstalled static librariesEli Schwartz2-9/+20
Since they will never be used outside of the build directory, they do not need to literally contain the .o files, and references will be sufficient. This covers a major use of object libraries, which is that the static library would potentially take up a lot of space by including another copy of every .o file. Fixes #9292 Fixes #8057 Fixes #2129
2021-10-10linkers: reorganize Ar linker into a base classEli Schwartz1-29/+24
The `init__()` method basically existed solely to be overridden by every derivative class. Better to use it only in the class that needs it. This fixes several warnings, including missing calls to init because we skipped ArLinker due to not wanting it... also get rid of a pointless popen return code saved as pc, which we never checked.
2021-10-10Revert "interpreter: Add FeatureNew check"Eli Schwartz1-12/+0
This reverts commit c0efa7ab22f8900f6fa1dadf0d306ec375569c8d. This was a nice idea, or a beautiful hack depending on your perspective. Unfortunately, it turns out to be a lot harder than we originally thought. By operating on bare nodes, we end up triggering a FeatureNew on anything that isn't a string literal, rather than anything that isn't a string. Since no one else has come up with a better idea for implementing a FeatureNew, let's just revert it. Better to not have a warning, than have it trigger way too often.
2021-10-10msubprojects: implement "packagefiles --save"Eli Schwartz1-2/+36
Copies packagefiles from the subproject back to the patch_directory for safe storage and to check into git etc.
2021-10-10msubprojects: add new subcommand "packagefiles"Eli Schwartz1-1/+28
This will re-apply the meson.build patch overlay, ensuring it is up to date. Also take the opportunity offered by this infrastructure to repatch when performing `update --reset` since internally this will run `git stash` and thus cause the (possibly locally modified) meson.build files to disappear.
2021-10-10Revert "msubprojects: if fetching the remote fails, gracefully fallback to ↵Eli Schwartz1-8/+3
local copy" This reverts commit 4568482316f63c48559b97c9a4771740ed61eca6. As it turns out, the rationale for this was completely bogus. This command doesn't re-apply the patch_directory etc. and in fact there is no command whatsoever that does this. So, this command does not have two purposes, and we are not making one of them more robust -- instead it has one purpose, and we are making it lie about whether it failed. Instead of trying to freeload off of this command, we will just add another command to properly apply patch overlays.
2021-10-10Be more strict about target names with slashes.Jussi Pakkanen1-0/+8
2021-10-10minstall: Ignore ldconfig errors when we did not install librariesXavier Claessens1-9/+22
Fixes: #9241
2021-10-10pkgconfig module: correctly generate Libs search path with absolute install_dirEli Schwartz1-4/+6
For example the OpenRC build files install libraries to install_dir: '/lib' and this works, but causes the generated pkg-config to say: prefix=/usr Libs: -L${prefix}//lib which is both ugly (double //) and resolves to /usr/lib which is exactly what does not work.
2021-10-10Merge pull request #9373 from anarazel/vs-build-speedJussi Pakkanen1-170/+69
backend/vs: Parallelize compilation inside one project
2021-10-09modules/windows: allow CustomTargets with more than one output for ↵Dylan Baker1-17/+20
compile_resources
2021-10-09build: Add missing type annotationDylan Baker1-1/+1
2021-10-09modules/windows: allow CustomTargetIndex for compile_resourcesDylan Baker1-3/+5
In the positional arguments
2021-10-09modules/windows: use typed_kwargsDylan Baker2-22/+46
2021-10-09optinterpreter: Add deprecated kwargXavier Claessens2-2/+32
It can be either: - boolean: the option is completely deprecated. - list: some choices are deprecated. - dict: some choices are deprecated and replaced by another. Fixes: #7444
2021-10-09optinterpreter: Refactor to use typed_pos_args() and typed_kwargs()Xavier Claessens1-121/+99
2021-10-09optinterpreter: Add support for dictionariesXavier Claessens1-0/+7
2021-10-09typed_kwargs: Fix when ContainerTypeInfo is used in a tupleXavier Claessens1-35/+52
info.types could be a tuple like (str, ContainerTypeInfo()). That means we have to check types one by one and only print error if none of them matched. Also fix the case when default value is None for a container type, it should leave the value to None to be able to distinguish between unset and empty list.
2021-10-08python: Add platlibdir and purelibdir optionsXavier Claessens3-7/+20