Commit Graph

56249 Commits

Author SHA1 Message Date
Kyle Edwards
8c23ecbd93 target_sources(): Process multiple FILE_SET arguments per block
Fixes: #23287
2022-03-03 14:31:54 -05:00
Brad King
04a7200c75 Merge topic 'cuda-arch-all' into release-3.23
2796d6eeca CUDA: Fix CMAKE_CUDA_ARCHITECTURES=all/all-major with NVCC 11.5+
e450d55552 Help: Update CUDA_ARCHITECTURES docs for generic all/all-major support
fe64c49e72 CUDA: Simplify CMAKE_CUDA_ARCHITECTURES special value logic

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7026
2022-03-02 07:52:17 -05:00
Brad King
f0f4390325 Merge topic 'doc-presets-v4' into release-3.23
6404751176 Help: Improve wording and structure related to preset includes

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7028
2022-03-02 07:49:44 -05:00
Brad King
4b9227e718 Merge topic 'find_file_frameworks_debug_output' into release-3.23
3354d52e3d find_file: Fix blank line instead of framework path in debug output

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7024
2022-03-02 07:46:57 -05:00
Brad King
66a7d2e222 Merge topic 'file-set-no-custom-targets' into release-3.23
ad41c9cd11 target_sources(): Prohibit FILE_SET on custom targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7027
2022-03-02 07:45:57 -05:00
Craig Scott
6404751176 Help: Improve wording and structure related to preset includes
Encourage placing preset includes near the beginning of a preset
file and ensure the example shows that usage. Move the prose
discussing includes to its own section to improve discoverability
and break up paragraphs to make each main point harder to miss.

Also clarify ${sourceDir} to remove any ambiguity with regard to
its meaning in included files.

Issue: #23214
2022-03-02 11:37:57 +11:00
Brad King
2796d6eeca CUDA: Fix CMAKE_CUDA_ARCHITECTURES=all/all-major with NVCC 11.5+
Changes in commit 8f64df0a7c (CUDA: Generic all and all-major support,
2021-12-19, v3.23.0-rc1~23^2) broke our architecture verification checks
when using `-arch={all,all-major}` with NVCC 11.5+.  If we test the
compiler with `-arch={all,all-major}`, we have no expected list of
architectures, so skip the check.

Fixes: #23278
2022-03-01 12:16:40 -05:00
Brad King
50d2d438cc Merge topic 'doc-crosscompiling-emulator-arg-list-3.15' into release-3.23
6ff1217b9c Help: Add missing versionadded to *CROSSCOMPILING_EMULATOR

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7023
2022-03-01 08:41:51 -05:00
Brad King
287199074f Merge branch 'release-3.22' into release-3.23 2022-03-01 08:38:52 -05:00
Brad King
893ba6c5c3 Merge topic 'FindThreads-revert-libc-pthread-flag' into release-3.23
c6da90bd39 FindThreads: Revert "Honor THREADS_PREFER_PTHREAD_FLAG when ... in libc"

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7025
2022-03-01 08:37:58 -05:00
Brad King
e450d55552 Help: Update CUDA_ARCHITECTURES docs for generic all/all-major support
Since commit 8f64df0a7c (CUDA: Generic all and all-major support,
2021-12-19, v3.23.0-rc1~23^2), these special values do not require any
specific compiler or version.

While at it, re-organize CUDA_ARCHITECTURES special value documentation.
Move the `versionadded` markup inside each special value so we can add
more in future versions.
2022-02-28 21:30:23 -05:00
Brad King
fe64c49e72 CUDA: Simplify CMAKE_CUDA_ARCHITECTURES special value logic
Refactor the logic checking `CMAKE_CUDA_ARCHITECTURES` special values.
Switch on the value first, and then make other decisions for each case.
This makes room for other special values to be added later.
2022-02-28 21:30:23 -05:00
Craig Scott
3354d52e3d find_file: Fix blank line instead of framework path in debug output
There's no point printing a blank line if FindHeaderInFramework()
returns an empty string. Pass in the debug object to that function
instead so it can record the actual paths it tests in the debug output
directly.
2022-03-01 09:28:22 +11:00
Kyle Edwards
ad41c9cd11 target_sources(): Prohibit FILE_SET on custom targets
Fixes: #23262
2022-02-28 17:21:04 -05:00
Brad King
371235e0d7 Merge branch 'release-3.21' into release-3.22 2022-02-28 13:09:25 -05:00
Brad King
7a16688f02 Merge branch 'FindThreads-revert-libc-pthread-flag' into release-3.22
Merge-request: !7025
2022-02-28 13:09:19 -05:00
Brad King
02b04f1ca8 Merge branch 'FindThreads-revert-libc-pthread-flag' into release-3.21
Merge-request: !7025
2022-02-28 13:09:00 -05:00
Brad King
c6da90bd39 FindThreads: Revert "Honor THREADS_PREFER_PTHREAD_FLAG when ... in libc"
Revert commit 5efb6fb516 (FindThreads: Honor THREADS_PREFER_PTHREAD_FLAG
when pthread is found in libc, 2021-11-03, v3.21.5~4^2).  The check for
the `-pthread` flag can pass on compilers like XL, that interprets it as
`-p -t hread` and returns zero.  Prior to that commit, we did not use
the check in the `CMAKE_HAVE_LIBC_PTHREAD` code path.  Now we do, it
succeeds, and we incorrectly add the `-pthread` flag for XL.

