aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2021-04-04Bump to 0.57.2 for release0.57Nirbheek Chauhan2-2/+2
2021-04-04tests: Add a test for the _FOR_BUILD env varsDylan Baker1-0/+20
2021-04-04environment: get environment variables for both host and build machinesDylan Baker2-14/+17
Fixes #8605
2021-04-04unittests: extend machine file override tests for CFLAGS (and friends)Dylan Baker1-5/+10
They behave slightly differently than other env vars, so have a test for them as well.
2021-04-04Split environment variable and command line cflagsDylan Baker4-7/+60
They are supposed to have different behavior. The environment variables apply to both the compiler and linker when the compiler acts as a linker, but the command line ones do not. Fixes #8345
2021-04-04coredata: Fix dependency cacheDylan Baker1-1/+1
The host cache had BUILD, which is wrong.
2021-04-04Strip host-compiler -std flag from NVCC line.Olexa Bilaniuk3-1/+36
Closes #8523.
2021-04-04Retract "DQSQ" merging in NVCC arguments handling.Olexa Bilaniuk1-15/+0
No coverage, no tests, unreadable, unused, likely premature optimization.
2021-04-04Canonicalize and merge consecutive -Xcompiler flags together.Olexa Bilaniuk1-1/+47
Makes command-line more readable.
2021-04-04mtest: timeout if the write side of pipes does not closePaolo Bonzini1-11/+39
If a test program forks a child, the pipes might remain open and "await stdo_task"/"await stde_task" will never complete in SingleTestRunner._run_cmd(). Instead, catch them in TestSubprocess.wait() so that the whole process group is killed. Fixes: #8533 Reported-by: Bastien Nocera <hadess@hadess.net>
2021-04-04mtest: remove pointless try/except from try_wait_onePaolo Bonzini1-5/+3
asyncio.wait does not return an asyncio.TimeoutError, so there is no exception to catch.
2021-04-04cmd_line_file.txt: Use cross/native file path resolved by coredataXavier Claessens2-2/+6
This fix issue when using --wipe and the machine file was passed as a pipe and written locally, or when the file was resolved in XDG_DATA_HOME or XDG_DATA_DIRS. Fixes: #8560
2021-04-04msetup: do not print bogus "Option ... is:" messagesPaolo Bonzini2-2/+8
get_non_matching_default_options is checking a string from project_default_options against a validated value from coredata.options. Passing the string to validate_value ensures that the comparison is sound; otherwise, "false" might be compared against False and a bogus difference is printed.
2021-04-04coredata: be more robust on unpickling errorsPaolo Bonzini1-1/+1
When reverting from 0.57 to 0.56, one can see an error like this: File /Users/pm215/src/qemu-for-merges/meson/mesonbuild/coredata.py, line 1016, in load obj = pickle.load(f) ModuleNotFoundError: No module named 'mesonbuild.mesonlib.universal'; 'mesonbuild.mesonlib' is not a package FAILED: build.ninja The reason is that the old version fails to resolve mesonbuild.mesonlib, which is a similar situation to the existing AttributeError check. Raise a MesonException for ModuleNotFoundError as well, so that reconfiguration proceeds using cmd_line.txt.
2021-04-04Fix run_targets running scripts from different subdirs.Jussi Pakkanen4-0/+16
2021-04-04interpreter: Cache found dependency before converting for include_typeXavier Claessens7-7/+35
Fixes: #8516.
2021-04-04Fix duplicate pkg_config_path entriesTristan Partin2-2/+14
Previously builds would *potentially* get sammed with messaging at configure time that duplicate entries in an array would be an error in the future, and the cause was because the same entries were getting added over and over to pkg_config_path.p
2021-04-04minstall: Correctly set uid/gid of installed filesPeter Kjellerstedt2-2/+2
In commit caab4d3d, the uid and gid arguments passed to os.chown() by set_chown() were accidentally swapped, causing files to end up with incorrect owner/group if the owner and group are not the same. Also update the documentation to better indicate which argument to install_mode is which. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
2021-04-04Fix Fortran dep scanner for upper case file extensions. Closes #8395.Jussi Pakkanen3-2/+3
2021-04-04mintro: include the correct target filenames for flat layoutPaolo Bonzini2-2/+23
Fixes: #8408
2021-04-04mintro: fix flake8 issuesPaolo Bonzini1-1/+1
2021-04-04pkgconfig: Add missing permitted kwargsXavier Claessens1-1/+1
Fixes #8462
2021-04-04Windows Subsystem for Linux can run .exe without mono interpreterXavier Claessens2-1/+4
Fixes: #8445
2021-04-04exernal_project: Fix default cross compile parametersLeif Middelschulte1-1/+1
The variable `{host}` cannot be successfully expanded. Using the `@HOST@` parameter, as suggested by the documentation, works.
2021-04-04mtest: create separate runners for multiple repeatsPaolo Bonzini2-18/+27
Reusing the runners for multiple repeats of the test run gets in the way of the progress report, which stores runners in an OrderedSet. Instead, create a separate SingleTestRunner object for each repeat. While at it, fix the "duplicate suite" assertion as it can fire with TAP tests and --repeat=N. Fixes: #8405
2021-04-04Require Windows 10 or newer for the MSI package. [skip ci]Jussi Pakkanen1-0/+12
2021-04-04Add filecmp to list of bundled modules. Closes #8431. [skip ci]Jussi Pakkanen1-0/+1
2021-04-04Remove remnants of 32 bit support. [skip ci]Jussi Pakkanen1-8/+4
2021-04-04interpreter: correctly track whether a subproject is initializedDylan Baker6-1/+35
The way the tracking is currently done it works if no new subprojects are added to a configured build directory. For cases where we want to add a new subproject, it fails because we don't initialize builtins for that subproject. This corrects that by checking to see if the subproject already exists, and if it doesn't initializes the bultins for it. Fixes: #8421
2021-04-04Bugfix: Forward sanitizer_*_args() methods to host compiler.Olexa Bilaniuk3-0/+40
Enables -Db_sanitize=undefined and company. Also serves as a testcase for NVCC comma-shielding: Because the test- case declares `b_sanitize=address,undefined`, the host GCC compiler needs `-fsanitize=address,undefined`, but this stands a danger of being split by NVCC when wrapped with `-Xcompiler=args,args`. Special, already-existing comma-shielding codepaths activate to prevent this splitting. Closes #8394.
2021-02-20Bump to 0.57.1 for release0.57.1Nirbheek Chauhan2-2/+2
2021-02-20Fix combining C and Fortran. Closes #8377.Jussi Pakkanen3-4/+23
2021-02-20Fix TAP parser when test exits with statusLuke Drummond3-1/+12
Some time between 0.56 and 0.57 the TAP parser broke when a test exits with a nonzero status. The TAP protocol does not specify this behaviour - giving latitude to implementers, and meson's previous behaviour was to report the exit status gracefully. This patch restores the old behaviour and adds a regression test
2021-02-20Ensure that $lang_args and $lang_link_args are properly parsedDylan Baker4-16/+41
Currently we don't handle things correctly if we get a string we should split, and the linker and needs compiler arguments. It would result in two unsplit strings in a list, instead of the split arguments in a list Fixes: #8348
2021-02-20environment: Allow setting build options in cross filesDylan Baker1-4/+11
This did work previously, so we need to let it continue working. I'm proposing removing it in 0.60 because the correct solution has always worked. I've also been a bit more defensive here, and made setting `subproject:opt = foo` in the machine files an error, as we have `[subproject:built-in options]` or `[subproject:project options]` for that.
2021-02-20allow build.b_* optionsDylan Baker2-2/+6
These continue to be ignored as they always have, but no longer raise an error. Fixes: #8354
2021-02-20Disable failing Cygwin GIR test.Jussi Pakkanen6-0/+22
2021-02-20Don't access other enum members from selfMiro Hrončok1-3/+4
This is deprecated in Python 3.10. Instead, acces them from the class. Fixes https://github.com/mesonbuild/meson/issues/8318
2021-02-20ci: Fix failure in unit tests with vs backendXavier Claessens2-3/+3
2021-02-20mtest: use / as path separator for ninja targetsPaolo Bonzini1-1/+7
os.path.relpath(f, wd) returns path with \ seperator on Windows, but ninja targets always uses / separator. See for example https://gitlab.freedesktop.org/ocrete/libnice/-/jobs/7348274. Analyzed-by: Xavier Claessens <xavier.claessens@collabora.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-02-20compilers: Only insert -flto-jobs in clang's link argumentsDylan Baker4-8/+18
Clang has a hand `-Wunused-command-line-argument` switch, which when turned to an error, gets very grump about `-flto-jobs=0` being set in the compiler arguments (although `-flto=` belongs there). We'll refactor a bit to put that only in the link arguments. GCC doesn't have this probably because, a) it doesn't have an equivalent warning, and b) it uses `-flto=<$numthreads. Fixes: #8347
2021-02-20Do not validate options when finding non-matchingDylan Baker4-5/+22
This is a) useless because it's only used to print which options are not default, and b) harmful because it can result in cases where things break, like in projects that set a standard that the chosen compiler doesn't support, but the project (or some subset) can be built with a different standard. Fixes: #8360
2021-02-20Substitute @CURRENT_SOURCE_DIR@ in run_target() and custom_target()Xavier Claessens5-3/+54
run_target() does some variable substitutions since 0.57.0. This is a new behavior, and undocumented, caused by sharing more code with custom_target(). More consistency is better, so document it now. custom_target() was doing variable substitution in the past, because it shared some code with generator(), but that was undocumented. Some refactoring in 0.57.0 caused it to not replace @CURRENT_SOURCE_DIR@, @SOURCE_DIR@, and @BUILD_DIR@ anymore. This patch adds back @CURRENT_SOURCE_DIR@ and document it. It does not add back @SOURCE_DIR@ because it is duplicate with @SOURCE_ROOT@ that has a better name. Also do not add back @BUILD_DIR@ which is duplicate of @PRIVATE_DIR@, and not @BUILD_ROOT@ surprisingly, adding to the confusion.
2021-02-20mconf: only print correct options in the correct sectionsDylan Baker1-2/+2
A predicate in two comprehensions was dropped, in what looks like a rebase error on my part. With the predicate added things work correctly. Fixes: #8344
2021-02-20Environment: Fix passing envrionment variables CPPFLAGS and CFLAGSDylan Baker6-8/+60
Or other language flags that use CPPFLAGS (like CXXFLAGS). The problem here is actually rather simple, `dict.setdefault()` doesn't work like I thought it did, I thought it created a weak entry, but it actually is equivalent to: ```python if k not in dict: dict[k] = v ``` Instead we'll use an intermediate dictionary (a default dictionary actually, since that makes things a little cleaner) and then add the keys from that dict to self.options as applicable. Test case written by Jussi, Fix by Dylan Co-authored-by: Jussi Pakkanen Fixes: #8361 Fixes: #8345
2021-02-20Small patch to unittests to initialize CUDA compiler correctly.Olexa Bilaniuk1-1/+1
Suggested by Dylan Baker.
2021-02-20Add optional -Dcuda_ccbindir= option and -ccbin flag to CUDA compiler.Olexa Bilaniuk2-8/+33
Closes #8110.
2021-02-20Armour-grade quoting to account for NVCC's -Xcompiler peculiarities.Olexa Bilaniuk1-14/+84
2021-02-20Extensive rewrite of GCC/MVSC flag translation to NVCC flags.Olexa Bilaniuk1-31/+313
2021-02-20Add default debug flags for two configurations to NVCC.Olexa Bilaniuk1-2/+2