Qt 6 now has stable keywords (and has for a while). Recent stabilisation
of Plasma 6 now pulls in Qt 6 in the image builder so frameworks: 4 qt
fails as qttools is missing.
Signed-off-by: Sam James <sam@gentoo.org>
This commit harmonizes the handling of `d_import_dirs` and
`include_directories`. The treatment of `d_import_dirs` was also
different depending on the context: in `declare_dependency` it was
treated like the `include_directories`, but in `build_target` et al,
it had special treatment. With this commit, they are all treated
by the same function. The documentation has been updated to
reflect this.
Fixes#12742
The zlib symbols may not be of type 'T' but rather e.g. 'D' -- instead,
tell nm to emit the POSIX format and also to only emit defined symbols,
not undefined ones. Then we just check if the symbol is listed at all,
regardless of type.
We already depend on -U elsewhere (e.g symbolextractor). There's no real
replacement for it, sadly. It's also buggy in some versions of nm, so we
check both its long and short options.
Bug: https://bugs.gentoo.org/938259
If kwargs_force_multiline is enabled, an ArgumentNode in a kwarg value can
already be marked multiline by the time we notice that the line needs to
be broken for length. Ensure we still break the line in this case.
Fixes: #13512
In cases, when localized media files are provided by some languages,
we need to use 'gnome.yelp ()' with 'symlink_media: false' which
copies all files from 'C' locale in addition to the localized
media. This wastes storage space. The alternative is to use
'symlink_media: true' which symlinks entirely to 'C' media files
ignoring localized media files.
As a middle ground, if the localized media file exists in the source
tree for a language, we use that file rather than symlinking to 'C'
media with the same filename even when 'symlink_media: true'. This
saves storage space.
If there are no localized media files in non-C language, the existing
behaviour is maintained.
There are two environments on Windows:
* When invoked in a Cygwin or MSYS2 MSYS shell, `host_machine.system()` returns `cygwin`.
* When invoked in a MSYS2 MINGW32/MINGW64/UCRT64/CLANG64/etc., `host_machine.system()` returns `windows`.
When projects do not specify a minimum meson version, we used to avoid
giving them the benefit of the Feature checks framework. Instead:
- warn for features that were added after the most recent semver bump,
since they aren't portable to the range of versions people might use
these days
- warn for features that were deprecated before the upcoming semver
bump, i.e. all deprecated features, since they aren't portable to
upcoming semver-compatible versions people might be imminently upgrading
to
Previously, setting `MESON_TESTTHREADS` to a number lower than 1
resulted in unexpected behavior. This commit introduces test for
negative value (with fallback to 1), and fallback to core count in case
it is set to 0.
It improves experience in job-matrix type of CI workflows, where some
jobs within the matrix require single job execution, whereas others can
default to taking core count as the job count.
Signed-off-by: Marek Pikuła <m.pikula@partner.samsung.com>
Although it's not especially common, there are certainly cases where it's
useful to pass the path to an external program to a test program.
Fixes: https://github.com/mesonbuild/meson/issues/3552
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
We've documented these lists as being `List[Path]`, but then we have the
potential to insert a None into them via the `rel_path()` function,
which can return `None` in some cases. Currently we fix some (but not
all) of these later, but we should actually remove them from the list
before we assign, so that it's actually a `List[Path]` at all times.
While we're here I've simplified the logic a bit.
Closes: #13551
It was possible (with some frequency) for the clang-tidy/format target
to continue starting new subprocesses after a CTRL-C, because we were
not canceling the already queued tasks and waiting for all of them.
This makes a best-effort attempt to cancel all further subprocesses. It
is not 100%, because there is a race that is hard to avoid (without
major restructuring, at least): new subprocesses may be started after
KeyboardInterrupt (or any other exception) is raised but before we get
to the cancellation.
When the race happens, the calling ninja may exit before Meson exits,
causing some output (from clang-tidy/format and Meson's traceback) to be
printed after returning to the shell prompt. But this is an improvement
over potentially launching all the remaining tasks after having returned
to the shell, which is what used to happen rather often.
In practice, it appears that we cleanly exit with a pretty high
probability unless CTRL-C is hit very early after starting (presumably
before the thread pool has launched subprocesses on all its threads).
The following is valid meson:
```meson
a = '''This string can't be simplified'''
```
which cannot be simplified because of the `'` in it, as
```meson
a = 'This string can't be simplified'
```
Is invalid.
Potentially we could convert that with escapes, but it seems reasonable
to me to leave this, since it may be desirable to not have lots of
escapes in a string. `'''I can't believe it's her's!'''` is much more
readable than `'I can\'t believe it\'s her\'s!'`, for example.
Closes: #13564