Prior to this fix, CMAKE_NMC_DEFAULT_CONFIGS would inherit "all" from
the union of CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG and
CMAKE_NMC_CROSS_CONFIGS. This is inconsistent with the behavior of the
"all" target signifying CMAKE_NMC_CROSS_CONFIGS. Update "all" in
CMAKE_NMC_DEFAULT_CONFIGS to inherit only from CMAKE_NMC_CROSS_CONFIGS.
8752c1bd64 Merge branch 'backport-3.16-link-line-backtrace'
e756328434 Propagate backtraces from LINK_LIBRARIES through to link line items
Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: Dennis Klein <d.klein@gsi.de>
Merge-request: !4344
In certain cases, rebuilds with CMake using the CONFIGURE_DEPENDS flag
with GLOB_RECURSE could result in a reconfigure loop due to CMP0009 not
being propogated to the generated VerifyGlobs.cmake script.
During the inital configuration phase, RecurseThroughSymlinksOn() is
called for recursive glob operations either by having the CMP0009 status
not set to NEW or by explicitly providing the FOLLOW_SYMLINKS flag. At
the end when the VerifyGlobs script is created, the FOLLOW_SYMLINKS flag
is written according to the final resolved form through a call to
GetRecurseThroughSymlinks(). Thus, setting CMP0009 to NEW in the
generated file is safe and allows correct behavior whether or not the
end user sets the policy status to NEW or OLD.
In commit 9fc20a4f3e (install: Add sane set of defaults for DESTINATION
and file type parameters, 2018-11-02, v3.14.0-rc1~410^2~1), a regression
was introduced, in which an `install(TARGETS)` with a
RUNTIME/LIBRARY/ARCHIVE DESTINATION but no PUBLIC_HEADER/PRIVATE_HEADER
DESTINATION would then install the headers. The old behavior did not do
this. Restore the old behavior.
Fixes: #20326
ceb5ee4a7b FindOpenMP: Add support for Clang on Windows
2dbff623f9 FindOpenMP: Save flags/libs in cache entries each time they are detected
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4327
b4d5ea8233 FindMPI: Preserve order of include directories on re-runs of CMake
8261ee3a9c FindMPI: Restore re-construction of include directories
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4341
In commit 5bc6230741 (ExternalProject: Option to turn off recursive
update of git submodules, 2019-10-16) we implemented the feature in the
clone script written by `_ep_write_gitclone_script` but not in the
update script written by `_ep_write_gitupdate_script`. Implement the
latter by factoring out a common helper to use in both places.
Fixes: #20335
Since commit d4d0dd0f6a (cmLinkLineComputer: Add ComputeLinkLibs
overload with backtraces, 2019-09-13, v3.16.0-rc1~87^2~4), backtraces
have been collected by `ComputeLinkLibs` by looking back through the
link implementation libraries for one matching the text of the link line
item. This is slow in projects with long link lines.
Instead, teach `cmComputeLinkDepends` and `cmComputeLinkInformation` to
carry backtrace information explicitly along with the text of each item.
Fixes: #20322
The fix in commit 5861c6d450 (FindMPI: Preserve include order when
extracting component directories, 2019-12-19) only works on the first
run of CMake in which we find MPI. Extend the fix to save the compiler
wrapper's entire include path in our cache without splitting anything
out. That way we can preserve the order when CMake re-runs.
Fixes: #20338
The fix in commit 5861c6d450 (FindMPI: Preserve include order when
extracting component directories, 2019-12-19) only works on the first
run of CMake in which we find MPI. It preserves the include directories
on the first run but still splits them up and saves the pieces in the
cache. On future runs the pieces are not re-assembled, and we do not
know the order anyway.
Restore the re-assembly step so that at least all the include dirs are
available. Leave preservation of the original order to later work.
Issue: #20338
Populate `CMAKE_Swift_IMPLICIT_INCLUDE_DIRECTORIES` with the macOS SDK's
include directory so that we filter such implicit directories out of
Swift targets.
Fixes: #19845
Fix `archive_string_append_from_wcs_in_codepage` to account for the
already-used portion of the buffer when computing the size of the
remaining buffer for ``WideCharToMultiByte` output.
Fix an issue where CMAKE_NMC_DEFAULT_BUILD_FILE_CONFIG is specified
and CMAKE_NMC_CROSS_CONFIGS is not, which results in a false error
with CMAKE_NMC_DEFAULT_CONFIGS.
bd4ae2af0f Help: Make note of ninja -f argument in Ninja Multi-Config docs
79e5b3c46a Help: Explain new behavior of cmake --build in Ninja Multi-Config
16a4ba5b31 Ninja Multi-Config: Use build.ninja if cmake --build has no --config
2ac835b9f9 Refactor: Allow generators to decide default configuration for build
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4323