Commit Graph

12441 Commits

Author SHA1 Message Date
Brad King 2045e1eee0 Merge topic 'less_ptx_for_all_all-major_native'
e8591f1516 CUDA: native/all/all-major generates minimal set of ptx code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Raul Tambre <raul@tambre.ee>
Merge-request: !7216
2022-05-04 11:18:28 -04:00
Brad King 1784440bd0 Merge topic 'cpack-nsis-typos'
125f6964ba CPack/NSIS: Fix several typos in the NSIS template

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7227
2022-05-04 11:11:09 -04:00
Brad King 8aff3e41a8 Merge topic 'FindThreads-aix'
3257c34073 FindThreads: avoid failing in AIX when using -D_XOPEN_SOURCE=500

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7230
2022-05-04 11:08:38 -04:00
Brad King d47e466935 Merge topic 'FindPython-fix-typo-error'
fff8d5b212 FindPython: fix typo error

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7233
2022-05-04 11:07:10 -04:00
Sadie Powell 125f6964ba CPack/NSIS: Fix several typos in the NSIS template 2022-05-03 12:47:27 -04:00
Carlo Marcelo Arenas Belón 3257c34073 FindThreads: avoid failing in AIX when using -D_XOPEN_SOURCE=500
Current FindThreads fails in AIX (tested on 7.1 and 7.2) when using
additional compilation flags (ex: -D_XOPEN_SOURCE=500) because the
linker might need additional flags to link and those aren't yet known
by the time check_include("pthread.h") is run (which is also the first
test).

