Commit Graph

12930 Commits

Author SHA1 Message Date
Brad King
7a4673965f Merge topic 'nvcc-isystem'
207fd956d8 CUDA: Use consistent -isystem flag style for NVIDIA nvcc

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7904
2022-11-14 10:32:32 -05:00
Brad King
38c8866dd1 Merge topic 'msvc-19.34-cpp-modules'
0e9782b336 msvc: bless MSVC 19.34 support for C++ modules as experimental

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7745
2022-11-14 10:18:21 -05:00
Brad King
6495e7e555 Merge topic 'iar-asm-archid'
f9ff6ab2d1 IAR: Fix ASM compiler architecture detection

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7903
2022-11-14 10:15:56 -05:00
Ben Boeckel
0e9782b336 msvc: bless MSVC 19.34 support for C++ modules as experimental
Visual Studio 17.4 now contains official support for what CMake needs.
2022-11-11 16:54:05 -05:00
YantaoZhao
207fd956d8 CUDA: Use consistent -isystem flag style for NVIDIA nvcc
Replace `-isystem=` with `-isystem ` for consistency with other compilers.

Fixes: #24154
2022-11-11 12:19:41 -05:00
Felipe Torrezan
f9ff6ab2d1 IAR: Fix ASM compiler architecture detection
Narrow the regex to match the actual supported architectures,
avoiding mismatched detection.

Fixes: #24145
2022-11-11 09:08:03 -05:00
Brad King
e159b5b2ae Merge topic 'doc-improvements'
d4d1f85297 Help: Move a note about arguments and genexes into include file
968224484f Help: Drop unused `PROPERTY_GENEX` replace from `prop_tgt/INTERFACE_*` files
65457e4fae Help: Add _See Also_ sections to related CMake commands
c86ec79d07 Help: Use direct refs to genexes instead of ``$<GENEX-NAME>``
8c6274326d Help: Use CMake highlighting for command synopsis
c356a94512 Help: Use monospaced font for a genex name in a section title
f98c8707f4 Help: Use `code-block:: cmake` instead of `::` for sub-commands descriptions
2ba351ca4f Help: ``CMake`` → CMake
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7873
2022-11-10 10:11:22 -05:00
Brad King
8dc7f6a443 Merge topic 'find_cuda_toolkit_support_symlink_math_dirs'
6f707ab541 FindCUDAToolkit: Support math_libs directory being a symlink

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7893
2022-11-10 10:04:01 -05:00
Robert Maynard
6f707ab541 FindCUDAToolkit: Support math_libs directory being a symlink
Fixes #24140
2022-11-09 16:04:00 -05:00
Ilia K
3166547cf6 ASM_MARMASM: Add support for Microsoft ARM assembler language
https://learn.microsoft.com/en-us/cpp/assembler/arm/arm-assembler-reference

Fixes: #23999
2022-11-09 10:22:46 -05:00
Brad King
7e0c00c251 Merge topic 'googletest-addtests-skipped'
f54963e60f GoogleTest: Reports skipped test with gtest_add_tests

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7868
2022-11-08 09:18:01 -05:00
Brad King
a0ad3209b5 Merge topic 'find-version-vars'
9e3f1723ff Find{BZip2,LibLZMA,ZLIB}: use *_VERSION as modern CMake

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Craig Scott <craig.scott@crascit.com>
Merge-request: !7877
2022-11-08 09:04:43 -05:00
Brad King
dab81ced1b Merge topic 'sphinx-linkcheck'
a89c76a773 Build: Add `SPHINX_LINKCHECK` build option
137b00cda1 Build: Do not redirect `sphinx-build` output if CMake running in verbose mode
d954fb8a60 Build: Deduplicate `add_custom_command()` calls for Sphinx targets
2af8724485 Merge branch 'backport-sphinx-linkcheck' into sphinx-linkcheck
435b0c573c Help: Fix some redirects reported with sphinx linkcheck
ac5295a9de Help: Fix broken external links found by sphinx linkcheck

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7876
2022-11-08 09:02:31 -05:00
Brad King
c30cd5fef1 Merge topic 'sphinx-linkcheck' into release-3.25
435b0c573c Help: Fix some redirects reported with sphinx linkcheck
ac5295a9de Help: Fix broken external links found by sphinx linkcheck

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7876
2022-11-08 09:02:30 -05:00
Brad King
6593aa8f06 Merge topic 'FindOpenSSL-mingw-lib64'
ed24414eee FindOpenSSL: Search "lib64" for mingw 64-bit installs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7875
2022-11-08 08:15:10 -05:00
Brad King
5e0bd923bd Merge topic 'FindOpenSSL-mingw-lib64' into release-3.25
ed24414eee FindOpenSSL: Search "lib64" for mingw 64-bit installs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7875
2022-11-08 08:15:09 -05:00
Brad King
2624c88e2f Merge topic 'tasking_remove_system_processor'
0a1d558971 Tasking: Remove CMAKE_SYSTEM_PROCESSOR support per CMP0123

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7879
2022-11-08 08:11:42 -05:00
Michael Hirsch
9e3f1723ff Find{BZip2,LibLZMA,ZLIB}: use *_VERSION as modern CMake
The old *_VERSION_STRING is silently left set for backward compat.
2022-11-07 16:22:31 -05:00
Alex Turbov
2ba351ca4f Help: `CMake` → CMake 2022-11-07 22:55:06 +04:00
Alex Turbov
1d3630203c Help: Use captions for code snippets in the FetchContent module
Instead of "manually" added captions use the Sphinx option of
`code-block` directive.
2022-11-07 22:55:06 +04:00
Brad King
2af8724485 Merge branch 'backport-sphinx-linkcheck' into sphinx-linkcheck 2022-11-07 10:09:27 -05:00
Alex Turbov
435b0c573c Help: Fix some redirects reported with sphinx linkcheck
Mostly it's about replace `http:` with `https:` protocol.
2022-11-07 10:07:36 -05:00
Alex Turbov
ac5295a9de Help: Fix broken external links found by sphinx linkcheck 2022-11-07 10:05:41 -05:00
Christoph Seitz
0a1d558971 Tasking: Remove CMAKE_SYSTEM_PROCESSOR support per CMP0123
Architecture specific compile options should be set through
toolchain files.

