Commit Graph

53713 Commits

Author SHA1 Message Date
Brad King
83a3db5631 export: Increase maximum policy version in exported files to 3.20
The files generatd by `install(EXPORT)` and `export()` commands
are known to work with policies as of CMake 3.20, so enable them
in sufficiently new CMake versions.
2021-06-30 10:13:56 -04:00
Brad King
d76cb12905 Add deprecation warnings for policies CMP0088 and below
The OLD behaviors of all policies are deprecated, but only by
documentation.  Add an explicit deprecation diagnostic for policies
introduced in CMake 3.14 and below to encourage projects to port
away from setting policies to OLD.
2021-06-30 10:07:42 -04:00
Brad King
1a2c8407a7 Merge branch 'release-3.21' 2021-06-30 08:58:36 -04:00
Brad King
e610e99ad3 CMake 3.21.0-rc2 v3.21.0-rc2 2021-06-30 07:51:35 -04:00
Brad King
6c3ae9827f Merge topic 'ninja-edit_cache'
51bf4094fb Ninja: Use `ccmake` for `edit_cache`
7cb4ad7e39 cmGlobalCommonGenerator: Adopt GetEditCacheCommand
23af78bb78 cmGlobalCommonGenerator: Adopt GetEditCacheTargetName
1db4d74628 cmGlobalCommonGenerator: Add SupportsDirectConsole
61a737b088 cmGlobalNinjaGenerator: Rename SupportsConsolePool to SupportsDirectConsole

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6272
2021-06-30 07:33:59 -04:00
Brad King
943d476346 Merge branch 'release-3.21' 2021-06-30 07:32:57 -04:00
Brad King
825ad2fb4c Merge topic 'CMP0126-WARNING' into release-3.21
16208ac113 CMP0126: Add control for warnings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !6282
2021-06-30 07:32:56 -04:00
Brad King
a2f2634a5d Merge topic 'CMP0126-WARNING'
616972197a Merge branch 'backport-3.21-CMP0126-WARNING' into CMP0126-WARNING
16208ac113 CMP0126: Add control for warnings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !6282
2021-06-30 07:32:56 -04:00
Brad King
da79d6bdf6 Merge topic 'fujitsu-clang-findbinutils' into release-3.21
6ce97c2248 FujitsuClang: Change LTO option from -flto=thin to -flto
3a0effcd16 FujitsuClang: Set CMAKE_<LANG>_COMPILER_AR and CMAKE_<LANG>_COMPILER_RANLIB

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6281
2021-06-30 07:31:39 -04:00
Brad King
0e2040f36f Merge branch 'release-3.21' 2021-06-30 07:31:39 -04:00
Brad King
d4a0d59472 Merge topic 'fujitsu-clang-findbinutils'
6ce97c2248 FujitsuClang: Change LTO option from -flto=thin to -flto
3a0effcd16 FujitsuClang: Set CMAKE_<LANG>_COMPILER_AR and CMAKE_<LANG>_COMPILER_RANLIB

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6281
2021-06-30 07:31:39 -04:00
Brad King
ff52df1d5c Merge branch 'release-3.21' 2021-06-30 07:30:25 -04:00
Brad King
2e7ce62b73 Merge topic 'vs-ARM64EC' into release-3.21
da0f74b5a1 VS: Add ARM64EC to supported platforms for VS 16 and 17

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6283
2021-06-30 07:30:24 -04:00
Brad King
e052bb64ef Merge topic 'vs-ARM64EC'
da0f74b5a1 VS: Add ARM64EC to supported platforms for VS 16 and 17

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6283
2021-06-30 07:30:24 -04:00
Brad King
b0db63db09 Merge branch 'release-3.21' 2021-06-30 07:29:30 -04:00
Brad King
e28c2ee9ae Merge topic 'rpm-suggests' into release-3.21
9b53eca317 CPack/RPM: Fix weak dep support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6274
2021-06-30 07:29:29 -04:00
Brad King
a63ae2f1b8 Merge topic 'rpm-suggests'
9b53eca317 CPack/RPM: Fix weak dep support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6274
2021-06-30 07:29:29 -04:00
Brad King
fccacee609 Merge branch 'release-3.21' 2021-06-30 07:27:50 -04:00
Brad King
25c2fed01b Merge topic 'tll-out-of-dir' into release-3.21
e27a76f131 target_link_libraries: Restore transitive out-of-dir linking

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6285
2021-06-30 07:27:49 -04:00
Brad King
85fe60ef03 Merge topic 'tll-out-of-dir'
e27a76f131 target_link_libraries: Restore transitive out-of-dir linking

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6285
2021-06-30 07:27:49 -04:00
Brad King
249363f579 Merge topic 'compiler-id-msvc-has-include' into release-3.21
c6aaaf066a DetermineCompiler: Restore identification of MSVC with no INCLUDE dirs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !6284
2021-06-30 07:26:25 -04:00
Brad King
123b9e18f3 Merge branch 'release-3.21' 2021-06-30 07:26:25 -04:00
Brad King
eb2ea3db8b Merge topic 'compiler-id-msvc-has-include'
c6aaaf066a DetermineCompiler: Restore identification of MSVC with no INCLUDE dirs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !6284
2021-06-30 07:26:25 -04:00
Kitware Robot
82183329a5 CMake Nightly Date Stamp 2021-06-30 00:01:09 -04:00
Brad King
e27a76f131 target_link_libraries: Restore transitive out-of-dir linking
Refactoring in commit 7f506b95a7 (cmGeneratorTarget: Refactor link item
lookup, 2021-05-26, v3.21.0-rc1~103^2~4) accidentally dropped the
persistent lookup scope tracking across multiple items that was added by
commit f0e67da061 (target_link_libraries: Fix out-of-dir linking of a
list of targets, 2020-01-14, v3.17.0-rc1~149^2).  This broke a
transitive out-of-dir linking case not covered by our test suite.
Restore the scope tracking and add a test case.

