Commit Graph

58000 Commits

Author SHA1 Message Date
Brad King e9755bc7c1 MinGW: Restore using windres when toolchain-prefixed name is not available
Since commit 55ba10dcfd (MSYS/MinGW Makefiles: Simplify selection of
windres as Resource Compiler, 2022-05-26, v3.24.0-rc1~82^2) the `MinGW
Makefiles` and `MSYS Makefiles` generators no longer specify the plain
`windres` name for the MinGW resource compiler.  Instead, the name is
specified in our MinGW platform information module. After the change in
commit af4adf6aa9 (MinGW: Fix default windres selection when
cross-compiling, 2020-03-25, v3.18.0-rc1~492^2), when cross-compiling,
we only specify the toolchain-prefixed name of the tool, which may not
be available in all environments.

If the toolchain-prefixed name is not available, fall back to the plain
`windres` name.  We already use this approach for other binutils.

Fixes: #23841
2022-08-15 13:57:58 -04:00
Brad King 732cad4952 Merge topic 'warning-as-error-ti-compiler' into release-3.24
1cd65dfa0e TI compiler: Add support for COMPILE_WARNING_AS_ERROR target property

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Josef Angstenberger <code@jtxa.de>
Merge-request: !7560
2022-08-15 10:51:44 -04:00
Brad King 2d08a35b50 Merge topic 'mingw-flto' into release-3.24
7b2a87c2eb IPO: Do not use -flto=auto with GCC 10.x on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7559
2022-08-15 10:48:26 -04:00
Craig Scott 1cd65dfa0e TI compiler: Add support for COMPILE_WARNING_AS_ERROR target property 2022-08-12 08:27:19 +10:00
Brad King 7b2a87c2eb IPO: Do not use -flto=auto with GCC 10.x on Windows
Revise the change from commit fe57410b33 (IPO: Use -flto=auto if
compiler is GCC >= 10.1, 2022-06-22, v3.24.0-rc2~2^2) to require
at least GCC 11 on Windows.

Fixes: #23836
Issue: #23640
2022-08-10 14:49:34 -04:00
Brad King 425f6a0ef6 Merge topic 'FindThreads-msvc-no-pthread-flag' into release-3.24
7203963788 FindThreads: Skip check for -pthread flag when targeting the MSVC ABI

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7551
2022-08-09 09:16:42 -04:00
Brad King 7203963788 FindThreads: Skip check for -pthread flag when targeting the MSVC ABI
Since commit 3257c34073 (FindThreads: avoid failing in AIX when using
-D_XOPEN_SOURCE=500, 2022-04-30, v3.24.0-rc1~197^2) we no longer check
for `pthreads.h` before checking for the `-pthread` flag.  Compilers
targeting the MSVC ABI do not have such a flag, so avoid performing the
check unnecessarily.

Fixes: #23829
2022-08-08 12:41:57 -04:00
Brad King 4be24f031a CMake 3.24.0 v3.24.0 2022-08-04 09:53:57 -04:00
Brad King 019c75eb9e Merge topic 'makefile-path-consistency' into release-3.24
5e0b06fe84 Makefiles: Restore path consistency in the global dispatch makefile

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7543
2022-08-04 09:35:49 -04:00
Brad King 3a38f6c618 Merge topic 'fetchcontent-set-CMAKE_VERIFY_INTERFACE_HEADER_SETS' into release-3.24
2a9cc3e8e8 FetchContent: Disable header set verification for dependencies

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7535
2022-08-04 09:34:47 -04:00
Brad King ae03cd71b3 Merge topic 'doc-find_package-typo' into release-3.24
5635d33656 Help: Fix reST syntax typo in find_package docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7540
2022-08-04 09:33:49 -04:00
Brad King dfcbdcb135 Merge topic 'FindLua-docfmt' into release-3.24
3e2094fb9b FindLua: Improve documentation formatting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7539
2022-08-04 09:32:36 -04:00
Craig Scott 2a9cc3e8e8 FetchContent: Disable header set verification for dependencies
The CMAKE_VERIFY_INTERFACE_HEADER_SETS variable is intended to
be under the control of the user. It doesn't discriminate between
header sets defined in the main project and those defined by
dependencies brought into the build directly via FetchContent.
Developers will usually only be interested in verifying the main project's
header sets, not those from dependencies.

Make the variable effectively only enable header set verification of the
main project by turning it off during FetchContent_MakeAvailable() calls.
The user still has variables like CMAKE_PROJECT_INCLUDE and
CMAKE_PROJECT_<projectName>_INCLUDE available to them if they
want to enable verification of all or specific dependencies respectively.