Fixes: #24115
2022-11-07 09:22:02 -05:00
klytje
ed24414eee FindOpenSSL: Search "lib64" for mingw 64-bit installs 2022-11-07 09:04:00 -05:00
Brad King
4ac37b8a0e Merge topic 'ExternalProject-INSTALL_BYPRODUCTS'
8c6b2928f4 ExternalProject: Add `INSTALL_BYPRODUCTS` option
6d6baffb85 Tests: Fix ExternalLibraryWithSubstitution test
4bcfff2df3 ExternalProject: Clarify `BYPRODUCTS` docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7866
2022-11-07 08:57:13 -05:00
Brad King
4e047870bc Merge topic 'CheckCompilerFlag-Swift'
2d5403ecaa CheckCompilerFlag: Add Swift Support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7865
2022-11-07 08:52:25 -05:00
DavidPerretSN
f54963e60f GoogleTest: Reports skipped test with gtest_add_tests
Skipped GTests were reported as success when tests where added with gtest_add_tests. This fixes this behaviour.

Fixes: #24130
2022-11-07 10:21:30 +01:00
Alex Turbov
029210730a Help: Use role :program:
When mention execitable names use Sphinx semantic role `:program`
instead of ``executable`` or **executable**.
2022-11-06 04:28:21 +04:00
Alois Klink
8c6b2928f4 ExternalProject: Add INSTALL_BYPRODUCTS option
Add an `INSTALL_BYPRODUCTS` option to `ExternalProject_Add` that can
be used to declare that files are `BYPRODUCTS` of the ExternalProject
install step.

This is often required by the Ninja generator to explicitly declare
dependencies. Previously, many users used `BUILD_BYPRODUCTS`, even if
their files were created by the install step, not the build step.

This commit essentially just copies the code for `BUILD_BYPRODUCTS`.

Fixes: #24120
Fixes: #23056
2022-11-05 16:26:45 +00:00
Evan Wilde
2d5403ecaa CheckCompilerFlag: Add Swift Support
Plumb through Swift `check_compiler_flag` support.
Add tests to check that valid flags work and invalid flags don't.
2022-11-04 09:32:06 -07:00
Brad King
c3b660710c Merge topic 'tasking-pic'
7e612977b9 Tasking: Fix PIC option for Tasking Toolset

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Christoph Seitz <christoph.seitz@posteo.de>
Merge-request: !7862
2022-11-04 11:28:24 -04:00
Brad King
7c52e9e951 Merge topic 'tasking-pic' into release-3.25
7e612977b9 Tasking: Fix PIC option for Tasking Toolset

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Christoph Seitz <christoph.seitz@posteo.de>
Merge-request: !7862
2022-11-04 11:28:23 -04:00
Alois Klink
4bcfff2df3 ExternalProject: Clarify BYPRODUCTS docs
Clarify that the `BUILD_BYPRODUCTS` and `BYPRODUCTS` options
in ExternalProject may also be required when using the Ninja
generator (as that's one of the primary reasons why you'd want to
use those options).