Fixes: #22363
2021-06-29 16:52:12 -04:00
Brad King
c6aaaf066a DetermineCompiler: Restore identification of MSVC with no INCLUDE dirs
Since commit bd844387df (ROCMClang: Add the ROCm toolkit derived clang
compiler to CMake, 2020-08-28, v3.21.0-rc1~66^2~6), our generated
compiler id source file contains a preprocessor condition of the form

    #elif ... && __has_include(...)

When MSVC is invoked with no include directories in the `INCLUDE`
environment variable or in `-I` flags, its implementation of
`__has_include` errors out immediately.  This breaks identification of
the compiler.

Work around the problem by adding a fallback attempt to compile the
identification source using a dummy include directory.
2021-06-29 12:55:35 -04:00
Alex Sweet
9b53eca317 CPack/RPM: Fix weak dep support
RPM 4.11.3 for el7 contains backported support for the RPM weak dep tags.
It only supports querying those tags, but rpmbuild can not make use of them.
Since CPack relies on rpmbuild --querytags to check for support, this
commit switches to rpm --suggests to check for support of weak
dependencies.

Fixes: #22350
2021-06-29 11:14:54 -04:00
NAKAMURA Takumi
51bf4094fb Ninja: Use ccmake for edit_cache
If `ninja` is new enough to support the console pool, and `ccmake` is
available, use it for `edit_cache`.
2021-06-29 11:07:42 -04:00
NAKAMURA Takumi
7cb4ad7e39 cmGlobalCommonGenerator: Adopt GetEditCacheCommand
Move the implementation from the Makefile generator so it can be
later used by the Ninja generator too.
2021-06-29 11:07:14 -04:00
Brad King
da0f74b5a1 VS: Add ARM64EC to supported platforms for VS 16 and 17
In commit 4ea3a88625 (MSVC: Add support for targeting ARM64EC,
2020-12-30, v3.20.0-rc1~121^2) the `ARM64EC` platform was accidentally
added to the list for VS 15 (2017) instead of VS 16 (2019).  Its
omission from the list of platforms was then repeated for VS 17 (2022).

