Commit Graph

8284 Commits

Author SHA1 Message Date
0fb1d029b6 interpreter: Correctly handle arguments to benchmark
This fixes two separate issues, one is that benchmark warns about
depends and priority; The other is that we passed bad values like
is_parallel into the test and would actually run benchmarks in parallel,
which is bad.
2019-10-02 13:43:08 -07:00
8d3fcb3dc4 dependencies: account for frameworks without a Versions directory
Most apple system frameworks do not have a Versions directory in them at
all.

Fixes the following traceback:

...
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/interpreter.py", line 3063, in func_dependency
    d = self.dependency_impl(name, display_name, kwargs)
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/interpreter.py", line 3110, in dependency_impl
    dep = dependencies.find_external_dependency(name, self.environment, kwargs)
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/dependencies/base.py", line 2142, in find_external_dependency
    d = c()
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/dependencies/base.py", line 2004, in __init__
    self.detect(name, paths)
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/dependencies/base.py", line 2035, in detect
    incdir = self._get_framework_include_path(framework_path)
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/dependencies/base.py", line 2065, in _get_framework_include_path
    self._get_framework_latest_version(path))
  File "/Users/matt/Projects/cerbero/build/build-tools/lib/python3.7/site-packages/meson-0.51.999-py3.7.egg/mesonbuild/dependencies/base.py", line 2057, in _get_framework_latest_version
    return 'Versions/{}/Headers'.format(sorted(versions)[-1]._s)
IndexError: list index out of range
2019-10-02 19:44:39 +03:00
48a5d17830 Merge pull request #5873 from mesonbuild/py2optional
Make Python 2 tests optional(er) to prepare for py2 purge in Debian.
2019-10-01 22:03:43 +03:00
d3b389f349 Add clang-tidy target. Closes #2383. 2019-10-01 22:02:51 +03:00
5a52983f16 Refactor clang tool generation to its own function. 2019-10-01 22:02:51 +03:00
94564b8f1a azure: Install python[23]-devel packages on Cygwin
Install python[23]-devel packages on Cygwin, so that python tests which
require that can run.

(Only the default version of python (currently 3.6) provides the
/usr/lib/pkgconfig/python3.pc file we are looking for so also update to
that version)
2019-10-01 21:12:04 +03:00
5b422fce87 Make Python 2 tests optional(er) to prepare for py2 purge in Debian. 2019-10-01 21:12:04 +03:00
7d9e58f125 cmake: Add support for normal libraries
Without this, set_target_properties() on those libraries won't be
catched, for example when setting the SOVERSION.
2019-10-01 13:30:15 -04:00
90a12ed3f0 cmake: Fix 'properies' typo 2019-10-01 13:30:15 -04:00
a4b0d216b5 cmake: COMMAND could have ';' separated arguments 2019-10-01 13:30:15 -04:00
73f0061498 cmake: postprocess libraries names with so version 2019-10-01 13:30:15 -04:00
22d578e1a0 Remove unused 'required' argument 2019-10-01 13:30:15 -04:00
7a83668b6b cmake: Generate declare_dependency() only for libraries 2019-10-01 13:30:15 -04:00
71bfec7ec1 cmake: subproject() supports the 'required' kwarg 2019-10-01 13:30:15 -04:00
70b1391248 cmake: Write AST into build dir
It easier to read it from a file than looking into logs. Users needs to
read it to find variable names of generated dependency objects.
2019-10-01 13:30:15 -04:00
058f89c2f2 Fix test_static_link() on MacOSX
test3-static was actually always using the shared library because that
warning was not fatal:
  WARNING: Static library 'func6' not found for dependency 'func6', may
  not be statically linked

The reason why the libfunc6.a wasn't found is because the prefix in the
generated pc file was not set to install dir.
2019-10-01 13:06:45 -04:00
2fb51a2cb0 doc: Add release snippet for the rework of static libraries 2019-10-01 13:06:45 -04:00
dd5a0df3ec Recursively include all objects from uninstalled static libraries 2019-10-01 13:06:45 -04:00
a3153747b9 Do not promote to link_whole when an internal library links to another 2019-10-01 13:06:45 -04:00
19fc692b25 pkgconfig: Include dependencies of uninstalled static libraries 2019-10-01 13:06:45 -04:00
dc5ad1fad9 pkgconfig: Do not include uninstalled static libraries 2019-10-01 13:06:45 -04:00
484b721369 Fix link_with of a static library with an uninstalled static library 2019-10-01 13:06:45 -04:00
f396c71c52 Fix link_whole of static libraries 2019-10-01 13:06:45 -04:00
01569fee2e Add depfile to configure_file()
In qemu, minikconf generates a depfile that meson could use to
automatically reconfigure on dependency change.

