Commit Graph

30969 Commits

Author SHA1 Message Date
Kitware Robot
82183329a5 CMake Nightly Date Stamp 2021-06-30 00:01:09 -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
Kitware Robot
06d2c3fce4 CMake Nightly Date Stamp 2021-06-29 00:01:13 -04:00
Brad King
7e9a32947b Merge branch 'upstream-KWSys' into update-kwsys
# By KWSys Upstream
* upstream-KWSys:
  KWSys 2021-06-28 (0648cb1a)
2021-06-28 13:32:23 -04:00
Brad King
c8d2e81e09 Merge topic 'target_compile_features-only-apply-to-enabled-languages'
a3cafa4237 compile_features: Ignore features that map to languages that aren't enabled

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6255
2021-06-28 09:26:02 -04:00
Brad King
117b1545a9 Merge topic 'vs2022' into release-3.21
93c718791e VS: Use 64-bit MSBuild in VS 2022
c46b265839 VS: Add Visual Studio 17 2022 generator
b610b7a35c VS: Update v142 CL flag table for VS 17.0 Preview 1
43375c6418 Help: Remove unnecessary Sphinx versionadded markup in VS toolset selection

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6268
2021-06-28 09:22:38 -04:00
Brad King
be78a9bf68 Merge topic 'vs2022'
93c718791e VS: Use 64-bit MSBuild in VS 2022
c46b265839 VS: Add Visual Studio 17 2022 generator
b610b7a35c VS: Update v142 CL flag table for VS 17.0 Preview 1
43375c6418 Help: Remove unnecessary Sphinx versionadded markup in VS toolset selection

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6268
2021-06-28 09:22:38 -04:00
Brad King
0adcdd2e00 Merge topic 'ninja-lwyu-flag-order'
d7159f9591 Ninja: Fix LINK_WHAT_YOU_USE link flag placement

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6263
2021-06-28 09:20:10 -04:00
Kitware Robot
25d7cd9671 CMake Nightly Date Stamp 2021-06-28 00:01:16 -04:00
Kitware Robot
66a0f46f9f CMake Nightly Date Stamp 2021-06-27 00:01:07 -04:00
Kitware Robot
cd809b8ea4 CMake Nightly Date Stamp 2021-06-26 00:01:09 -04:00
Robert Maynard
a3cafa4237 compile_features: Ignore features that map to languages that aren't enabled
Remove the Cuda/ConsumeCompileFeatures test as it only existed to
validate that using `cxx_std_XY` would cause the paired language (CUDA) to also build in mode XY.
2021-06-25 13:39:50 -04:00
Brad King
93c718791e VS: Use 64-bit MSBuild in VS 2022
Visual Studio 17 2022 is now a 64-bit native application.  It places the
64-bit `MSBuild.exe` in the `PATH` of VS command prompts, so prefer it
for this version and above.