I've also mentioned that `add_custom_command` has additional
documentation on what `BYPRODUCTS` does.
2022-11-03 15:33:05 +00:00
Gordon Jess
7e612977b9 Tasking: Fix PIC option for Tasking Toolset
Fixes: #24114
2022-11-03 08:57:20 -04:00
Brad King
7e94e54f8f Merge topic 'correct_nvptxcompiler_not_linking_to_threads'
62f13ed588 FindCUDAToolkit: Restore usage from multiple directories

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7859
2022-11-03 08:15:13 -04:00
Brad King
32352abbd1 Merge topic 'correct_nvptxcompiler_not_linking_to_threads' into release-3.25
62f13ed588 FindCUDAToolkit: Restore usage from multiple directories

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7859
2022-11-03 08:15:12 -04:00
Brad King
db6123d66e Merge topic 'IAR-CXX-fix'
73e84a392b IAR: Restore support for CMAKE_CXX_FLAGS_INIT

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7857
2022-11-02 13:36:48 -04:00
Robert Maynard
62f13ed588 FindCUDAToolkit: Restore usage from multiple directories
Fixes #24119
2022-11-02 12:23:30 -04:00
Daniel Schürmann
73e84a392b IAR: Restore support for CMAKE_CXX_FLAGS_INIT
Prior to commit a9073db736 (IAR: update language specification
detection, 2021-09-23, v3.22.0-rc1~83^2) the `--c++`/`--eec++` flags
were stored in `CMAKE_IAR_CXX_FLAG` so that they would be used as part
of the `CMAKE_CXX_COMPILE_OBJECT` rule variable.  That commit moved the
flags to `CMAKE_CXX_FLAGS`, which also broke initialization of
`CMAKE_CXX_FLAGS` from `CMAKE_CXX_FLAGS_INIT`.  Restore the original
approach.

Fixes: #24111
2022-11-01 14:59:24 -04:00
Brad King
c18caa3a7d Merge topic 'FindCUDAToolkit-nvptxcompiler-static-deps'
301815eb62 FindCUDAToolkit: Add nvptxcompiler_static dependency on Threads::Threads

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7853
2022-11-01 08:52:38 -04:00
Robert Maynard
301815eb62 FindCUDAToolkit: Add nvptxcompiler_static dependency on Threads::Threads 2022-10-31 11:48:09 -04:00
Brad King
35a231bf0f Merge topic 'ewilde/swift-output-file-map-logic'
e88509d0e8 Swift: Omit output-file-map when used as a linker

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7835
2022-10-31 09:54:12 -04:00
Brad King
92fe99a0d0 Merge topic 'ArchLinux-lib-dir'
988b9928e4 Linux: Avoid finding libraries using lib64 on ArchLinux

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Felix Yan <felixonmars@archlinux.org>
Merge-request: !7849
2022-10-31 09:46:19 -04:00
Brad King
628d1c3396 Merge topic 'ArchLinux-lib-dir' into release-3.25
988b9928e4 Linux: Avoid finding libraries using lib64 on ArchLinux

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Felix Yan <felixonmars@archlinux.org>
Merge-request: !7849
2022-10-31 09:46:18 -04:00
Brad King
5b23e3021b Merge topic 'ninja-showIncludes-encoding'
a0d4e3bf34 cmGeneratedFileStream: Drop unused WriteRaw method
2e5af30ce0 Ninja: Match showIncludes dependencies using console output code page
e1c1679148 cm_codecvt: Add support for the Windows console output code page
328c15189d cmGeneratedFileStream: Add support for a temporary alternate encoding

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7845
2022-10-31 09:44:12 -04:00
Letu Ren
988b9928e4 Linux: Avoid finding libraries using lib64 on ArchLinux
ArchLinux uses `/lib` for 64-bit libraries and there is no `/lib64`.
However, unlike Debian, 32-bit libraries are in `/lib32`.
2022-10-30 08:52:59 -04:00
Brad King
2e5af30ce0 Ninja: Match showIncludes dependencies using console output code page
Generalize the fix from commit 37a279f8d1 (Ninja: Write msvc_deps_prefix
as UTF-8 when console codepage is UTF-8, 2020-07-31, v3.19.0-rc1~349^2).
`cl /showIncludes` output is encoded using the console output code page,
so this is the byte sequence that Ninja must use to match its lines.

Fixes: #24068
2022-10-30 08:29:55 -04:00
Evan Wilde
e88509d0e8 Swift: Omit output-file-map when used as a linker
Swift is used as the linker for non-swift files because it needs to pull
files like swiftrt.o in when swift symbols are present to ensure that
the swift runtime is linked.

The swift driver uses clang as the underlying linker, which pulls in
crtbegin.o and friends when appropriate, so using Swift as a linker for
C/C++ libraries is fine.

The output-file-map was getting passed to all Swift invocations,
regardless of whether or not we generated one. This patch changes it so
that we only include the output-file-map in the Swift compiler
invocation if we have actually generated the file.
2022-10-28 16:44:26 -07:00
Brad King
5b9fc1062b Merge topic 'FindGLUT-pkg-config'
919ab832e8 FindGLUT: Fix regression when pkg-config is not available

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7840
2022-10-28 10:00:04 -04:00