Remove the check for it and all supporting code and rely instead on
the compilation test that will be done later to find the correct
syntax to use, and that confirms it exists implicitly.
2022-05-03 12:26:18 -04:00
Robert Maynard e8591f1516 CUDA: native/all/all-major generates minimal set of ptx code
Fixes #23459
2022-05-03 11:52:23 -04:00
Brad King 252fdfe6e4 Merge topic 'cuda-arch-verify'
7bf5200699 CUDA: Restore CMAKE_CUDA_ARCHITECTURES support for -real and -virtual suffixes

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewd-by: Raul Tambre <raul@tambre.ee>
Merge-request: !7218
2022-05-03 11:26:40 -04:00
Marc Chevrier fff8d5b212 FindPython: fix typo error
Fixes: #23476
2022-05-03 10:46:13 +02:00
Brad King 7bf5200699 CUDA: Restore CMAKE_CUDA_ARCHITECTURES support for -real and -virtual suffixes
Fix the validation regex added by commit c267ed205a (CUDA: Defer
architecture testing to the compiler testing step, 2022-04-25) to
allow these values.
2022-04-29 09:07:53 -04:00
Brad King d71d555153 Merge topic 'findmpi_dont_variable_lang'
c9c2e040aa FindMPI: Don't check for variables named the same as the languages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7208
2022-04-28 09:37:23 -04:00
Brad King d35f1c9bee Merge topic 'cuda-arch-verify'
c267ed205a CUDA: Defer architecture testing to the compiler testing step

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robertjmaynard@gmail.com>
Acked-by: Raul Tambre <raul@tambre.ee>
Merge-request: !7202
2022-04-28 09:36:31 -04:00
Brad King 4b63f2ca4a Merge topic 'FindThreads-cleanup'
c53748a377 FindThreads: Factor out helper macro for libc check
564385194b FindThreads: Avoid repeating check for -pthread flag
41ef904e81 FindThreads: Simplify conditions for not-in-libc checks
cbe7550d99 FindThreads: Remove unnecessary condition
1ee8c545dd FindThreads: Clarify internal helper macro names
5b5cd92363 FindThreads: Drop strange SunOS+pthread.h+thr_create combination
c9bd462c08 FindThreads: Drop unused internal CMAKE_HAVE_THREADS_LIBRARY variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: Rolf Eike Beer <eike@sf-mail.de>
Merge-request: !7207
2022-04-27 08:53:18 -04:00
Brad King 54f7955382 Merge topic 'CUDAToolkit-cupti-include-dirs'
e6b51a1b01 CUDAToolkit: Add include paths for CUDA::cupti

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Robert Maynard <robertjmaynard@gmail.com>
Merge-request: !7200
2022-04-27 08:50:07 -04:00
Brad King 967a1037b2 Merge topic 'FindBoost-1.79'
f90fb73651 FindBoost: Add support for Boost 1.79

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7205
2022-04-27 08:43:49 -04:00
Robert Maynard c9c2e040aa FindMPI: Don't check for variables named the same as the languages
We want to see if a language is inside `MPI_FIND_COMPONENTS` not if
the variables `C`/`CXX` is set to a positive value.
2022-04-26 16:16:31 -04:00
Brad King c53748a377 FindThreads: Factor out helper macro for libc check 2022-04-26 13:54:53 -04:00
Brad King 564385194b FindThreads: Avoid repeating check for -pthread flag
When `THREADS_PREFER_PTHREAD_FLAG` is enabled, we check for it before
the thread libraries.  We do not need to check after them too.
2022-04-26 13:54:53 -04:00
Brad King 41ef904e81 FindThreads: Simplify conditions for not-in-libc checks
If `CMAKE_HAVE_LIBC_PTHREAD` is true, we also set `Threads_FOUND` to
true, which blocks all the other checks from running.
2022-04-26 13:54:53 -04:00
Brad King cbe7550d99 FindThreads: Remove unnecessary condition
The `THREADS_HAVE_PTHREAD_ARG` cache entry cannot be defined unless
FindThreads has already been executed, perhaps by a previous run of
CMake, or a previous `find_package(Threads)` call.  In that case, the
other alternatives will also already have been checked and results
cached.
2022-04-26 13:54:53 -04:00
Brad King 1ee8c545dd FindThreads: Clarify internal helper macro names 2022-04-26 13:54:53 -04:00
Brad King 5b5cd92363 FindThreads: Drop strange SunOS+pthread.h+thr_create combination
Solaris has provided pthreads for a long time, so we probably never
get to this combination anyway.
2022-04-26 13:54:53 -04:00
Brad King c9bd462c08 FindThreads: Drop unused internal CMAKE_HAVE_THREADS_LIBRARY variable
This internal variable has not been used since commit 46368eddfd
(FindThreads: move checking of the -pthread compiler flag into a macro,
2014-10-06, v3.1.0-rc1~21^2~2).  It has never been documented for public
use.
2022-04-26 13:54:53 -04:00
Peter Bell e6b51a1b01 CUDAToolkit: Add include paths for CUDA::cupti
CUDA's cupti library has its headers in a seperate directory on a
standard CUDA install, but `CUDA::cupti` only adds the default cuda
include directory.

Issue: #22761
2022-04-26 13:48:02 -04:00
Brad King f90fb73651 FindBoost: Add support for Boost 1.79
Update the list of known versions.

Run the command

    cmake -DBOOST_DIR=/path/to/boost_1_79_0 \
      -P Utilities/Scripts/BoostScanDeps.cmake

to extract dependencies from the 1.79.0 source tree.
They are the same as 1.78's dependencies, so just update
the version check for warning about newer versions.

Fixes: #23452
2022-04-26 11:23:16 -04:00
Brad King c267ed205a CUDA: Defer architecture testing to the compiler testing step
Verifying the architectures during compiler identification is redundant,
and requires a lot more up-front information than we should need.
It also causes unsupported architectures to break the compiler id and
version detection, so the resulting output from CMake does not report
the compiler version, which is useful information to know why the
specified architectures are not supported.

The "detecting compiler ABI info" and "check for working compiler" steps
already pass `CMAKE_CUDA_ARCHITECTURES` into their test projects.
Therefore we can just drop the earlier architecture testing.  Bad
architectures will be reported as a not-working compiler, and the
output will include the compiler's error message.