Note: someone clever can perhaps find a way to express this with a
ninja rule & depfile=. I didn't manage, so I wrote a simple depfile
parser.
2019-09-30 22:17:50 +03:00
e32b0f8fbb Deduplicate PKG_CONFIG_PATH entries when initializing the array option pkg_config_path.
This avoids a warning about duplicate entries in an array option,
and closes #5736.
2019-09-30 20:54:08 +03:00
2057ffccc3 Correct obviously-wrong test for gold linker. 2019-09-30 20:54:08 +03:00
1473fbc3f6 Merge pull request #5939 from lantw44/move-the-list-of-llvm-versions-to-a-common-place
Move the list of LLVM versions to a common place
2019-09-30 00:07:32 +03:00
0008b326ff Add support for depth option in wrap-git
This allows cloning subprojects shallowly.  It works recursively for a
subproject's submodules in case `clone-recursive` is set to `true`.
2019-09-29 20:47:59 +03:00
a65d5801f3 environment: Support taking values from dict
Related to #5955.
2019-09-29 08:42:53 -04:00
18897b6afd ConfigurationDataHolder: pass initial_values to ctor 2019-09-29 08:42:53 -04:00
6c72119cfd configure_file: add feature version checks for taking dict
Since commit 38a658214 ("configure_file: Support taking values from a
dict" #4236), configuration_data() and configure_file()'s
configuration kwarg can take a dict. Add missing version checks.
2019-09-29 08:42:53 -04:00
ef5fa846e0 Add CppCon 2019 talk to videos page. [skip ci] 2019-09-29 02:51:39 +03:00
52c4ca4afd Moved changes from preliminary relnote page to snippets. [skip ci] 2019-09-29 02:48:58 +03:00
24bd029437 environment: LLVM 9 is now a stable release 2019-09-29 00:11:16 +08:00
0390b673f1 Find clang-format with alternative names
This is similar to what we currently do for scan-build except there is
no environment variable to choose a specific clang-format to run. If an
environment variable is needed for better control, we can add it later.
2019-09-29 00:11:15 +08:00
08ce1fb541 Move the list of LLVM version suffixes to a common place
Both scan-build and llvm-config need the same list of LLVM version
suffixes. It is better to keep the list at a common place instead of
having several copies in different files, which is likely to become
out-of-sync when the list is updated.
2019-09-29 00:11:13 +08:00
d6c4e79c84 mtest: Don't require an exe wrapper for if the cross file says we don't need one
Fixes #5970
2019-09-28 18:11:06 +03:00
f724cc2042 backends: Add needs_exe_wrapper to test serialization
We need to know if the test actually needs an exe wrapper to run or not.
2019-09-28 18:11:06 +03:00
714908e5d9 Catch NotADirectoryError to fix selinux error
Fixes #4798
2019-09-27 13:09:52 -07:00
3fd460bce7 Fix GNU-like LLD being misdetected as MSVC-like LLD
Affects the latest version of the llvm-mingw toolchain
2019-09-27 08:20:07 -07:00
7dbabdc7b6 Correctly handle platform-specific LDFLAGS options 2019-09-27 00:57:21 +03:00
534e94ffc3 cmake: Support ALIAS libraries 2019-09-26 20:33:50 +03:00
fbddeeb4ac cmake: define set_and_check in CMake package config (fixes #5889) 2019-09-26 20:29:42 +03:00
2dd5e695c7 envconfig: Add MicroBlaze CPU family
Add the CPU family for the MicroBlaze processor.

Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
2019-09-26 20:28:42 +03:00
fbbdde4561 Clarify the list of languages is optional for project() [skip ci] 2019-09-26 20:26:14 +03:00
0993c57ce6 Merge pull request #5958 from keszybz/caching-cleanup
Caching cleanup
2019-09-26 00:08:57 +03:00
74d5136e59 environment: Don't make special case for scan-build on Linux
Versioning of executables is not related to the operating system kernel.
It is possible for a Linux distribution to support multiple versions of
LLVM in a way similar to FreeBSD. For example, on Debian, you can use
'apt install clang-tools-7' to install the versioned 'scan-build-7'
executable without bringing the unversioned 'scan-build' into the
environment. Therefore, we should not skip the version list on Linux.
It also makes it consistent with the behavior of llvm dependency, which
does not change the search list depending on the operating system.

This commit also fixes the version suffix for Debian. Debian stops using
the minor version number on the executable after version 7, so it should
be 'scan-build-7', not 'scan-build-7.0'.

This is a follow-up of https://github.com/mesonbuild/meson/pull/5918.
2019-09-25 22:52:19 +03:00
2e7f0ce557 Print user defined options in meson-log.txt
It can be useful to know what options have been passed to the command
line, excluding default values.

Closes: #5956
2019-09-25 22:50:48 +03:00
f745e8fc4d Use functools cache instead of open-coded implementation
Functional behaviour is not identical, because the cache not set
when an exception is thrown. I hope this doesn't matter in practice.
2019-09-25 14:52:07 +02:00
11c1f8644c Drop unused variable 2019-09-25 14:52:07 +02:00