aboutsummaryrefslogtreecommitdiff
path: root/test cases
AgeCommit message (Collapse)AuthorFilesLines
2020-11-24compiler: allow non-built internal dependencies as argumentsPaolo Bonzini1-0/+6
Allow methods on the compiler object to receive internal dependencies, as long as they only specify compiler/linker arguments or other dependencies that satisfy the same requirements. This is useful if you're using internal dependencies to add special "-D" flags such as -DNCURSES_WIDECHAR, -D_XOPEN_SOURCE_EXTENDED or -DGLIB_STATIC_COMPILATION.
2020-11-21Handle cmake dependencies which require a specified versionJason Ekstrand3-0/+27
Some CMake packages fail to find at all if no version is specified. This commit adds a cmake_version parameter to dependency() to allow you to specify the requested version.
2020-11-21cmVers: use env instead of hardcoding bash locationDylan Baker1-1/+1
2020-11-18Merge pull request #7894 from obilaniu/cudaupdatesJussi Pakkanen1-3/+57
Update unstable CUDA Module to support newest toolkits and drivers.
2020-11-17Revert "Add thinlto support. Closes #7493."Jussi Pakkanen1-1/+1
This reverts commit 3e6fbde94c1cb8d4e01b7daf0282c315ff0e6c7d.
2020-11-17gnome: Drop use of volatile in GLib type functionsPhilip Withnall4-16/+16
See https://gitlab.gnome.org/GNOME/glib/-/issues/600 `volatile` was previously mistakenly used in GLib to indicate that a variable was accessed atomically or otherwise multi-threaded. It’s not meant for that, and up to date compilers (like gcc-11) will rightly warn about it. Drop the `volatile` qualifiers. Based on a patch by Jeff Law. See also http://isvolatileusefulwiththreads.in/c/. Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
2020-11-14Merge pull request #7843 from dcbaker/submit/rustc-fixesJussi Pakkanen1-1/+1
A few fixups for rust
2020-11-13Use c99 instead of c11 for buildoptions testjpark371-1/+1
Older verisons of MSVC do not support C11 properly.
2020-11-13run_unittests: use textwrap.dedentDylan Baker1-1/+1
So that editors that can fold code (vim, vscode, etc) can correctly fold functions, instead of getting confused by code that doesn't follow the current indention. Also, it makes the code easier to read.
2020-11-13gnome: Handle libraries that are not in the current build dirSam Thursfield9-0/+377
The generate_gir() function previously assumed all library inputs were in the current build dir. This would fail if they weren't.
2020-11-12interpreter: Add get_keys function for configuration_data (#7887)Jones1-0/+1
2020-11-12Merge pull request #7965 from dcbaker/wip/2020-11/macos-github-actionsJussi Pakkanen5-0/+18
Migrate osx CI from travis to github actions
2020-11-12dependencies: Put pkgconfig options before operandsHaelwenn (lanodan) Monnier1-1/+1
This fixes building with meson when the POSIX behavior of getopt is used, such as when GNU libc is used with POSIXLY_CORRECT=1 defined
2020-11-11tests/rust: dynamic linking doesn't work on darwinDylan Baker2-0/+8
This is a bug, and needs to be fixed, but in the short term testing other rust functionality on darwin is an improvement over testing none.
2020-11-11tests/frameeworks 8/flex: fix undefined functionsDylan Baker2-0/+8
Some compilers don't have explicit errors for undefined functions enabled by default. Apple clang seems to.
2020-11-10tests/28 multiline string: include required headersDylan Baker1-0/+2
we're relying on printf being defined with stdio.h, which happens to work sometimes. It doesn't work with Apple clang though.
2020-11-08Add thinlto support. Closes #7493.Jussi Pakkanen1-1/+1
2020-11-05Update CUDA module's nvcc_arch_flags() and nvcc_arch_readable() for newOlexa Bilaniuk1-0/+54
CUDA Toolkits. Also harden internal logic and add several asserts in the testcase.
2020-11-05Add newer CUDA Toolkit version entries.Olexa Bilaniuk1-3/+3
Also, remove the possibility of passing in a compiler instance to min_driver_version. This is because the NVCC compiler instance is, as of CUDA Toolkit 11.0, no longer guaranteed to be versioned identically to the toolkit itself.
2020-11-05docs: Recommend to use SPDX license identifiers [skip ci]Michael Weiss1-3/+3
Some license identifiers are ambiguous (e.g. "GPL3"). The SPDX license identifiers avoid this by providing standardized and unique identifiers (e.g. "GPL-3.0-only" or "GPL-3.0-or-later" for the previous example). Because SPDX short-form identifiers are also both human- and machine-readable we should recommend them in the documentation. More information (advantages, details, etc.) can be found here: - https://spdx.dev/resources/use/#identifiers - https://spdx.dev/ids/ Fix #7905.
2020-11-05rust: implement support for --editionDylan Baker3-0/+30
Using the std option, so now `rust_std=..` will work. I've chosen to use "std" even though rust calls these "editions", as meson refers to language versions as "standards", which makes meson feel more uniform, and be less surprising. Fixes: #5100
2020-11-03Condense test directory names again.Jussi Pakkanen1075-0/+0
2020-11-01interpreter: store correct files for project regenerationDylan Baker4-0/+14
Right now sub-sub projects are not correctly registered, because we don't have a way to pass up past the first level of subproject. This patch changes that by making the build_Def_files as defined in the Interpreter initializer accurate for translated dependencies, ie, cmake dependencies won't define a dependency on a non-existent meson.build. This means that it can always add the subi.build_def_files because they are always accurate.
2020-10-24cmake: Disable the new (CMake 3.16) PCH supportDaniel Mensinger2-0/+8
Subprojects that use the CMake PCH feature will cause compilation/linker errors. The CMake PCH support should thus be disabled until this can be properly translated to meson.
2020-10-22depenencies/llvm: Handle llvm-config --shared-mode failing (#7379)Dylan Baker3-39/+55
* depenencies/llvm: Handle llvm-config --shared-mode failing Fixes: #7371 Fixes: #7878 * test cases/llvm: Refactor to use test.json Instead of trying to cover everything internally
2020-10-19In text, betterer grammer usings.Jussi Pakkanen2-2/+2
2020-10-17Fix gnome.compile_resources() when glib is a subprojectXavier Claessens1-1/+1
When glib is a subproject we should use glib-compile-resources it overrides using find_program() in the case it is not installed on the build machine. With old glib version we have to run glib-compile-resources at configure time to generate the list of dependencies, but not when glib is recent enough.
2020-10-16Add test case for "subproject:opt" in project()Xavier Claessens3-0/+7
This is regression test for #7573
2020-10-16Add CUDA compiler header symbol testsCarlos Bederian1-0/+27
2020-10-16Fix consistency in variables kwargXavier Claessens5-4/+8
Share common code to extract the `variables` kwarg in declare_dependency() and pkg.generate().
2020-10-15intro: Add extra_files key to intro output (fixes #7310)Daniel Mensinger3-3/+12
2020-10-13wrap: Use sub-subproject packagefilesXavier Claessens1-0/+0
2020-10-13Merge wraps from subprojects into wraps from main projectXavier Claessens5-1/+19
wraps from subprojects are now merged into the list of wraps from main project, so they can be used to download dependencies of dependencies instead of having to promote wraps manually. If multiple projects provides the same wrap file, the first one to be configured wins. This also fix usage of sub-subproject that don't have wrap files. We can now configure B when its source tree is at `subprojects/A/subprojects/B/`. This has the implication that we cannot assume that subproject "foo" is at `self.subproject_dir / 'foo'` any more.
2020-10-13include_type: Add CMake subporject dependency method (fixes #6879)Daniel Mensinger1-1/+2
2020-10-13include_type: honor include_type in dependency fallbacks (fixes #7503)Daniel Mensinger1-0/+3
2020-10-13cmake: Add cross testsDaniel Mensinger14-7/+35
2020-10-12Merge pull request #7740 from bonzini/fallback-falseJussi Pakkanen6-0/+28
Allow blocking/forcing automatic subproject search
2020-10-10add test case for #6365Sahnvour5-0/+35
2020-10-08dependency: support boolean argument "allow_fallback"Paolo Bonzini6-0/+28
Sometimes, distros want to configure a project so that it does not use any bundled library. In this case, meson.build might want to do something like this, where slirp is a combo option with values auto/system/internal: slirp = dependency('', required: false) if get_option('slirp') != 'internal' slirp = dependency('slirp', required: get_option('slirp') == 'system') endif if not slirp.found() slirp = subproject('libslirp', ...) .variable('...') endif and we cannot use "fallback" because the "system" value should never look for a subproject. This worked until 0.54.x, but in 0.55.x this breaks because of the automatic subproject search. Note that the desired effect here is backwards compared to the policy of doing an automatic search on "required: true"; we only want to do the search if "required" is false! It would be possible to look for the dependency with `required: false` and issue the error manually, but it's ugly and it may produce an error message that looks "different" from Meson's. Instead, with this change it is possible to achieve this effect in an even simpler way: slirp = dependency('slirp', required: get_option('slirp') != 'auto', allow_fallback: get_option('slirp') == 'system' ? false : ['slirp', 'libslirp_dep']) The patch also adds support for "allow_fallback: true", which is simple and enables automatic fallback to a wrap even for non-required dependencies.
2020-10-07Tests: py.dependency() now has required:true by defaultXavier Claessens1-1/+1
It used to ignore the required argument and got fixed to be consistent with dependency() function.
2020-10-07Add win_subsystem kwarg. Closes #7765.Jussi Pakkanen1-3/+8
2020-10-05options: Handle updates to choices in optionsDylan Baker3-0/+27
Currently if you change the `choices` field in the meson_options.txt file, no update will be done until `meson setup --wipe` is called. Now if the choices change then the options will be properly merged. If the currently select value is still valid it is guaranteed to be kept, if it is now invalid the new default value will be used and a warning will be printed. Fixes #7386
2020-10-05Never run clang-format / clang-tidy against directoriesBernd Busse2-0/+2
`pathlib.Path.glob()` also returns directories that match source filenames (i.e. a directory named `test.h/`), but `clang-format` and `clang-tidy` fail when handed a directory. We manually skip calling `clang-format` and `clang-tidy` on those directories.
2020-10-05machinefiles: Allow keys to be stored case insensitiveDylan Baker2-0/+10
This is required to make the various keys in the [user options] section work the same as they do in the meson_options.txt file, where we don't have any rules about case sensitivity. There is some risk here. Someone may be relying on this lower by default behavior, and this could break their machine files. Fixes #7731
2020-10-04Added subdir files testOskar Sigvardsson3-0/+5
2020-10-04cmake: switch to pathlib (fixes #7322)Daniel Mensinger2-4/+2
2020-09-29tests/curses: Extend to test versionsDylan Baker1-1/+5
This is mostly important for the system dependency where we need to roll the version check ourselves.
2020-09-29dependencies/curses: Add a system dependencyDylan Baker2-2/+3
That calls find_library and has_header in conjunction to look for curses implementations that are baked into the system without any other find method.
2020-09-29dependencies/curses: Add support for using the ncurses config toolsDylan Baker3-1/+17
These are mostly duplicated with pkg-config, but maybe someone has one but not another, and they're easy to turn on with the ConfigToolDependency.
2020-09-29Merge pull request #7758 from dcbaker/submit/hdf5-factoryDylan Baker3-7/+40
dependencies/hdf5: Convert to a dependency_factory