When 033dc7ee2f introduced
`AddSystemIncludeDirectory()`, the function was not handling the
situation which a system include cache key is not added properly like
in `IsSystemIncludeDirectory()`. The error was not exposed when
`AUTOMOC` is `ON` and `AUTOUIC` is `ON` because
`GetIncludeDirectoriesImplicit()` inside `initMoc()` was triggering
`IsSystemIncludeDirectory()`.
This commit adds calling
`AddSystemIncludeCacheKey()` inside `AddSystemIncludeDirectory()`
when the system include cache key is not added before.
Fixes: #26146
62bb8a77a5 cmMakefile: Teach ConfigureFile to move the temp file instead of copying it
dc38f81237 cmSystemTools: Revise MoveFileIfDifferent to return cmsys::Status
0a0a826b86 cmMakefile: Use find_if instead of manual loop
e0294fa310 cmMakefile: Replace single-char string literal with char for cmStrCat
206961bc60 cmMakefile::FormatListFileStack: Refactor "manual" loop into algorithms
2e16b58b7c cmStringAlgorithms: Move generic strings join function to public API
ce991188f3 cmMakefile::FormatListFileStack: Exit early on empty stack trace
29fb605822 cmMakefile::FormatListFileStack: Refactor 'while' into 'for'
...
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9635
In the variables substitution mode `cmMakefile::ConfigureFile`
was copy file and then remove temporary rendered file.
With updated signature of `MoveFileIfDifferent` it can be used
instead of `CopyFileIfDifferent`.
Move `cmJoinImpl` from `cmStringAlgorithms.cxx` to the
`cmStringAlgorithms.h` as `cmJoinStrings`. Two existing overloads are
not suitable for reverse iterators due to the hardcoded type of the
first parameter.
The signature is similar to the generic (template) `cmJoin`. With
`enable_if` "magic", `cmJoinString` could be renamed to `cmJoin` in the
future.
Also, replace `getJoinedLength` with `std::accumulate`.
In a complex test environment, there may be a desire to add a test
property label to indicate context. Here is one such example:
set_property(TEST mygoofytest PROPERTY LABELS might-fail-on-config-change)
Upon looking at the failed test summary, one can quickly decide whether
the failure might be expected or not.
198 - mygoofytest (Failed) might-fail-on-config-change
Since generated `ui` headers are added as byproducts of the autogen
target, it causes to compilation of unchanged files.
This commits adds generated `ui` headers to byproducts of the
timestamp target instead of the autogen target's.
Fixes: #25436Fixes: #26135
Since commit 67de5b7b82 (VS: Suppress MSBuild default settings affected
by UseDebugLibraries, 2024-02-13, v3.30.0-rc1~538^2~1) we generate an
empty `Optimization` element for the host compiler when there are no C
or C++ optimization flags enabled. The CUDA Toolkit Visual Studio
integration fails with an error if an empty string is inherited from the
host compiler's `Optimization` element. If no CUDA optimization flags
are specified, write an explicit empty `Optimization` element for the
CUDA compiler too.
Fixes: #26144
Since commit d3cbee99e3 (macOS: Prefer building with system-provided
curl, 2024-05-09, v3.30.0-rc1~130^2~1) CMake uses the macOS-provided
curl, which uses the LibreSSL backend by default. This exposes us to
curl issue 12525, created and fixed by the following upstream curl
commits:
* commit `bec0c5bbf` (openssl: switch to modern init for
LibreSSL 2.7.0+, 2023-08-07, `curl-8_3_0~201`)
* commit `9f2d2290d` (openssl: re-match LibreSSL deinit with init,
2023-12-15, `curl-8_6_0~219`)
Work around the bug by preferring the secure-transport backend by
default on the problematic versions of curl.
Since commit c16acd35b3 (GenEx: Add support for custom transitive link
properties, 2024-05-09, v3.30.0-rc1~82^2) evaluation of
`TRANSITIVE_LINK_PROPERTIES` by `install(EXPORT)` enables discovery of
missing dependencies on INTERFACE libraries that we did not previously
diagnose. This regressed existing projects that relied on such
non-diagnosis. Although commit 2fc9e482a9 (Evaluation of
TRANSITIVE_LINK_PROPERTIES isn't considered a usage, 2024-07-05) fixed
this, it also made a significant change to the `UseTo` infrastructure
that may have other subtle effects. Replace the fix with an approach
that explicitly models suppression of the relevant diagnostics.
Fixes: #26108
In the commit 8d99e71b, a new timestamp file was added to prevent
unneeded `AUTORCC` triggering after successful builds when
`CMAKE_GLOBAL_AUTORCC_TARGET` is ON. This caused a regression that
configuration fails when multiple `.qrc` files are added to a target.
This commits reverts 8d99e71b.
Issue: #26059Fixes: #26126