This change was backported to the 3.21 and 3.22 release series long
after they initially came out.  Since there may be more cases where we
now add `-pthread` incorrectly, it is simplest to revert the change in
all release series pending further investigation.

Fixes: #23270
2022-02-28 12:53:15 -05:00
friendlyanon
6ff1217b9c Help: Add missing versionadded to *CROSSCOMPILING_EMULATOR
The list capability was added in CMake 3.15 by commit fec441ec17 (Teach
CROSSCOMPILING_EMULATOR to support arguments, 2019-05-30,
v3.15.0-rc1~6^2), but the documentation did not indicate the version
that added it.
2022-02-28 10:40:22 -05:00
Brad King
07a7772968 Merge topic 'ninja-gfortran-preprocess' into release-3.23
6b4885b58b Ninja: Avoid preprocessing twice with explicit Fortran_PREPROCESS

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7008
2022-02-25 08:07:35 -05:00
Brad King
7d110c25ed Merge topic 'ghs_fix_rtos_dir' into release-3.23
005c7dc9e7 GHS: Store full path of Integrity OS directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7017
2022-02-24 13:01:39 -05:00
Peter Hill
6b4885b58b Ninja: Avoid preprocessing twice with explicit Fortran_PREPROCESS
Fix spurious warnings from gfortran+Ninja for preprocessing.

Fixes: #23248
2022-02-24 12:54:46 -05:00
Fred Baksik
005c7dc9e7 GHS: Store full path of Integrity OS directory
Fixes build project error because the OS directory was a relative
path from the binary directory.

Fixes issue during project regeneration where the `-os_dir` project option
was missing because GHS_OS_DIR was not properly stored in the cache
file.

This error was introduced by commit aa59eaac4f (GHS: Allow setting GHS
variables from toolchain file, 2021-11-15, v3.23.0-rc1~337^2).
2022-02-23 11:33:35 -05:00
Brad King
352ea99bba CMake 3.23.0-rc2 v3.23.0-rc2 2022-02-23 09:22:31 -05:00
Brad King
bc0d7c19db Merge topic 'update-expat' into release-3.23
07f9ce4f8c Merge branch 'upstream-expat' into update-expat
4c031b9417 expat 2022-02-20 (65a21f2b)
9d035ba28d expat: Update script to get Expat 2.4.6

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7015
2022-02-23 09:00:36 -05:00
Brad King
07f9ce4f8c Merge branch 'upstream-expat' into update-expat
# By Expat Upstream
* upstream-expat:
  expat 2022-02-20 (65a21f2b)
2022-02-22 17:11:37 -05:00
Expat Upstream
4c031b9417 expat 2022-02-20 (65a21f2b)
Code extracted from:

    https://github.com/libexpat/libexpat.git

at commit 65a21f2b2a306d29b44e70264aca948aa0454219 (R_2_4_6).
2022-02-22 17:11:37 -05:00
Brad King
9d035ba28d expat: Update script to get Expat 2.4.6 2022-02-22 17:11:28 -05:00
Brad King
2e963c41b4 Merge topic 'cuda-archs' into release-3.23
f75299b803 CUDA: Restore support for non-"all" CUDA_ARCHITECTURES with nvcc 11.5+

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7007
2022-02-22 12:56:50 -05:00
Brad King
e6a364c999 Merge topic 'CheckTypeSize-doc' into release-3.23
65e4d29e35 CheckTypeSize: Modernize and clarify documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7006
2022-02-22 12:55:54 -05:00
Brad King
f75299b803 CUDA: Restore support for non-"all" CUDA_ARCHITECTURES with nvcc 11.5+
Since commit 8f64df0a7c (CUDA: Generic all and all-major support,
2021-12-19, v3.23.0-rc1~23^2), setting `CUDA_ARCHITECTURES` to a value
other than `all` or `all-major` is ignored with NVCC 11.5+.  Fix the
logic to return early only when actually using an "all" value.

Fixes: #23243
2022-02-18 12:54:12 -05:00
Brad King
65e4d29e35 CheckTypeSize: Modernize and clarify documentation
Spell out the list of result variables as a definition list rather
than in prose.

