aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2022-05-25dependencies: Fix several annotations issuesDylan Baker1-7/+11
- `BuildTarget` should be `SharedLibrary | StaticLibrary` - Needs to take `CustomTargetIndex` as well as `CustomTarget` - don't assign to self until values have been converted to the correct type
2022-05-25build: fix annotations for BuildTarget.link*targetDylan Baker1-2/+2
which do not hold BuildTargets, they are `SharedLibrary | StaticLibrary | CustomTarget | CustomTargetIndex` (whole doesn't accept `SharedLIbrary`)
2022-05-25modules/gnome: Fix missing type annotationDylan Baker1-1/+1
2022-05-25modules/gnome: fix some typing issuesDylan Baker1-3/+3
That come to light with some of the changes later in this series, particularly around dependencies.
2022-05-25Fix optimization level 's' for the TI compilerAndreas Obergschwandtner1-1/+1
2022-05-24cmake: Add test caseDaniel Mensinger2-0/+5
2022-05-24cmake: fix detecting directories as input files (fixes #10244)Daniel Mensinger1-1/+1
2022-05-24ast: cmake: Generate line numbers while printing the AST for better debuggingDaniel Mensinger2-2/+31
2022-05-24doc: Generate dev release notesXavier Claessens2-31/+69
2022-05-24Compiler-properties.md:link to compiler object pageandy59951-2/+3
2022-05-24Tweak "header has symbol" messagePeter Eisentraut1-2/+2
Change message Header <foo.h> has symbol "BAR" to Header "foo.h" has symbol "BAR" with the first part also now in bold. This is more consistent with other messages like Has header "foo.h" and Checking whether type "foo" has member "bar"
2022-05-24fix traceback when run_command has a find_program as the inline argEli Schwartz1-1/+6
We were poking directly at the node, so if it was a FunctionNode then this broke. Instead, just do a reverse lookup in the overrides table to get the original find_program name.
2022-05-24mtest: ignore invalid inputPaolo Bonzini2-6/+0
TAP version 14 introduced subtests, that are supposedly backward compatible because "TAP13 specifies that non-TAP output should be ignored". Meson reported TAP syntax errors based on behavior of "prove" at the time, but it seems that now "prove" has become a lot more lenient; it even accepts the following completely bogus input just fine: --- ok 1 ok 2 x 1..1 --- So do the same and make Meson's parser accept invalid TAP input silently. Fixes: #10032
2022-05-23modules/icestorm: use type checkingDylan Baker2-55/+92
2022-05-23modules/icestorm: replace individual tools attributes with dictDylan Baker1-16/+22
As we commonly do in other modules
2022-05-23interpreter: Add another overload to source_strings_to_filesDylan Baker1-0/+3
Which doesn't have `StructuredSources`, as is actually quite common.
2022-05-23modules: add typing to the modtest moduleDylan Baker2-5/+17
2022-05-23move various imports into TYPE_CHECKING blocks for neatnessEli Schwartz6-16/+29
2022-05-23typing: use forward reference for types defined later in fileEli Schwartz1-2/+2
2022-05-23fix typing regressionEli Schwartz1-1/+1
In commit f2d21bf8a98fe4eb528a077f3faf5d68cd35c244 a type annotation was added that does not exist. The referenced type is present but only as a dotted name.
2022-05-19Fix invalid Python overridesTristan Partin3-10/+6
- mismatched method type - mismatched parameter names
2022-05-19Add cc.has_function_attribute('sentinel')Tristan Partin3-0/+4
2022-05-19Add cc.has_function_attribute('section')Tristan Partin3-0/+10
2022-05-19Reword message in warningZbigniew Jędrzejewski-Szmek8-23/+23
"targetting" is verb-derived adjective, which sort-of-works here, but makes the whole sentence awkward, because there's no verb. Let's just use present simple.
2022-05-19Reword misleading warningZbigniew Jędrzejewski-Szmek5-7/+7
"tried to use" implies that the attempt was not successful, i.e. that meson ignored the feature. But that is not what happens, apart from the warning the feature works just fine. The new message is also shorter ;)
2022-05-18Fix --allow-shlib-undefined for LLVM versions > 9Tristan Partin1-1/+2
2022-05-17fix incorrect FeatureNew for separator kwarg in environment object methodsEli Schwartz1-1/+1
In commit 6acfe48f32110671a0adf80ad3497a35105b265d, the kwarg was added to environment() in addition to the env object methods. As part of the associated refactor, a shared KwargInfo was used, and evolved to be new since 0.62.0 in the two cases where it is in fact new. However, it *also* set the base KwargInfo for the exact same newness, which is wrong as it was present ever since the initial introduction in 0.34.0 As usual for anything that predates 0.37.0 we simply don't tag FeatureNew. Revert this back to the same KwargInfo definition from before the refactoring commit. Fixes #10402
2022-05-17mtest: stop disrespecting the gdb config fileEli Schwartz1-1/+1
This was added in commit 01be50fdd90851f17de5499537f10b5b62c9fb49 with zero explanation as a side effect of moving code around. It seems like a really bad idea and it causes people to view debugging Meson projects on e.g. debuginfod systems as "painful".
2022-05-16Update Creating-OSX-packages.mdAdel Kara Slimane1-3/+25
Qt offers a tool to automatize most of what needs to be done regarding its libraries.
2022-05-16Add optional compressjoshcangit1-1/+2
Compress files under source directory using Deflate method. By default, files are not compressed in the archive. Compression is active only when this option is defined. https://docs.python.org/3/library/zipapp.html?highlight=zipapp#cmdoption-zipapp-c
2022-05-10linkers/MinGW: Allow `efi_application` value for `win_subsystem`Lens1-7/+25
Previously, any value other than `windows` or `console` caused an exception. This change allows for `efi_application` to be passed as the `win_subsystem` to MinGW based linkers.
2022-05-10Require CMake 3.14 for all tests that use the cmake moduleSimon McVittie7-20/+12
Older versions are not supported by the cmake module since 0.62. This avoids having to hard-code the linux-bionic-gcc CI job as being unable to run these tests, which leaves other older environments like Debian 10 still trying to run them (and failing). Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-09dependencies/boost.py: ignore unknown filesfghzxm1-2/+14
If we encounter a file under the Boost library directory that doesn't look like a Boost library binary, we should ignore it. We log a warning for each file we ignore, except for ones we know are safe to ignore (e. g. PDB files from the SourceForge Windows distribution). This should avoid polluting the log. Fixes #8325.
2022-05-09python module: default extensions to hidden symbol visibilityEli Schwartz3-0/+22
python compiled extensions should never need to expose any symbol other than PyInit_* which is declared with default visibility via PyMODINIT_FUNC on supported compilers. Thus, a reasonably sane default is to mark any other symbols as hidden, while still respecting any manually specified visibility. Gate this on the version of python itself, as not all versions decorate PyMODINIT_FUNC properly.
2022-05-09compilers/gnu: demote visibilty inlineshidden to hidden for unsupported ↵Eli Schwartz1-0/+2
compilers This option is only valid for C++ and ObjC++, but the kwarg is useful for mixed language targets. Asking for inlines as well, when the compiler driver is trying to build the C components of a target, results in gcc emitting: ``` cc1: warning: command-line option ‘-fvisibility-inlines-hidden’ is valid for C++/ObjC++ but not for C ``` Squelch this warning by filtering it out on Meson's side of things.
2022-05-08fix regression in reporting errors for invalid gnu_symbol_visibilityEli Schwartz1-1/+1
In commit fb2cdd0fe2797b30e1fd4c118407302402739a3b the internal property was renamed, but one use case of it in raising a MesonException was not changed to go with it. This meant that instead of erroring out with: ``` ERROR: GNU symbol visibility arg XXXX not one of: default, internal, hidden, protected, inlineshidden ``` we instead errored out with: ``` AttributeError: 'SharedLibrary' object has no attribute 'symbol_visibility' ``` Fixes #9659
2022-05-08compilers/c++: Add MSVC option to make the __cplusplus define accurateEli Schwartz5-1/+47
Otherwise it always returns the value for c++98, starting with MSVC 2017 15.7 or later. Earlier versions are not affected by this mis-feature. See: https://docs.microsoft.com/en-us/cpp/build/reference/zc-cplusplus?view=msvc-160 This was originally applied as 0b97d585480e973d8b149618901f7a4ddfa1a906 but later reverted because it made the CI red. Try it again, now. Original-patch-by: Dylan Baker <dylan@pnwbakers.com> Co-authored-by: Dylan Baker <dylan@pnwbakers.com>
2022-05-06Limit parallelism to hopefully work on machines with 160 cores.Jussi Pakkanen1-1/+6
2022-05-06compiler.has_argument: Add `-Werror=unknown-warning-option` to clang-cl cmd lineKhairul Azhar Kasmiran1-1/+1
2022-05-06devenv: Set WINEPATH when cross compiling for WindowsXavier Claessens4-6/+74
2022-05-06coverage: be clever and detect config files for gcovr/lcovEli Schwartz2-13/+40
gcovr will read this file anyway, but if it exists we don't need to assume that the project wishes to exclude subprojects/ -- they can determine that themselves. Fixes #3287 Closes #9761 lcov doesn't read the config file by default, but we can do the smart thing here. Fixes #4628
2022-05-06Add some scaffolding needed for C++ modules in GCC.Jussi Pakkanen14-0/+98
Further work pending GCC bug #105467 and/or Ninja bug #1962.
2022-05-06Move Visual Studio module test to its own subdir.Jussi Pakkanen13-14/+21
2022-05-06unittests: Skip prelinking test with gcc 8 or olderSimon McVittie1-4/+2
This was already skipped when running on the Ubuntu 18.04 version of gcc, but it also fails with gcc 8.3.0 on Debian 10. Instead of hard-coding specific versions to look for, do a version comparison. Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-05minit: refuse to allow creating broken projectsEli Schwartz1-0/+4
Some executable names are invalid, and while it's unlikely anyone will specify such a thing using the --executable argument, it's not unlikely that people experimenting will attempt to use meson init in a directory named "test". This then defaults to that for both the project name and the sample target name, and the latter produces errors when you try to build it. Fixes #10321
2022-05-03add prefer_static built-in optionDudemanguy10-7/+28
By default, meson will try to look for shared libraries first before static ones. In the meson.build itself, one can use the static keyword to control if a static library will be tried first but there's no simple way for an end user performing a build to switch back and forth at will. Let's cover this usecase by adding an option that allows a user to specify if they want dependency lookups to try static or shared libraries first. The writer of the meson.build can manually specify the static keyword where appropriate which will override the value of this option.
2022-05-03dependencies: cleanup kwargs.get('static') usageDudemanguy2-3/+2
In a couple of spots, kwargs.get('static', False) was being unneccesarily used. In these spots, we can just use self.static instead which is already inherited from the ExternalDependency. In additional, the python system dependency oddly has a kwargs.get('static', False) line which overrides the self.static in that dependency for no real reason. Delete this line too.
2022-05-03dependencies: handle one more case of subproject installed filesEli Schwartz5-1/+11
Some projects treat meson.project_source_root() as the root of the dependency files, because the project itself merely wraps a bunch of datafiles. Our validation to make sure this doesn't point to another subproject, made use of pathlib.Path's generator for all component paths, which... did not include the path itself. So go ahead and explicitly check that too. Add a test case to verify it while we are at it. Fixes https://github.com/mesonbuild/meson/pull/10103#issuecomment-1114901033
2022-05-04devenv: Use PkgConfigDependency.get_env()Xavier Claessens2-5/+3
This ensures that PKG_CONFIG_PATH, PKG_CONFIG_LIBDIR and PKG_CONFIG_SYSROOT_DIR are also set properly.
2022-05-03add testcase for bad things with add_project_dependenciesPaolo Bonzini10-0/+53
Test that add_project_dependencies() can only be used before build targets have been declared. Also test that one cannot use override_dependency on a superproject to inject a superproject's build products into the subproject. This would violate the rule that build products cannot be used with add_project_dependencies() (similar to e.g. compiler.has_function), so check that meson detects the situation correctly.