Issue: #21724
2021-06-29 10:59:05 -04:00
NAKAMURA Takumi
23af78bb78 cmGlobalCommonGenerator: Adopt GetEditCacheTargetName
The implementation is the same for both Makefile and Ninja generators.
2021-06-29 10:39:15 -04:00
NAKAMURA Takumi
1db4d74628 cmGlobalCommonGenerator: Add SupportsDirectConsole
Default to `true` since this is used by Makefile generators.
The Ninja generator already overrides it to use a version check.
2021-06-29 10:37:16 -04:00
NAKAMURA Takumi
61a737b088 cmGlobalNinjaGenerator: Rename SupportsConsolePool to SupportsDirectConsole
Use a name that is not ninja-specific.
2021-06-29 10:36:03 -04:00
Yuichiro Utsumi
6ce97c2248 FujitsuClang: Change LTO option from -flto=thin to -flto
Since -flto=thin is not supported officially in FujitsuClang,
change to -flto.
2021-06-29 09:31:53 -04:00
Yuichiro Utsumi
3a0effcd16 FujitsuClang: Set CMAKE_<LANG>_COMPILER_AR and CMAKE_<LANG>_COMPILER_RANLIB
Fixes: #22337
2021-06-29 09:31:53 -04:00
Brad King
d837efafa5 Merge topic 'test-CTestTestSerialInDepends-lockfile'
a5011a2fbf Tests: Cleanup CTestTestSerialInDepends lockfile at test start

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6273
2021-06-29 09:24:49 -04:00
Brad King
fb02657b6a Merge topic 'update-kwsys' into release-3.21
7e9a32947b Merge branch 'upstream-KWSys' into update-kwsys
bf4ae1c2b2 KWSys 2021-06-28 (0648cb1a)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Björn Esser <besser82@fedoraproject.org>
Merge-request: !6266
2021-06-29 09:23:28 -04:00
Brad King
0d9f8b0267 Merge branch 'release-3.21' 2021-06-29 09:23:28 -04:00
Brad King
5bc933ce96 Merge topic 'update-kwsys'
7e9a32947b Merge branch 'upstream-KWSys' into update-kwsys
bf4ae1c2b2 KWSys 2021-06-28 (0648cb1a)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Björn Esser <besser82@fedoraproject.org>
Merge-request: !6266
2021-06-29 09:23:28 -04:00
Brad King
543394af28 Merge topic 'tests-tolerate-NINJA_STATUS' into release-3.21
63177678d0 Tests/RunCMake/Ninja.*: Sanitize NINJA_STATUS since we expect default behavior

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6271
2021-06-29 09:22:05 -04:00
Brad King
3e8fc845f5 Merge branch 'release-3.21' 2021-06-29 09:22:05 -04:00
Brad King
dd6ce26f7e Merge topic 'tests-tolerate-NINJA_STATUS'
63177678d0 Tests/RunCMake/Ninja.*: Sanitize NINJA_STATUS since we expect default behavior

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6271
2021-06-29 09:22:05 -04:00
Brad King
a158ac723e Merge branch 'release-3.21' 2021-06-29 09:21:14 -04:00
Brad King
e3066e19df Merge topic 'test-driver-local-var'
1e3d3c5284 TestDriver: Avoid declaring local variable after statement

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6276
2021-06-29 09:21:14 -04:00
Brad King
9b4a5b4120 Merge topic 'test-driver-local-var' into release-3.21
1e3d3c5284 TestDriver: Avoid declaring local variable after statement

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6276
2021-06-29 09:21:13 -04:00
Brad King
901a910391 Merge branch 'release-3.21' 2021-06-29 09:20:17 -04:00
Brad King
4eb78f774c Merge topic 'curl-schannel-ALPN-length' into release-3.21
3faa3d3a38 curl: backport upstream fix to 7.77.0 regression

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6280
2021-06-29 09:20:17 -04:00
Brad King
2c5b758bba Merge topic 'curl-schannel-ALPN-length'
3faa3d3a38 curl: backport upstream fix to 7.77.0 regression

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6280
2021-06-29 09:20:17 -04:00
Marc Chevrier
616972197a Merge branch 'backport-3.21-CMP0126-WARNING' into CMP0126-WARNING 2021-06-29 13:41:10 +02:00
Marc Chevrier
16208ac113 CMP0126: Add control for warnings
Fixes: #22353
2021-06-29 13:36:28 +02:00