Fixes: #23247
2022-02-18 11:33:06 -05:00
Brad King
a1cb448580 Merge topic 'correct_multiple_source_warnings' into release-3.23
7083b19498 cmake: When given multiple source paths use last instead of first

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7001
2022-02-18 09:01:21 -05:00
Brad King
ae5f8684f9 Merge topic 'file-set-no-exist' into release-3.23
058b8a0bfb install(): Properly ignore FILE_SETs that don't exist

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7000
2022-02-18 08:57:31 -05:00
Brad King
a99c73852e Merge branch 'release-3.22' into release-3.23 2022-02-18 08:54:27 -05:00
Brad King
e9832cc298 Merge topic 'test-qt-disable' into release-3.23
5bfff3c750 Tests: Add missing guards on Qt4 and Qt5 tests

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6998
2022-02-18 08:52:48 -05:00
Brad King
abc12c4e96 Merge topic 'libarchive-openssl-crypto-checks' into release-3.23
483a1c248c libarchive: Fix OpenSSL crypto library checks for build inside CMake

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6997
2022-02-18 08:51:54 -05:00
Robert Maynard
7083b19498 cmake: When given multiple source paths use last instead of first
When given two source paths via `-S` or just directory paths prefer
the last one. When the paths are mixed always prefer the last `-S`
entry.

Fixes: #23238
2022-02-17 16:54:30 -05:00
Kyle Edwards
058b8a0bfb install(): Properly ignore FILE_SETs that don't exist
Fixes: #22960
2022-02-17 14:43:06 -05:00
Brad King
fa9bba4905 Merge branch 'test-qt-disable' into release-3.22
Merge-request: !6998
2022-02-17 11:11:20 -05:00
Brad King
5bfff3c750 Tests: Add missing guards on Qt4 and Qt5 tests
Add missing `CMake_TEST_Qt{4,5}` conditions on Qt4 an Qt5 tests.
Configuring CMake with `-DCMake_TEST_Qt5=OFF` should prevent any
attempt to search for Qt5.

Fixes: #23239
2022-02-17 11:00:25 -05:00
Brad King
9c81f2cb8b Merge topic 'cmake-empty-cmd-line-arg' into release-3.23
f73457ca2e cmake: Ignore any empty "" command line arguments
67f97f5478 Tests: Add RunCMake helper to run cmake with raw execute_process args

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6980
2022-02-17 08:45:52 -05:00
Brad King
ed9e7a2732 Merge topic 'test-cuda-sepcomp-ptx' into release-3.23
a7ef59c9c4 Tests: Fix CudaOnly.SeparateCompilationPTX test project name

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6991
2022-02-17 08:43:39 -05:00
Brad King
483a1c248c libarchive: Fix OpenSSL crypto library checks for build inside CMake
libarchive's crypto library checks use its `config.h` inside the
`try_compile` project.  Since commit ade3b16e63 (libarchive: Use KWIML
to get fixed-size integer types, 2020-06-01, v3.18.0-rc1~33^2),
that header depends on KWIML inside CMake.  Add the include directory
for KWIML to the crypto library checks.  Otherwise, they always fail
due to not finding the KWIML headers, and libarchive decides not
to link the crypto library.

libarchive has other code besides the hash algorithms that depends on
the crypto library if its ENABLE_OPENSSL option is enabled (which in
CMake is controlled by CMAKE_USE_OPENSSL).  It seems to be missing some
conditions to link the crypto library in those cases, and instead relies
on at least one of the above-mentioned checks to pass.  If they all
fail, and we are using system curl, we might not link the crypto
library.

Fixes: #23234
2022-02-17 08:06:01 -05:00
Robert Maynard
f73457ca2e cmake: Ignore any empty "" command line arguments
Don't treat empty quote arguments("") as the current working
directory but instead ignore them.

Fixes #23217
2022-02-16 12:11:33 -05:00
Brad King
67f97f5478 Tests: Add RunCMake helper to run cmake with raw execute_process args 2022-02-16 12:10:19 -05:00
Brad King
368dc57979 Merge topic 'tll-genex-concat' into release-3.23
c1e812ad4f target_link_libraries: Improve tolerance of unquoted generator expressions
5571a31648 target_link_libraries: Handle keyword arguments in dedicated code path
42590df9f9 target_link_libraries: Remove likely-broken ancient compatibility check

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !6989
2022-02-16 09:47:45 -05:00
Brad King
bd575a2918 Merge branch 'release-3.22' into release-3.23 2022-02-16 09:43:48 -05:00
Brad King
809cb5b76a Merge topic 'FindGLUT-link-dirs' into release-3.23
44f7238d5d FindGLUT: Use link directories for libs from pkg-config

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6985
2022-02-16 09:42:53 -05:00
Brad King
1f4976d959 Merge topic 'FindHDF5-info-binary-exists' into release-3.23
449f343498 FindHDF5: Tolerate failure during compiler interrogation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6983
2022-02-16 09:41:57 -05:00