Fixes: #23808
2022-08-04 09:43:10 +10:00
Brad King 5e0b06fe84 Makefiles: Restore path consistency in the global dispatch makefile
Directory-level rules in `CMakeFiles/Makefile2` were previously
previously written by each directory's local generator using its own
decision for using relative or absolute paths.

Since commit d33b12d84b (Add support for build tree symlink inside
source tree, 2022-02-25, v3.24.0-rc1~583^2), each local generator
explicitly models the relationship between its source and build paths,
and uses this to determine when it is safe to use relative paths.
Because `add_subdirectory` supports arbitrary placement of the source
and build directories, different local generators may have different
relationships between their source and build paths.  This can cause
disagreement among rules written to `CMakeFiles/Makefile2`.

Restore consistency by always using the root local generator to write
rules to `CMakeFiles/Makefile2`.  Relative paths should always be
expressed w.r.t. the top-level build directory since that is the working
directory in which the `make` tool processing the file will run.

Fixes: #23814
2022-08-03 14:58:47 -04:00
Eisuke Kawashima 5635d33656 Help: Fix reST syntax typo in find_package docs 2022-08-03 10:02:21 -04:00
Kyle Edwards 9d24d62098 Merge topic 'all-verify-interface-header-sets' into release-3.24
83e44002ae VERIFY_INTERFACE_HEADER_SETS: Add verification target for all

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7536
2022-08-03 09:58:42 -04:00
Michael Hirsch 3e2094fb9b FindLua: Improve documentation formatting
Since commit cb811d11ce (Help: Improve description of modules,
2019-04-12, v3.15.0-rc1~210^2) we've had two `::` prompts for
the preformatted block listing the result variables.  Convert the
block to a definition list.
2022-08-03 09:56:38 -04:00
Brad King a9d0bcc71e Merge topic 'ci-wix-host' into release-3.24
9ff7fffbf4 ci: host WiX 3.14.0.6526 binaries ourselves

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7538
2022-08-03 09:37:54 -04:00
Kyle Edwards 83e44002ae VERIFY_INTERFACE_HEADER_SETS: Add verification target for all
Fixes: #23802
2022-08-03 08:19:08 -04:00
Brad King 9ff7fffbf4 ci: host WiX 3.14.0.6526 binaries ourselves
Since commit 06c6e76a12 (ci: update to WiX 3.14.0.6526, 2022-06-10,
v3.24.0-rc1~4^2~2) we download the WiX binaries from `wixtoolset.org`
instead of a `github.com` CDN.  Avoid hitting their organization site
on every CI job by hosting the binaries at `cmake.org`.
2022-08-02 14:38:22 -04:00
Brad King e18fb0c73e Merge topic 'vs-msbuild-arm64' into release-3.24
c165dd6a83 VS: Fix ARM64 host architecture detection in x86 binary

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7525
2022-08-02 09:30:03 -04:00
Brad King 40b45f55f4 Merge topic 'windows-symlink-dir' into release-3.24
a4f1c0fac8 Windows: Revert "Prefer junctions for directory symlinks"

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7530
2022-08-02 09:28:48 -04:00
Brad King a4f1c0fac8 Windows: Revert "Prefer junctions for directory symlinks"
Revert commit 5101d586c4 (Windows: Prefer junctions for directory
symlinks, 2022-02-22, v3.24.0-rc1~575^2).  Junctions do not support
`../` and other non-canonical paths.  Revert their use pending further
investigation.

Fixes: #23781
Issue: #23257
2022-08-01 10:59:20 -04:00
Brad King a2daa18237 Merge topic 'doc-init-VERIFY_INTERFACE_HEADER_SETS' into release-3.24
c31f9ef22b Help: Document initialization of VERIFY_INTERFACE_HEADER_SETS property

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7528
2022-08-01 10:28:51 -04:00
Anton Lapounov c165dd6a83 VS: Fix ARM64 host architecture detection in x86 binary
Use the 64-bit registry view when we check whether Windows
has the ARM64 version of the .NET Framework 4.x installed.

