84db8506ff Deprecate compatibility with CMake versions older than 3.10
9e3b559b6a Tests: Update cmake_minimum_required versions to 3.10
f4aa34daa7 Tests/RunCMake: Update cmake_minimum_required versions to 3.10
1d38d52995 Tests/RunCMake: Match diagnostic line numbers more robustly
55778f5a16 ExternalProject: Enable all policies in internal scripts
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9875
Issue a deprecation warning on calls to `cmake_minimum_required` or
`cmake_policy` that set policies based on versions older than 3.10.
Note that the effective policy version includes `...<max>` treatment.
Update the check from commit 3a4791548d (Deprecate compatibility with
CMake versions older than 3.5, 2023-02-09, v3.27.0-rc1~508^2).
Remove some edge cases where if CPACK_DEBIAN_PACKAGE_DEPENDS is a list
it would not be expanded on all components leaving some with ';'(s) in
the Depends field of the control file.
Same goes for using CPACK_DEBIAN_PACKAGE_SHLIBDEPS.
The `/usr/lib` and `/lib` entries need to be present, but do not need to
be at the end. Avoid appending extra copies of the entries if they
already exist.
Closes: #26275
This will now preserve empty values in the TEST_LAUNCHER and
CROSSCOMPILING_EMULATOR target properties for tests added by:
- The add_test() command.
- The ExternalData_Add_Test() command from the ExternalData module.
- The gtest_add_tests() or gtest_discover_tests() commands from the
GoogleTest module.
For the gtest_add_tests() and gtest_discover_tests() commands,
empty elements in the values passed after the EXTRA_ARGS keyword
are also now preserved.
Policy CMP0178 is added to provide backward compatibility with the
old behavior where empty values were silently discarded from the
above cases.
Fixes: #26337
Visual Studio Generator: The `VS_TOOL_OVERRIDE` source file property
would previously only be respected for file types that CMake didn't know
how to build out of the box. This change allows the user to override how
any source file is built with a custom build tool, even ones with
standard/recognized extensions such as `.cxx`, `.idl`, etc.
Fixes: #26336
8f4cea94da FindOpenMP: Add support for CUDA when supported by the toolchain
f8ed4d7c21 FindOpenMP: Factor out compiler id lookup
534923428a FindOpenMP: Simplify compiler driver check
42bf0f596e FindOpenMP: Simplify explicit "omp" library checks
5204262c0e ci: add libomp to cuda12.2 base image
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9861
The prose previously gave the impression that discovery was always done
as a post-build operation, but later in the documentation the
DISCOVERY_MODE option is explained where pre-test can also be specified.
Update the earlier prose to mention both methods equally.
- Use an "arg" prefix for cmake_parse_arguments() rather than
an empty string or uppercase ARGS so that usages of parsed
values don't start with a bare underscore or look fully
uppercase. This makes it harder to miss them or mistake
them for keywords.
- Use lowercase for names of positional function arguments
so they don't get mistaken for keywords.
Extend commit d27fe9dfba (AIX: Add option to archive shared libraries,
2024-06-18) to update the Ninja generator to support the new
`AIX_SHARED_LIBRARY_ARCHIVE` feature.
Fixes: #26332
When AIX stores a `.so` inside a `.a` archive, the loader section is
aligned to maximum of the text and data alignment. In commit 98013ad1ca
(cmXCOFF: Add support for editing binary inside an archive, 2024-07-01)
we only accounted for the data alignment.
Issue: #26275
Extend the changes from commit 190a5fdffd (Automatically use OpenSSL by
default on Linux and FreeBSD if available, 2016-02-26, v3.6.0-rc1~301^2)
and commit dd3e476786 (OpenSSL: Issue an error if OpenSSL is not found,
2019-07-17, v3.16.0-rc1~379^2) to cover builds targeting the CYGWIN and
MSYS runtime platforms.
The compiler driver's verbose flag is needed only when linking because
we parse its output to get the implicit link information added by the
OpenMP flag.
For toolchains that do not provide a builtin `omp` library the compiler
driver's OpenMP flag should not be needed when linking. We also do not
need the compiler driver's verbose flag because we are not parsing its
output.