This reverts the approach from:

* commit 19cc5bc296 (CUDA: Throw error if user-specified architectures
                     don't work, 2020-05-26, v3.18.0-rc1~79^2)
* commit 650c1029a0 (CUDA: Detect non-working user-specified architectures
                     on NVCC, 2020-05-28, v3.18.0-rc1~51^2)
* commit 01428c5560 (CUDA: Fail fast if CMAKE_CUDA_ARCHITECTURES
                     doesn't work during detection,
                     2020-08-29, v3.19.0-rc1~241^2).

Their goal was in part to avoid waiting until the test for working
compiler to detect unsupported architectures.  However, experience has
shown that failing earlier is more trouble than it's worth.

Fixes: #23161
Issue: #20756
2022-04-25 15:01:36 -04:00
Brad King b48e348b66 Merge topic 'FindICU-show-found-libs'
c3c7e6d609 FindICU: Show location of found libraries

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7193
2022-04-22 09:11:42 -04:00
Brad King bd8acc3a1b Merge topic 'clang-cl-asm-msvc-runtime'
b41fab9285 Clang: populate MSVC runtime library abstraction table

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7048
2022-04-22 09:01:35 -04:00
Brad King 1bd85e8f3f Merge topic 'NO_CMAKE_INSTALL_PREFIX'
42f7e39789 Find: Support per call disabling of CMAKE_INSTALL_PREFIX

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7163
2022-04-22 08:59:09 -04:00
Brad King 417de67afd Merge topic 'CheckCompilerFlags-revert-linker-warnings'
4941887d7d CheckCompilerFlags: Revert "Catch linker warning about ignored flags"
c2341ece47 CheckLinkerFlag: Catch linker warning when the checked flag is ignored

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7190
2022-04-22 08:55:57 -04:00
Brad King ddefed68e5 Merge topic 'CheckCompilerFlags-revert-linker-warnings' into release-3.23
4941887d7d CheckCompilerFlags: Revert "Catch linker warning about ignored flags"
c2341ece47 CheckLinkerFlag: Catch linker warning when the checked flag is ignored

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7190
2022-04-22 08:55:56 -04:00
Don Olmstead c3c7e6d609 FindICU: Show location of found libraries
Announce locations of the libraries without the use of `ICU_DEBUG`.
2022-04-21 12:54:02 -04:00
Brad King 0473d714de Merge topic 'FindPython-pypy-v7.3.9-support'
5440eafaae FindPython: Add support for pypy v7.3.9 and uppers

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7189
2022-04-21 11:50:28 -04:00
Brad King 4941887d7d CheckCompilerFlags: Revert "Catch linker warning about ignored flags"
Revert commit f745e0497e (CheckCompilerFlags: Catch linker warning about
ignored flags, 2022-01-03, v3.23.0-rc1~174^2).  It regressed cases where
incidental linker warnings were previously tolerated.  Revert the change
pending further investigation.

Fixes: #23432
Issue: #22961
2022-04-21 11:36:21 -04:00
Brad King c2341ece47 CheckLinkerFlag: Catch linker warning when the checked flag is ignored
Prior to commit 219dde4ea8 (CheckPIESupported: now uses any SYSROOT settings,
2022-01-16, v3.23.0-rc1~110^2), the checks for `-pie` and `-no_pie` on macOS
failed due to executing the compiler directly without any `-isysroot`,
producing `ld: library not found for -lc++`.  See issues #23053 and #19180.
The failing check for `-pie` was a bug because it is supported on macOS,
both for `x86_64` and `arm64`, and the commit fixed that check.

However, `-no_pie` is not supported on macOS `arm64`.  The above commit was
only able to detect that due to commit f745e0497e (CheckCompilerFlags: Catch
linker warning about ignored flags, 2022-01-03, v3.23.0-rc1~174^2), which we
need to revert due to issue #23432.  Instead, catch only the linker warning
about the exact flag being checked.
2022-04-21 11:35:30 -04:00
Marc Chevrier 5440eafaae FindPython: Add support for pypy v7.3.9 and uppers
Library name versioning has changed.

Fixes: #23439
2022-04-20 15:29:50 +02:00
Saleem Abdulrasool b41fab9285 Clang: populate MSVC runtime library abstraction table
!3211 overlooked populating the runtime library selection flags for
clang-cl in MSVC compatibility mode.  There is no flag that needs to be
passed, but the value is expected to be available by the generators.  We
simply provide the empty string to appease the generators without
emitting any additional flags.

Fixes: #23048
2022-04-17 21:13:44 -07:00
Robert Maynard 42f7e39789 Find: Support per call disabling of CMAKE_INSTALL_PREFIX
Fixes #23359
2022-04-15 09:33:55 -04:00
Brad King b760828d3f CPack/DMG: Do not use CPACK_RESOURCE_FILE_LICENSE for SLA by default
Since macOS 12.0 deprecated the tools needed to attach a SLA to a
`.dmg`, we should no longer do this by default.  Add a policy to
change the default to off.

Fixes: #22978
2022-04-14 10:14:58 -04:00
Brad King 3ca187ad3d Merge topic 'FindGit-no-easygit'
b656a3fa16 FindGit: remove EasyGit

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7169
2022-04-14 09:25:21 -04:00
Brad King 359d7c19e5 Merge topic 'FindwxWidgets-mingw'
6fac8af9ca FindwxWidgets: set wxWidgets_FIND_STYLE to unix on MINGW

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7162
2022-04-12 08:21:37 -04:00
Brad King 1b9630782a Merge topic 'FindGLUT-freeglut'
2c45465ffb FindGLUT: Search for freeglut as well using PkgConfig.
804ce3ee42 FindGLUT: Search for "freeglut" first On Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7161
2022-04-12 08:21:01 -04:00
Brad King bd59d50ecb Merge topic 'doc-CheckPIESupported'
91c859d1e5 CheckPIESupported: Prevent separate output lines running together
ab5455aa79 Help: Correct/add missing details for CheckPIESupported

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7157
2022-04-12 08:18:10 -04:00
Brad King 8fd65bef7d Merge topic 'doc-CheckPIESupported' into release-3.23
91c859d1e5 CheckPIESupported: Prevent separate output lines running together
ab5455aa79 Help: Correct/add missing details for CheckPIESupported

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7157
2022-04-12 08:18:09 -04:00
Brad King 7a1c6fd3e6 Merge topic 'FindPostgreSQL-14'
23671318f3 FindPostgreSQL: add support for PostgreSQL 14

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7158
2022-04-12 08:17:16 -04:00
Michael Hirsch b656a3fa16 FindGit: remove EasyGit
Blame shows EasyGit was part of initial FindGit 11 years ago.
I can hardly find Easy Git as a package. Given that Git is vital
for many complex CMake projects, it seems good to ensure CMake
FindGit is finding a Git program likely to work.

Crucial CMake modules like FetchContent also use FindGit, emphasizing
the importance of having a Git executable with proper functionality.
2022-04-11 14:08:01 -04:00
Craig Scott 91c859d1e5 CheckPIESupported: Prevent separate output lines running together 2022-04-11 09:06:37 -04:00
Craig Scott ab5455aa79 Help: Correct/add missing details for CheckPIESupported 2022-04-11 09:06:37 -04:00
Even Rouault 23671318f3 FindPostgreSQL: add support for PostgreSQL 14 2022-04-11 09:00:18 -04:00
Brad King c362d02e74 Merge topic 'check-flag-fembed-bitcode-conflict'
a10fc754a6 CheckSourceCompiles: Avoid linker warning with -fembed-bitcode

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7156
2022-04-11 08:50:58 -04:00