Issue: #23755
2022-08-01 10:16:14 -04:00
Brad King d5977ee359 Merge branch 'release-3.23' into release-3.24 2022-08-01 10:09:54 -04:00
Brad King e0a39aeade Merge topic 'FindGTest-gmock-needs-gtest' into release-3.24
1aa95e1a3b FindGTest: Create the gmock targets only when GTest has been found

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7523
2022-08-01 10:02:24 -04:00
Craig Scott c31f9ef22b Help: Document initialization of VERIFY_INTERFACE_HEADER_SETS property
The docs for the CMAKE_VERIFY_INTERFACE_HEADER_SETS variable do
mention that it initializes the property, but the property docs didn't
mention the variable. Add that missing cross-reference.
2022-08-01 15:58:04 +10:00
Craig Scott 6c3ea97381 Merge topic 'fetchcontent-url-regression' into release-3.24
fd95769ccf FetchContent: Restore support for multiple URL values

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7522
2022-08-01 01:42:09 -04:00
Brad King e2d03cea9e Merge branch 'FindGTest-gmock-needs-gtest' into release-3.23
Merge-request: !7523
2022-07-29 14:07:08 -04:00
Robert Maynard 1aa95e1a3b FindGTest: Create the gmock targets only when GTest has been found
When we introduced the `GTest::gmock` and `GTest::gmock_main` targets in
commit 50bf457a0d (FindGTest: Add target for gmock library, 2021-10-17,
v3.23.0-rc1~321^2) we failed to handle the case where GTest isn't found.
Don't construct gmock targets that depend on non-existent gtest targets
when gtest failed to be found.
2022-07-29 14:05:55 -04:00
Craig Scott fd95769ccf FetchContent: Restore support for multiple URL values
In c2044fdf3f (FetchContent: Respect the CMP0135 policy setting,
2022-06-02), the URL keyword was wrongly assumed to only have
a single value. Multiple URL values are allowed if they are all
non-local. Rework the logic to remove that incorrect assumption
and handle both single and multi-value URL combinations.

Fixes: #23792
2022-07-29 20:58:08 +10:00
Brad King 5ead1d0a25 CMake 3.24.0-rc5 v3.24.0-rc5 2022-07-28 13:19:49 -04:00
Brad King d3c047bd39 Merge branch 'release-3.23' into release-3.24 2022-07-28 13:08:55 -04:00
Brad King d566bd962d CMake 3.23.3 v3.23.3 2022-07-28 11:46:12 -04:00
Brad King b82956ac19 Merge branch 'release-3.23' into release-3.24 2022-07-28 11:30:13 -04:00
Brad King b9efb007d0 Merge branch 'release-3.22' into release-3.23 2022-07-28 11:30:01 -04:00
Brad King 0bfd4f1ed6 CMake 3.22.6 v3.22.6 2022-07-28 10:41:34 -04:00
Brad King cacdbd570b Merge branch 'release-3.23' into release-3.24 2022-07-28 10:40:37 -04:00
Brad King ee64500b7f Merge branch 'release-3.22' into release-3.23 2022-07-28 10:40:28 -04:00
Brad King da7f3c09bf Merge topic 'ci-xcode-13.4' into release-3.24
eddf057830 gitlab-ci: update macOS jobs to use Xcode 13.4

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7520
2022-07-28 10:39:07 -04:00
Brad King c6735d6102 Merge branch 'ci-xcode-13.4' into release-3.23
Merge-request: !7520
2022-07-28 09:36:05 -04:00
Brad King faa4aed46f Merge branch 'ci-xcode-13.4' into release-3.22
Merge-request: !7520
2022-07-28 09:35:50 -04:00
Brad King eddf057830 gitlab-ci: update macOS jobs to use Xcode 13.4 2022-07-28 09:27:27 -04:00
Brad King 12830cc2a9 Merge topic 'verify-interface-header-sets-interface-library-source-language' into release-3.24
41f15193e5 VERIFY_INTERFACE_HEADER_SETS: Fall back to global languages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7517
2022-07-28 08:12:09 -04:00
Brad King 75647fc53d Merge topic 'verify-interface-header-sets-add-compile-definitions' into release-3.24
27fd172d8d VERIFY_INTERFACE_HEADER_SETS: Finalize compile info for verify targets
626e641a19 cmTarget: Factor out FinalizeTargetCompileInfo()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7516
2022-07-28 08:11:18 -04:00
Brad King 859f50a4ed Merge topic 'vs-msbuild-arm64' into release-3.24
418fd85569 VS: Detect ARM64 host architecture at runtime

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Tommy Vercetti <tommyvct@outlook.com>
Acked-by: Anton Lapounov <anton.lapounov@microsoft.com>
Merge-request: !7511
2022-07-28 08:08:00 -04:00
Kyle Edwards 41f15193e5 VERIFY_INTERFACE_HEADER_SETS: Fall back to global languages
If a target doesn't have any source files, fall back to the global
list of enabled languages to determine the language of the header
file to verify.

Fixes: #23774
2022-07-27 13:29:09 -04:00
Kyle Edwards 27fd172d8d VERIFY_INTERFACE_HEADER_SETS: Finalize compile info for verify targets
Fixes: #23732
2022-07-27 12:25:15 -04:00
Kyle Edwards 626e641a19 cmTarget: Factor out FinalizeTargetCompileInfo() 2022-07-27 12:24:53 -04:00