summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
* Merge topic 'FindGTest-target-for-gmock'Brad King2021-11-221-1/+55
|\ | | | | | | | | | | | | 50bf457a0d FindGTest: Add target for gmock library Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6632
| * FindGTest: Add target for gmock libraryEero Aaltonen2021-11-221-1/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | `googlemock` has been absorbed into the [googletest](https://github.com/google/googletest) project and is built and installed from the same source tree. As GTest may be built with or without GMock, skip GMock if it is not present. Do not provide result variables for GMock. They are not provided by upstream GTest's CMake Package Configuration File. Also update the test case to cover linking to `GTest::gmock`.
* | Merge topic 'GNUInstallDirs-multiarch-prefixes'Brad King2021-11-221-3/+7
|\ \ | | | | | | | | | | | | | | | | | | dd9584b352 GNUInstallDirs: Apply Debian multiarch LIBDIR to more prefixes Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6748
| * | GNUInstallDirs: Apply Debian multiarch LIBDIR to more prefixesMathieu Malaterre2021-11-191-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On typical Debian amd64 system (bullseye), multiarch is setup as: ``` % cat /etc/ld.so.conf.d/x86_64-linux-gnu.conf /usr/local/lib/x86_64-linux-gnu /lib/x86_64-linux-gnu /usr/lib/x86_64-linux-gnu ``` Where: ``` % apt-cache policy libc6:amd64 libc6: Installed: 2.31-13+deb11u2 Candidate: 2.31-13+deb11u2 Version table: *** 2.31-13+deb11u2 500 500 http://deb.debian.org/debian bullseye/main amd64 Packages 100 /var/lib/dpkg/status ``` Update GNUInstallDirs to support all three cases `/`, `/usr/` and `/usr/local/`. Fixes: #19698
* | | Merge topic 'cudatoolkit_update_cusparse_deps'Brad King2021-11-221-0/+17
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | fedca357d2 FindCUDAToolkit: Correct cusparse dependencies for 10.1, 11.2.2 Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6745
| * | | FindCUDAToolkit: Correct cusparse dependencies for 10.1, 11.2.2Robert Maynard2021-11-191-0/+17
| | | |
* | | | Merge topic 'UseSWIG-create-workingdir'Brad King2021-11-221-1/+1
|\ \ \ \ | |_|_|/ |/| | | | | | | | | | | | | | | | | | | 7224eb5185 UseSWIG: ensure directory for depfile exists Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6750
| * | | UseSWIG: ensure directory for depfile existsMarc Chevrier2021-11-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When `Visual Studio` and `Xcode` generators are used, directory for depfile is not implicitely created by CMake when OUTFILE_DIR option is used. Fixes: #22932
| * | | Merge branch 'IntelLLVM-Fortran-frontend-variant' into release-3.21Brad King2021-11-111-0/+1
| |\ \ \ | | | | | | | | | | | | | | | Merge-request: !6718
* | \ \ \ Merge topic 'ghs_initial_setup'Brad King2021-11-192-33/+102
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | aa59eaac4f GHS: Allow setting GHS variables from toolchain file ab6f0b51b1 GHS: Add note about -T and path style a55b5c4e18 GHS: Update BSP selection logic 0427f22539 GHS: Update RTOS selection logic e006b87cc6 GHS: GHSMULTI - Update documentation to match implementation 83eb5695e9 GHS: Update toolset selection logic 8114ddcad1 GHS: Continue splitting variables used by generator 831607889f GHS: Update selection of primaryTarget in MULTI project file ... Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6715
| * | | | GHS: Allow setting GHS variables from toolchain fileFred Baksik2021-11-151-32/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Update generator to use the current variable definition, not the CACHE definition. * Avoid overwriting toolchain variables and avoid developer warnings when setting up the GHS variables. -- A cache entry is only required when: a) The toolchain uses set( CACHE ) to set the variable b) A -D or preset value was used to set the variable The cache entry is required so that the TYPE gets set properly. -- Avoid the Policy CMP0126 warnings: setting cache variable when normal variable exists * Move GHS_PRIMARY_TARGET back into area so non-GHS generator toolchain file can trigger the OS search.
| * | | | GHS: Update BSP selection logicFred Baksik2021-11-151-1/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Selection of a BSP only needs to be performed if not set by user. Remove all the logic for printing error and status messages about BSP selection. These messages also breaks CMake tests. NOTE: If BSP selection fails then the compiler checks will result in a build error. The build error will report that the BSP does not exist.
| * | | | GHS: Update RTOS selection logicFred Baksik2021-11-151-19/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Selection of an RTOS only needs to be performed if not set by user. Avoid CMake developer warnings for setting GHS_OS_DIR multiple times. Instead only set it once after searching has been performed. Remove all the logic for printing error and status messages about RTOS selection. This was broken and reporting incorrect messages. These messages also breaks CMake tests. NOTE: If RTOS selection fails then the compiler checks will result in a build error. The build error will report that the RTOS "GHS_OS_DIR-NOT-SPECIFIED" does not exist.
| * | | | GHS: Update toolset selection logicFred Baksik2021-11-151-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- Ensure that GHS_TOOLSET_ROOT is used as a path * Converts directory path slashes to CMake style -- Use ComparePath() to properly check for path changes of build tool * Accounts for Windows file-system case insensitivity. -- Don't print message "defaulting" messages (this causes CMake test failures) -- Don't force update CMAKE_GENERATOR_TOOLSET back into cache when `-T` is not used on initial configure. This change avoids an unnessary error message when accidentally using `-T` in subsequent runs but the same tools are always used. -- Use IssueMessage() for error messages.
| * | | | GHS: Continue splitting variables used by generatorFred Baksik2021-11-151-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | This makes it easier to use GHS-MULTI platform in other generators that want to use the GHS-MULTI platform and compilers.
| * | | | GHS: Update selection of primaryTarget in MULTI project fileFred Baksik2021-11-152-8/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes to ``-A`` handling: * Don't force CMAKE_GENERATOR_PLATFORM into cache when using default value (breaks using CMake presets). * Don't print message when using default value (breaks CMake tests). Changes to ``GHS_PRIMARY_TARGET`` handling: * Add as a cache variable so its known to GUI * Don't always include``GHS_TARGET_PLATFORM``, it's only needed if ``GHS_PRIMARY_TARGET`` wasn't set by the user. * Set ``GHS_PRIMARY_TARGET`` during platform selection instead of when a language is enabled. By performing this sooner ``GHS_TARGET_PLATFORM`` is not always required to be set into cache.
* | | | | Merge topic 'FindHDF5-Fortran-without-HL'Brad King2021-11-181-2/+0
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 86c697f49a FindHDF5: Fix Fortran compiler interrogation without HL library Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Ben Boeckel <ben.boeckel@kitware.com> Merge-request: !6739
| * | | | | FindHDF5: Fix Fortran compiler interrogation without HL libraryHÃ¥kon Strandenes2021-11-171-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the HDF5 HL library is not available, FindHDF5 with Fortran does not work. The problem is because `cmake_hdf5_test.f90` tries to "use h5lt" and "use h5ds", which comes from the HL library. Then the basic compiler check fails completely. The two "use" lines were added by commit 00405af0f1 (HDF5: Refactor the use of compiler wrappers, 2016-04-04, v3.6.0-rc1~85^2) along with the rest of the check. Remove them. Fixes: #22890
* | | | | | Merge topic 'gtest_discover_tests-PRE_TEST-dep'Brad King2021-11-171-1/+2
|\ \ \ \ \ \ | |/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1bf6d5979d gtest_discover_tests: Re-run PRE_TEST discovery on any arg change 715af43124 Tests: Fix and update wrongly named GoogleTest stdout file Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6728
| * | | | | gtest_discover_tests: Re-run PRE_TEST discovery on any arg changeCraig Scott2021-11-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: #22912
* | | | | | Merge topic 'clang_windows_thinlto'Brad King2021-11-161-1/+6
|\ \ \ \ \ \ | |_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 3155b23260 Clang/Windows: Use ThinLTO if possible to match other platforms Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6730
| * | | | | Clang/Windows: Use ThinLTO if possible to match other platformsRaul Tambre2021-11-141-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | Fixes #22905.
* | | | | | Merge topic 'doc-gtest_discover_tests-filter'Brad King2021-11-151-2/+5
|\ \ \ \ \ \ | |/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1ef54f3163 Help: Clarify meaning of filter expression in gtest_discover_tests() Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6727
| * | | | | Help: Clarify meaning of filter expression in gtest_discover_tests()Craig Scott2021-11-141-2/+5
| |/ / / /
| * | | | Merge topic 'IntelLLVM-Fortran-frontend-variant' into release-3.22Brad King2021-11-121-0/+1
| |\ \ \ \ | | | |/ / | | |/| | | | | | | | | | | | | | | | | | | | | | b1edd6e7c7 Fortran: Save frontend variant persistently for IntelLLVM Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6718
* | | | | Merge topic 'IntelLLVM-Fortran-frontend-variant'Brad King2021-11-121-0/+1
|\ \ \ \ \ | | |/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | b1edd6e7c7 Fortran: Save frontend variant persistently for IntelLLVM Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6718
| * | | | Fortran: Save frontend variant persistently for IntelLLVMWilliam R. Dieter2021-11-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit a90d2a9eed (IntelLLVM: Add support for Intel LLVM-based compilers, 2020-11-02, v3.20.0-rc1~89^2~20), our IntelLLVM compiler support populates `CMAKE_Fortran_COMPILER_FRONTEND_VARIANT`. However, the frontend variant was not stored in `CMakeCompilerFortran.cmake`. Signed-off-by: William R. Dieter <william.r.dieter@intel.com>
| * | | | Merge branch 'msvc-c++23' into release-3.20Brad King2021-10-121-0/+1
| |\ \ \ \ | | | | | | | | | | | | | | | | | | Merge-request: !6614
| * \ \ \ \ Merge branch 'revert-debian-libexec' into release-3.20Brad King2021-10-081-13/+2
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | Merge-request: !6607
* | \ \ \ \ \ Merge topic 'ti-armcl-unknown-arg-warning'Brad King2021-11-121-0/+1
|\ \ \ \ \ \ \ | | |_|_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 220f78e253 TI: Recognize invalid compiler option warning during try_compile() Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6705
| * | | | | | TI: Recognize invalid compiler option warning during try_compile()Craig Scott2021-11-111-0/+1
| | | | | | | | | | | | | | | | | | | | | Fixes: #22866
| * | | | | | Merge topic 'IntelLLVM-no-xilink' into release-3.22Brad King2021-11-111-1/+1
| |\ \ \ \ \ \ | | | |_|_|/ / | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 48f29b5805 IntelLLVM: Use MSVC linker with MSVC frontend variant Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6719
| * | | | | | Merge topic 'vs-framework-version' into release-3.22Brad King2021-11-082-0/+12
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | d51246c662 VS: Default TargetFrameworkVersion to v4.7.2 for VS 2022 f97f8537f3 VS: Model a default target framework e40cedddc0 cmVisualStudio10TargetGenerator: Refactor target framework selection 78782cc7dc cmGlobalVisualStudio8Generator: Refactor SetGeneratorPlatform Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6699
* | \ \ \ \ \ \ Merge topic 'FindVulkan-pre-1.2.175'Brad King2021-11-111-4/+9
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | db8bd5965f FindVulkan: Fix finding versions < 1.2.175 Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6717
| * | | | | | | | FindVulkan: Fix finding versions < 1.2.175Ralf Habacker2021-11-101-4/+9
| | | | | | | | |
* | | | | | | | | Merge topic 'FindThreads-libc-pthread-flag'Brad King2021-11-111-8/+11
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 68285bc8a9 FindThreads: Honor THREADS_PREFER_PTHREAD_FLAG when pthread is found in libc Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !6693
| * | | | | | | | | FindThreads: Honor THREADS_PREFER_PTHREAD_FLAG when pthread is found in libcMattias Ellert2021-11-101-8/+11
| | |_|_|_|_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `-pthread` flag tells the compiler/linker to link to additional libraries needed for thread support (e.g. libatomic on riscv64). The flag therefore should be used if requested using `THREADS_PREFER_PTHREAD_FLAG` also when the pthread functions are found in libc.
* | | | | | | | | Merge topic 'IntelLLVM-no-xilink'Brad King2021-11-111-1/+1
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | / / / / | | |_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | 48f29b5805 IntelLLVM: Use MSVC linker with MSVC frontend variant Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6719
| * | | | | | | IntelLLVM: Use MSVC linker with MSVC frontend variantWilliam R. Dieter2021-11-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Intel compiler (pre-LLVM) expected xilink.exe and had special logic to set xilink.exe. The newer LLVM-based compiler does not want xilink.exe. link.exe works better for host code, and is the default, so change the matching condition such that the old compiler matches (and gets xilink.exe) and the new compiler gets the default link.exe it expects. A better solution will be to use the compiler as the linker. A future change will switch to compiler as linker by default, but that fix needs more validation. Signed-off-by: William R. Dieter <william.r.dieter@intel.com>
* | | | | | | | Merge topic 'cuda_clang_cmp0105'Brad King2021-11-092-1/+5
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4707ecbe6f CUDA: Support CMP0105 on Clang 15fde4c420 CUDA: Use local shorthands for variables in Clang device link code cf7e68087d CUDA: Avoid unnecessary allocation and GetLinkLanguage() 5b0693411e CUDA: Ignore USE_WATCOM_QUOTE for device link rules Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6709
| * | | | | | | | CUDA: Support CMP0105 on ClangRaul Tambre2021-11-082-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add link flags during the "device compile" step. Enabled the relevant tests. The disable reasons regarding separable compilation were outdated and the actual failure case was device link flags support.
* | | | | | | | | Merge topic 'cpack-drop-osxx11'Brad King2021-11-083-4/+1
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4ef974e6cb CPack: Remove undocumented deprecated OSXX11 generator Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6704
| * | | | | | | | | CPack: Remove undocumented deprecated OSXX11 generatorBrad King2021-11-053-4/+1
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This CPack generator was never documented, and has been deprecated since commit 2ed00e8ef8 (CPack: Deprecate OSXX11 generator, 2020-01-31, v3.17.0-rc1~45^2). Issue: #20235
* | | | | | | | | Merge topic 'vs-framework-version'Brad King2021-11-082-0/+12
|\ \ \ \ \ \ \ \ \ | | |_|_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | d51246c662 VS: Default TargetFrameworkVersion to v4.7.2 for VS 2022 f97f8537f3 VS: Model a default target framework e40cedddc0 cmVisualStudio10TargetGenerator: Refactor target framework selection 78782cc7dc cmGlobalVisualStudio8Generator: Refactor SetGeneratorPlatform Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6699
| * | | | | | | | VS: Model a default target frameworkBrad King2021-11-062-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add fields to the VS generator to select a target framework. Migrate the existing default for VS 12 .NET CF for Windows CE. Report the values in `CMAKE_VS_*` variables and use them for the CSharp compiler id project too. Issue: #22849
* | | | | | | | | Merge topic 'doc-PKG_CONFIG_ARGN'Craig Scott2021-11-081-16/+33
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | / / / / | | |_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | 76c0281421 Help: Clarify how PKG_CONFIG env var initializes cache vars Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6706
| * | | | | | | Help: Clarify how PKG_CONFIG env var initializes cache varsCraig Scott2021-11-071-16/+33
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: #22870
* | | | | | | | Merge topic 'CheckLinkerFlag-policies'Brad King2021-11-051-0/+6
|\ \ \ \ \ \ \ \ | |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 58c8d649e1 CheckLinkerFlag: Set policies needed by the implementation Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6701
| * | | | | | | CheckLinkerFlag: Set policies needed by the implementationThomas Dickerson2021-11-041-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The module was added in CMake 3.18 by commit af96c0f4fa (CheckLinkerFlag: Add module to check validity of linker flags, 2020-05-16, v3.18.0-rc1~103^2), but it is still possible for projects to use it without setting policies to the 3.18 version level.
| * | | | | | | Merge topic 'FindHDF5-avoid-duplicate-library-entries' into release-3.22Brad King2021-11-041-0/+8
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 247f1149e1 FindHDF5: clear language-specific libraries list before discovery f56963cf05 FindHDF5: clear library output variables at the top of the module Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6698