This was previously attempted for older VS versions, but reverted by
commit f3cedf381e (VS: Revert "Use MSBuild matching toolset host
architecture", 2019-03-12, v3.14.0~1^2).  For now, do not use the 64-bit
MSBuild for VS 16 and below.

Fixes: #18219
2021-06-25 12:45:53 -04:00
Brad King
c46b265839 VS: Add Visual Studio 17 2022 generator
Fixes: #22339
2021-06-25 12:45:44 -04:00
Đoàn Trần Công Danh
d7159f9591 Ninja: Fix LINK_WHAT_YOU_USE link flag placement
Move `-Wl,--no-as-needed` from the `<FLAGS>` placeholder to
`<LINK_FLAGS>`, as it is in the Makefile generators.

Fixes: #22342
2021-06-25 08:45:47 -04:00
Brad King
a6b075c3f8 Merge topic 'import-elf'
115ff6a347 cmELF: Include the ELF parsing code unconditionally
5dfa3ddbe5 cmELF: Allow building without system ELF headers
0da1540aaa cmELF: Fix check for TagMipsRldMapRel
e21188df8b cmELF: Open file explicitly in binary mode
70cdb36d25 Merge branch 'upstream-elf' into import-elf
7a0a37ca41 elf 2021-06-23 (f13da247)
18038042ed cmelf: Add script to import the FreeBSD ELF headers

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6240
2021-06-25 07:26:35 -04:00
Kitware Robot
ed295f63ec CMake Nightly Date Stamp 2021-06-25 00:01:08 -04:00
Alex Richardson
115ff6a347 cmELF: Include the ELF parsing code unconditionally
Now that the ELF definitions are provided on all platforms there is no
need to keep the CMake_USE_ELF_PARSER option.
2021-06-24 10:57:51 -04:00
Alex Richardson
5dfa3ddbe5 cmELF: Allow building without system ELF headers
Use ELF headers vendored in `Utilities/cmelf` to get the ELF constants
and types. Using the same ELF definition header for all compilation
targets allows removing some #ifdefs depending on the host OS since we
know all required ELF constants will always be present. To reduce the
size of this commit, the CMake_USE_ELF_PARSER definite will be removed
in a separate commit.

This allows me to use CMAKE_BUILD_WITH_INSTALL_RPATH=False and the Ninja
generator on macOS, whereas before it would always give me the following
error message (despite cross-compiling for an ELF-based platform):

```
The install of the <name> target requires changing an RPATH from
  the build tree, but this is not supported with the Ninja generator unless
  on an ELF-based platform.  The CMAKE_BUILD_WITH_INSTALL_RPATH variable may
  be set to avoid this relinking step.
```
2021-06-24 10:57:51 -04:00
Alex Richardson
0da1540aaa cmELF: Fix check for TagMipsRldMapRel
DT_MIPS_RLD_MAP_REL is a machine-speicific dynamic tag, so other
architectures could re-use the value of 0x70000035 to mean something
else.  Before using DT_MIPS_RLD_MAP_REL, we have to check that the ELF
file is actually has a e_machine of EM_MIPS.
2021-06-24 10:57:51 -04:00
Brad King
e21188df8b cmELF: Open file explicitly in binary mode
ELF is a binary format.
2021-06-24 10:57:51 -04:00
Brad King
004a51e0c2 Merge topic 'fortran-compiler-intrinsics'
fe3f846e1b Makefiles: Add support for building Fortran intrinsics

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5518
2021-06-24 09:12:15 -04:00
Isuru Fernando
fe3f846e1b Makefiles: Add support for building Fortran intrinsics
Fixes: #21463
2021-06-24 08:39:47 -04:00
Kitware Robot
55d9199f7c CMake Nightly Date Stamp 2021-06-24 00:01:11 -04:00
Brad King
0aae790a5e CMake 3.21.0-rc1 2021-06-23 09:01:47 -04:00
Brad King
6c5f21d10e Merge topic 'clang-compiler-warnings'
88e56c2e5a Enable compiler warnings when compiling CMake with Clang
cadf2b632e Fix -Wpessimizing-move warnings in QCMake::loadPresets()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6252
2021-06-23 08:56:28 -04:00
Kitware Robot
fd2aa87278 CMake Nightly Date Stamp 2021-06-23 00:01:09 -04:00
Alex Richardson
cadf2b632e Fix -Wpessimizing-move warnings in QCMake::loadPresets() 2021-06-22 16:13:21 +01:00
Brad King
66488d4eb3 Merge topic 'cmsystemtools-multiple-formats'
2e1149874d cmSystemTools: Support multiple binary formats

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6239
2021-06-22 09:44:06 -04:00
Kitware Robot
ea02397dab CMake Nightly Date Stamp 2021-06-22 00:01:10 -04:00
Brad King
d60d6c269a Merge topic 'ctest_runtime_labels'
bd38749fd4 ctest: allow test output to add labels

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6234
2021-06-21 09:52:36 -04:00
Brad King
cbdd6747ad Merge topic 'msvc-isystem'
f29e1874ad Compiler/MSVC: use the `-external:I` flag for system includes
5a5c85dffd Tests/IncludeDirectories: support MSVC in system include tests
399a3204bb Tests/IncludeDirectories: align sibling predicates
20ab49193b Tests/IncludeDirectories: factor out applying flags to targets
809f7b0c3a Tests/IncludeDirectories: fix copy pasta for otherlib
b094324948 Tests/IncludeDirectories: Include system headers via angle brackets
8f63f3b04e cmVisualStudio10TargetGenerator: remove unused variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Julien Waechter <greenjava@gmail.com>
Acked-by: DE-VS wenglor <devs.wenglor@gmail.com>
Merge-request: !4766
2021-06-21 09:50:52 -04:00
Alex Richardson
2e1149874d cmSystemTools: Support multiple binary formats
This prepares the code to handle both the ELF and XCOFF being enabled by
trying to parse an ELF file first and if that fails falling back to XCOFF.
2021-06-21 09:36:39 -04:00
Kitware Robot
858164d155 CMake Nightly Date Stamp 2021-06-21 00:01:20 -04:00
Kitware Robot
93a63425b6 CMake Nightly Date Stamp 2021-06-20 00:02:10 -04:00
Kitware Robot
4e518a852a CMake Nightly Date Stamp 2021-06-19 00:01:13 -04:00
Ben Boeckel
f29e1874ad Compiler/MSVC: use the -external:I flag for system includes
See: #17904
2021-06-18 09:54:17 -04:00
Brad King
d64d2d12c3 Merge topic 'vs-utf-8' into release-3.21
9ba99a1203 VS: Add support for Utf8Enconding when using VS 16.10+

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6238
2021-06-18 09:39:24 -04:00
Brad King
c35273c22d Merge topic 'vs-utf-8'
9ba99a1203 VS: Add support for Utf8Enconding when using VS 16.10+

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6238
2021-06-18 09:39:24 -04:00
Brad King
57322b572d Merge topic 'vs-flag-tables'
b0f830ced6 VS: Do not apply any '/external:*' flag table mapping on VS < 16.10
3fd65f5ca6 VS: Compare VS instance versions as strings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6241
2021-06-18 09:38:27 -04:00
Brad King
333e1973ce Merge topic 'vs-flag-tables' into release-3.21
b0f830ced6 VS: Do not apply any '/external:*' flag table mapping on VS < 16.10
3fd65f5ca6 VS: Compare VS instance versions as strings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6241
2021-06-18 09:38:26 -04:00
Kitware Robot
5ef8c09a8f CMake Nightly Date Stamp 2021-06-18 00:01:12 -04:00
Zack Galbreath
bd38749fd4 ctest: allow test output to add labels
Parse test output for <CTestLabel>...</CTestLabel>.
If found, add this value to the list of labels associated with this test.
2021-06-17 14:09:01 -04:00
Ben Boeckel
8f63f3b04e cmVisualStudio10TargetGenerator: remove unused variable 2021-06-17 14:02:52 -04:00
Gustavo Varo
9ba99a1203 VS: Add support for Utf8Enconding when using VS 16.10+
On VS 16.10 Preview 2 or above, generate `UseUtf8Encoding`
instead of `StdOutEncoding=UTF-8` in `.vcxproj` files.

Fixes: #22032
2021-06-17 13:44:22 -04:00
Brad King
11695f5985 Begin post-3.21 development 2021-06-17 13:18:30 -04:00
Brad King
22fb0713a2 Begin 3.21 release versioning 2021-06-17 13:17:06 -04:00
Brad King
b0f830ced6 VS: Do not apply any '/external:*' flag table mapping on VS < 16.10
Since commit 887e9df0c7 (VS: Update v142 CL flag table for VS 16.10,
2021-06-04) we map several `/external:*` flags to their corresponding
`.vcxproj` elements.  These elements were added to `cl.xml` in VS 16.10,
so filter them out in older VS versions.  Add a field to the json flag
table format to specify the minimum version of VS needed for a given
mapping.

Issue: #22308
2021-06-17 08:25:04 -04:00
Brad King
3fd65f5ca6 VS: Compare VS instance versions as strings
This makes the values more readable.
2021-06-17 07:54:48 -04:00
Brad King
1aa16906e6 Merge topic 'fix-flow-control-override'
c017098d4d CMake: Allow override of unexpected non-flow-control commands

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6232
2021-06-17 06:47:42 -04:00