Commit Graph

7429 Commits

Author SHA1 Message Date
Vladimír Čunát e4f3894582 dist: recurse into git submodules 2019-04-21 23:13:01 +03:00
Dylan Baker 3edc7f343b coredata: store cross/native files in the same form they will be used (#5224)
* coredata: store cross/native files in the same form they will be used

Currently they're forced to absolute paths when they're stored in the
coredata datastructure, then when they're loaded we de-absolute path
them to check if they're in the system wide directories. This doesn't
work at all, since the ninja backend will generat a dependency on a
file that is in the source directory unless the path was already given
as absolute. This results in builds being retriggereed forever due to
a non-existant file.

The right way to do this is to figure out whether the file is in the
build directory, is absolute, or is in one of the system paths at
creation time, and store that path as absolute. Then the code that
reads the file and the code that generates the dependencies in the
ninja backend just takes the computed list and there is no mismatch
between them.

Fixes #5257

* run_unittests: Add a test for correct native file storage

This tests the bug in #5257
2019-04-21 23:10:02 +03:00
Daniel Mensinger bffd28d4b2 rewriter: fix error message 2019-04-21 22:15:27 +03:00
Jussi Pakkanen 91654674f0
Merge pull request #5289 from mesonbuild/fixxpass
Report xpass results as failures.
2019-04-21 15:15:19 +03:00
Jussi Pakkanen 4e4f97edb3 Can run argument strings with internal Python. Closes #5217. 2019-04-21 15:14:34 +03:00
Jussi Pakkanen e43c9d96d1 Make it work on Cygwin. 2019-04-21 03:04:25 +03:00
Jussi Pakkanen dc2044c56d Report xpass results as failures. 2019-04-21 03:01:04 +03:00
Jussi Pakkanen ce160e1eab
Merge pull request #5250 from jon-turney/test-compiler-report
Add a report of compilers used to run_project_tests.py
2019-04-20 14:36:16 +03:00
Jussi Pakkanen 5c85b50280
Merge pull request #5284 from makise-homura/update_lcc_support
Update lcc support
2019-04-20 14:18:27 +03:00
TheQwertiest bf65660509 Updated meson --help output 2019-04-20 14:17:13 +03:00
makise-homura 0ec71fff34 Fix indentation 2019-04-19 21:01:14 +03:00
makise-homura 94b7ff3823 Correctly find lfortran for Elbrus compiler 2019-04-19 18:39:04 +03:00
makise-homura 29267b7716 Add -std= remap support for Elbrus compiler 2019-04-19 18:08:54 +03:00
makise-homura d016e23932 Handle cpp_debugstl option for Elbrus compiler 2019-04-19 18:06:20 +03:00
makise-homura ebe78a14e6 Making number of arguments consistent in get_library_dirs 2019-04-19 18:03:17 +03:00
makise-homura 54f9ec4510 Fix concatenation of library dirs 2019-04-19 18:02:01 +03:00
Nirbheek Chauhan 2795f942be interpreter: Check the meson version before parsing options
Also add a test for it so we don't regress this in the future.

Closes https://github.com/mesonbuild/meson/issues/5281
2019-04-18 19:18:21 +00:00
Nirbheek Chauhan 2e93ed58c3 unit tests: Skip toolset version test on VS2015 and older 2019-04-18 09:01:23 +00:00
Nirbheek Chauhan 7654db511c vs: Update toolset table for VS 2019
Also add a test to ensure that we don't forget it in the future.
2019-04-18 09:01:23 +00:00
Jon Turney 3c86520b6f Add a test case for dependency(method:'config-tool') with an unknown name
This failed with an exception with 0.49. Fixed by c0166355, but add a
test case to ensure it doesn't regress.
2019-04-18 07:02:39 +00:00
Paolo Bonzini 2942467148 add test case for generator dependencies 2019-04-16 01:46:31 +00:00
Paolo Bonzini c8b414f6b9 vs2010backend: emit dependencies for generators
This is the VS-specific part of the previous commit; the Visual Studio
backend was ignoring dependencies, add an AdditionalInputs element
similar to what add_custom_build does.
2019-04-16 01:46:31 +00:00
Paolo Bonzini 5952256566 vs2010backend: fix flake8 issue
mesonbuild/backend/vs2010backend.py:506:9: F841 local variable action is assigned to but never used
2019-04-16 01:46:31 +00:00
Paolo Bonzini b9774b4485 generator: add dependency on generator in source tree
If find_program() returns a file from the source directory, anything
that uses it should add the file to the dependencies, so that they are
rebuilt whenever the script changes.  Generator is not doing that.

While at it, I am doing two related fixes:

- Generator is not checking whther the generator actually was found,
resulting in a Python error involving NoneType if it isn't.  To minimize
backwards compatibility issues, I am only raising the error when
g.process() is acutally called.

- the error message for custom_target with a nonexisting program
erroneously mention a not-found external program "nonexistingprogram".
The new error is similar to the one I am adding for generators.
2019-04-16 01:46:31 +00:00
Anton Kochkov ad0ba6a911 Add VS2019 backend CI and docs. 2019-04-16 00:11:02 +03:00
Dylan Baker b510bc12ac Shaderc pkg config 2019-04-15 21:43:03 +03:00
Eli Schwartz 3814d698b1 gpgme dependency: verify that pkg-config works on newer gpgme
If the detected gpgme version is recent enough to match the version in
which upstream pkg-config files were added, assert that the default
found dependency is of the pkgconfig type.
2019-04-15 11:09:49 -07:00
Eli Schwartz f5bc0ab44a fix gpgme support by preferring pkg-config where possible
Since gpgme 1.13.0, pkg-config files are available and this is the
preferred way to detect the dependency. Without this, projects that wish
to generate pkg-config files that Requires.private on gpgme, now have
their custom dependency() fallbacks overridden with an incorrect
configtool dependency.
2019-04-15 11:09:49 -07:00
Keefer Rourke 53a7403f10 (#5260) link to builtin options in `library()` fn
As a newcomer to the Meson build system, I found the documentation of the `library()` function to be a bit misleading. Eventually I found what 'user option' referred to after digging through the docs.

This just adds a link back to the page that describes the options that are referred to in this paragraph.
2019-04-15 20:39:16 +03:00
Jon Turney 744ca13ddb
Don't always skip objc/objc++ tests on Windows
These tests can run under MSYS2 using gcc or clang objc/objc++.
2019-04-15 12:07:17 +01:00
Jon Turney 050b7d8584
Note when clang objc/objc++ compiler is Windows targeted
When using clang as an objc/objc++ compiler, identify if it's a Windows
targeted compiler, so that GnuLikeCompiler::get_pic_args() doesn't use
'-fPIC', which clang considers an error for the Window target.

Future work: Factor out parsing the clang target string from the
detectors for various languages.
2019-04-15 12:07:17 +01:00
Jon Turney df0be82dd6
azure: Fix some places where an unexpected compiler is being picked up
Now we have some information in CI logs about what compiler is actually
being used, fix some places where an unexpected compiler is being picked
up.

Avoid picking up gcc-objc and gfortran from PATH in vs2017 image for VS
test runs.

Use clang for objc/objc++ in MSYS2 clang test runs, rather than picking
up gcc from path.

Also install gfortran for fortran tests on Cygwin.
2019-04-15 12:07:17 +01:00
Jon Turney 10749494c8
Flush run_tests output so it appears before the test subprocesses it runs
This makes 'System information', 'Running unittests', etc. appear before
any test output.
2019-04-15 12:07:17 +01:00
Jon Turney 1e9b753c95
Report detected compilers in run_project_tests
v2:
Use compilers.all_languages for the list of known languages
2019-04-15 12:06:58 +01:00
Dylan Baker 79e925b8f6 docs/fallback-wraptool: wrap to 80 characters 2019-04-14 20:54:38 +03:00
Dylan Baker 68f5bfea62 docs: update fallback wraptool docs [skip ci]
Fixes #5229
2019-04-14 20:54:38 +03:00
Nirbheek Chauhan 10468b3a28 interpreter: Warn when environment() ops are overriden
Warn when someone tries to use append() or prepend() on an env var
which already has an operation set on it. People seem to think that
multiple append/prepend operations stack, but they don't.

Closes https://github.com/mesonbuild/meson/issues/5087
2019-04-13 22:53:33 +03:00
Daniel Mensinger c04651fe24 mintro: Fix set_variable plus assign bug (closes #5256) 2019-04-13 09:51:15 +00:00
Elliott Sales de Andrade eaed4aecbe Run postconf scripts absolutely last.
Introspection is broken if they are run any earlier.
2019-04-13 04:30:59 +00:00
Elliott Sales de Andrade e9b4344aee TST: Actually check that postconf introspection works. 2019-04-13 04:30:59 +00:00
Jon Turney e5008b0109
Unfold cross-compilation case from compilers_from_language() 2019-04-12 11:47:29 +01:00
Jon Turney 3fc3695624
Push formatting of compiler version string down into Compiler class 2019-04-12 11:47:28 +01:00
Dylan Baker 0a0b473e84 interpreter: use container explosion where it makes sense
we can avoid writing code like:
a = c[0]
b = c[1]
by using:
a, b = c

or
a = c[0]
b = c[1:]
by using:
a, *b = c

This saves just a bit of code and is a teeny bit faster. But mostly
for less code
2019-04-12 00:24:51 +03:00
Dylan Baker 00a3bb8d69 interpreter: use zip function
Currently this is implemented as range(min(len(a), len(b)), an then
indexing into a and b to get what we actually want. Fortunately python
provides a function called zip that just does this.
2019-04-12 00:24:51 +03:00
TheQwertiest 2499e25476 Added a unit test for built-in options docs 2019-04-12 00:24:07 +03:00
jrl64 a2d222c383 Update Built-in Option c_std for C17. Closes #4842. 2019-04-10 23:14:51 +03:00
Jussi Pakkanen 04710b087a Add support for VS2019. Closes #4640. 2019-04-10 23:13:47 +03:00
Dylan Baker 02ff9829c4 docs: Change 0.51 to 0.50.1 [skip ci]
Since this is targeting the 0.50.1 bugfix release.
2019-04-10 19:30:18 +03:00
TheQwertiest 52fa6152cd [docs] Reordered options and fixed a typo [skip ci] 2019-04-10 19:29:25 +03:00
Dylan Baker 67ca2d5bdc docs: Document pkg_config_path and cross_ options [skip ci] 2019-04-09 16:34:10 +00:00