summaryrefslogtreecommitdiffstats
path: root/Modules
Commit message (Collapse)AuthorAgeFilesLines
* Merge topic 'fix-IS_NEWER_THAN-usage' into release-3.20Brad King2021-02-223-6/+26
|\ | | | | | | | | | | | | | | b0da671243 FetchContent: Don't update timestamps if files don't change 404cddb7bb ExternalProject: Fix misuse of IS_NEWER_THAN in timestamp checks Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5825
| * FetchContent: Don't update timestamps if files don't changeCraig Scott2021-02-221-4/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The refactoring in 17e5516e60 (FetchContent: Invoke steps directly and avoid a separate sub-build, 2021-01-29) uses a different way of writing out the step scripts and updating time stamps when steps are executed. That inadvertently always wrote out the scripts for custom commands, even when the contents didn't change. This caused their timestamp to always be updated, resulting in those steps always being seen as out-of-date and needing to be re-executed. The way timestamps were checked to determine whether to re-execute a step also did not adequately account for file systems which only have second-resolution timestamps. The IS_NEWER_THAN if condition also returns true when timestamps are the same, so one needs to use the negative form to get a true "is newer than" test. ExternalProject is not susceptible to this problem because it uses file(GENERATE) to write out the script files and that only updates the file's timestamp if the contents change. It also mostly leaves timestamp checking to the build tool.
| * ExternalProject: Fix misuse of IS_NEWER_THAN in timestamp checksCraig Scott2021-02-222-2/+4
| | | | | | | | | | | | | | When using a file system which only has second resolution timestamps, there is a reasonably high likelihood of timestamps being the same. The IS_NEWER_THAN test returns true when timestamps are the same, so don't redo downloads when they match exactly.
* | Merge topic 'intel-fortran-preprocess' into release-3.20Brad King2021-02-192-4/+20
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | c9244f369a IntelLLVM: Make explicit Fortran preprocessing under Ninja more robust 056d4bf528 Merge branch 'backport-intel-fortran-preprocess' af074c266e Intel: Make explicit Fortran preprocessing under Ninja more robust Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5826
| * | IntelLLVM: Make explicit Fortran preprocessing under Ninja more robustBrad King2021-02-181-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | Tell the Fortran compiler to write preprocessor output directly to a file, as we do for the GNU compiler. The previous "redirect stdout" approach could break during ABI detection with some `mpif90` wrappers that add version information to stdout when called with `-v`. Issue: #21828
| * | Merge branch 'backport-intel-fortran-preprocess'Brad King2021-02-181-2/+10
| |\ \
| | * | Intel: Make explicit Fortran preprocessing under Ninja more robustBrad King2021-02-181-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tell the Fortran compiler to write preprocessor output directly to a file, as we do for the GNU compiler. The previous "redirect stdout" approach could break during ABI detection with some `mpif90` wrappers that add version information to stdout when called with `-v`. Fixes: #21828
* | | | Merge topic 'fix-intel-compiler-check' into release-3.20Brad King2021-02-181-1/+1
|\ \ \ \ | |_|_|/ |/| | | | | | | | | | | | | | | | | | | dc7b6c2c06 DetermineCompiler: Fix copy-paste error in Intel Compiler detection Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5818
| * | | DetermineCompiler: Fix copy-paste error in Intel Compiler detectionGregor Jasny2021-02-171-1/+1
| |/ / | | | | | | | | | | | | Fixes: #21561 Fixes: a90d2a9eed (IntelLLVM: Add support for Intel LLVM-based compilers, 2020-11-02)
* | | FetchContent: Restore patch command supportCraig Scott2021-02-171-1/+1
|/ / | | | | | | | | | | The refactoring in 17e5516e60 (FetchContent: Invoke steps directly and avoid a separate sub-build, 2021-01-29) contained a typo which resulted in any PATCH_COMMAND being ignored. Fix the typo and add a test case that would have caught the regression.
* | Merge topic 'FindPython-fix-variable-handling' into release-3.20Brad King2021-02-161-2/+2
|\ \ | |/ | | | | | | | | | | 754f4f6876 FindPython: fix erroneous variable handling Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5816
| * FindPython: fix erroneous variable handlingMarc Chevrier2021-02-161-2/+2
| | | | | | | | Fixes: #21817
* | Merge topic 'FindPNG-advanced-variables' into release-3.20Brad King2021-02-161-2/+1
|\ \ | | | | | | | | | | | | | | | | | | 17ae4e1bef FindPNG: only mark used variables as advanced Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5809
| * | FindPNG: only mark used variables as advancedBen Boeckel2021-02-151-2/+1
| | | | | | | | | | | | | | | | | | The `PNG_LIBRARY` variable is an output and not a cache variable. Fixes some CMP0102 warnings.
* | | Merge topic 'IntelLLVM-unused-C17' into release-3.20Brad King2021-02-161-8/+3
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4642c81c72 IntelLLVM: Remove incomplete C17 support Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Merge-request: !5805
| * | | IntelLLVM: Remove incomplete C17 supportBrad King2021-02-151-8/+3
| |/ / | | | | | | | | | | | | CMake does not yet model support for C17. Avoid possible confusion by removing the settings for IntelLLVM pending a full implementation.
* | | Merge topic 'cuda-nvcc-output' into release-3.20Brad King2021-02-153-9/+12
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 9ea66b2d86 CUDA: Capture all nvcc output when extracting toolkit root Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Tested-by: Raul Tambre <raul@tambre.ee> Acked-by: Rong Ou <rong.ou@gmail.com> Merge-request: !5804
| * | | CUDA: Capture all nvcc output when extracting toolkit rootBrad King2021-02-123-9/+12
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | Since commit fb2afef620 (CUDA: Support nvcc symlinking to ccache, 2021-01-07) and commit 3cef91a321 (CUDA: Always extract CUDA Toolkit root from nvcc verbose output, 2021-02-03) we always run the command `nvcc -v __cmake_determine_cuda` to look for the toolkit root in its stderr. On Windows, that command may print to stdout instead, so capture that as well.
* | | Merge topic 'FindGDAL-improvements' into release-3.20Brad King2021-02-151-14/+45
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 55e493928b FindGDAL: add release note f4b53fadda FindGDAL: support finding additional GDAL library names 1b2774450d FindGDAL: add support for skipping gdal-config 1621cb3eb1 FindGDAL: add documentation to cache variables 3caaff4c08 FindGDAL: conditionally set the output variables 3f6a4f2062 FindGDAL: mark cache variables as advanced 02e906305d FindGDAL: use execute_process instead of exec_program 140344da14 FindGDAL: fix some indentation Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5799
| * | FindGDAL: support finding additional GDAL library namesBen Boeckel2021-02-121-1/+17
| | |
| * | FindGDAL: add support for skipping gdal-configBen Boeckel2021-02-111-1/+8
| | | | | | | | | | | | | | | | | | This can be confusing if there are autotools and CMake-built GDAL builds within the same environment as the autotools variant will always be preferred.
| * | FindGDAL: add documentation to cache variablesBen Boeckel2021-02-111-0/+3
| | |
| * | FindGDAL: conditionally set the output variablesBen Boeckel2021-02-111-8/+10
| | |
| * | FindGDAL: mark cache variables as advancedBen Boeckel2021-02-111-0/+3
| | |
| * | FindGDAL: use execute_process instead of exec_programBen Boeckel2021-02-111-1/+1
| | |
| * | FindGDAL: fix some indentationBen Boeckel2021-02-111-3/+3
| | |
* | | Merge topic 'FindMPI-lang-reason' into release-3.20Brad King2021-02-121-1/+3
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | 8251b62ba0 FindMPI: Fix reason for a non-enabled non-requested language Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5801
| * | | FindMPI: Fix reason for a non-enabled non-requested languageAxel Huebl2021-02-111-1/+3
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In pure C/CXX projects, when doing an optional search for C/CXX MPI APIs, I keep getting a reason appended of the form: ``` -- Could NOT find MPI_C (missing: MPI_C_LIB_NAMES MPI_C_HEADER_DIR MPI_C_WORKS) -- Could NOT find MPI_CXX (missing: MPI_CXX_LIB_NAMES MPI_CXX_HEADER_DIR MPI_CXX_WORKS) -- Could NOT find MPI (missing: MPI_C_FOUND MPI_CXX_FOUND) Reason given by package: MPI component 'Fortran' was requested, but language Fortran is not enabled. ``` The reason makes no sense since I did not request Fortran and thus confuses the reader. It is now only added if the component was truly requested.
* | | IAR: add support for the STM8 compilerFelipe Torrezan2021-02-126-2/+19
|/ /
* | Merge topic 'IntelLLVM-no-imsvc' into release-3.20Brad King2021-02-111-1/+0
|\ \ | | | | | | | | | | | | | | | | | | e5563e592f IntelLLVM: Remove unsupported -imsvc system include flag Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5795
| * | IntelLLVM: Remove unsupported -imsvc system include flagwilliam.r.dieter2021-02-101-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | `clang-cl` supports the `-imsvc` flag to tell the compiler an include directory is intended for system paths. `icx` does not accept this flag, even on MSVC platforms, so do not tell CMake that it exists. Fixes: #21801 Signed-off-by: william.r.dieter <william.r.dieter@intel.com>
* | | Merge topic 'FindBoost-no-warn'Brad King2021-02-101-1/+7
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | 90467747a1 FindBoost: Add option to suppress new boost version dependency warning Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5794
| * | | FindBoost: Add option to suppress new boost version dependency warningJohn Melas2021-02-101-1/+7
| |/ / | | | | | | | | | | | | | | | | | | Add option `Boost_NO_WARN_NEW_VERSIONS` to suppress new boost version dependency warning. Fixes: #21786
* | | Merge topic 'findcudatoolkit_handle_cuda_compiler_without_enabled_lang'Brad King2021-02-101-0/+1
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cd89d1c328 FindCUDAToolkit: Robust version checks when CUDA lang is not enabled Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Tested-by: Raul Tambre <raul@tambre.ee> Merge-request: !5787
| * | | FindCUDAToolkit: Robust version checks when CUDA lang is not enabledRobert Maynard2021-02-091-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Previously if you set `CMAKE_CUDA_COMPILER` but hadn't enabled the CUDA language, FindCUDAToolkit would not correctly compute the version information.
* | | | Merge topic 'clang-imsvc'Brad King2021-02-102-1/+1
|\ \ \ \ | |_|/ / |/| | / | | |/ | |/| | | | | | | | | | 2fc5e5dba9 Clang: Use -imsvc for system include only with MSVC-like front-end Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Thomas Bernard <thomas@famillebernardgouriou.fr> Merge-request: !5792
| * | Clang: Use -imsvc for system include only with MSVC-like front-endBrad King2021-02-092-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit bb61c2d024 (Clang: use -imsvc for system include dirs when running on Windows, 2020-09-16, v3.19.0-rc1~162^2) we added `-imsvc` for all Clang compilers targeting the MSVC ABI. However, the option only exists for the MSVC-like front-end. The GNU-like front-ends use `-isystem`. Fixes: #21789
| * | Merge topic 'FindXCTest-bundle-inject' into release-3.19Brad King2021-02-091-2/+9
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | eafe740ead FindXCTest: Fix output directory for test bundle with new build system Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5786
* | \ \ Merge topic 'FindXCTest-bundle-inject'Brad King2021-02-091-2/+9
|\ \ \ \ | | |/ / | |/| | | | | | | | | | | | | | | | | | eafe740ead FindXCTest: Fix output directory for test bundle with new build system Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5786
| * | | FindXCTest: Fix output directory for test bundle with new build systemYauheni Khnykin2021-02-081-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The output directory was still correct for macOS with the new build system, but not for iOS. Fixes: #20662
* | | | Merge topic 'xcode12-ios_install_combined'Brad King2021-02-091-13/+18
|\ \ \ \ | | |/ / | |/| | | | | | | | | | | | | | | | | | 0110aa018d IOS_INSTALL_COMBINED: Support Xcode 12 (command line only) Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5785
| * | | IOS_INSTALL_COMBINED: Support Xcode 12 (command line only)Craig Scott2021-02-081-13/+18
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Xcode 12 doesn't allow nested builds within the same build directory. That means we can no longer do an install by building the install target when IOS_INSTALL_COMBINED is true. We can, however, still do an install by running the cmake_install.cmake script or executing cmake --install, since there is no outer build and therefore the associated SDK can be built as a sub-build. The non-build methods previously didn't work when IOS_INSTALL_COMBINED was true because the generated install script and the CMakeIOSInstallCombined script both made certain assumptions that relied on being part of a build. Those assumptions are now removed. A side-effect of this work is that cpack now also works from the command line when IOS_INSTALL_COMBINED is true. Relates: #21282 Fixes: #20023
* | | Merge topic 'cuda_support_nvcc_from_hpctoolkit'Brad King2021-02-093-38/+32
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 3cef91a321 CUDA: Always extract CUDA Toolkit root from nvcc verbose output Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Tested-by: Raul Tambre <raul@tambre.ee> Merge-request: !5777
| * | | CUDA: Always extract CUDA Toolkit root from nvcc verbose outputRobert Maynard2021-02-083-38/+32
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #21750, #21763 Given that NVCC can be provided by multiple different sources (NVIDIA HPC SDK, CUDA Toolkit, distro) each of which has a different layout, we need to extract the CUDA toolkit root from the compiler itself, allowing us to support numerious different scattered toolkit layouts. The NVIDIA HPC SDK specifically ships two copies of nvcc one in `compilers/bin/` and one in `cuda/bin`. Thus when using `compilers/bin/nvcc` the Toolkit root logic fails.
* | | Merge topic '21479-branding-name-cpack-nsis'Brad King2021-02-091-0/+1
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | 0aabeb0c30 CPack/NSIS: Add option for setting branding text Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5784
| * | | CPack/NSIS: Add option for setting branding textJohnny Jazeix2021-02-071-0/+1
| |/ / | | | | | | | | | | | | | | | | | | See https://nsis.sourceforge.io/Reference/BrandingText for more information. Fixes: #21479
* | | AddFileDependencies: Deprecate this unnecessary moduleBrad King2021-02-081-1/+13
| | | | | | | | | | | | Document that one can call `set_property` directly instead.
* | | MacroAddFileDependencies: Explicitly deprecate by documentationBrad King2021-02-081-7/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | This module has been discouraged since commit 1e20be319f (STYLE: add documentation for MACRO_ADD_FILE_DEPENDENCIES(), 2009-07-14, v2.8.0~433). It has been listed in the `cmake-modules(7)` manual as deprecated since commit df780bcc01 (Help: Move deprecated modules to appropriate section., 2018-11-12, v3.14.0-rc1~374^2). Add the explicit deprecation mark in its documentation.
* | | MacroAddFileDependencies: Simplify implementationBrad King2021-02-081-8/+1
| | |
* | | Merge topic 'AddFileDependencies-simplify'Brad King2021-02-081-11/+4
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 0f6fc388ea AddFileDependencies: Avoid leaking temporary variable Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Ben Boeckel <ben.boeckel@kitware.com> Merge-request: !5779