Commit Graph

48243 Commits

Author SHA1 Message Date
Craig Scott
8dca6bd04b FetchContent: Preserve empty string arguments
Fixes: #20579
2020-05-23 23:42:43 +10:00
Craig Scott
cbf2daeed0 ExternalProject: Preserve empty string arguments 2020-05-23 23:41:53 +10:00
Brad King
62816ff88c Merge topic 'fortran-preprocess-property'
3888de23da Ninja: Skip Fortran preprocessing if Fortran_PREPROCESS is OFF
66c4e87282 Ninja: Add helper functions to generate Fortran build
5cca1ec893 Ninja: Add helper functions to generate Fortran preprocess rule
b0a6161190 Fortran: Add Fortran_PREPROCESS property

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4659
2020-05-22 10:35:10 -04:00
Craig Scott
1b0049680b Merge topic 'cmake_language-rename-from-cmake_command'
94c1e4fdb3 cmake_language: Rename command from cmake_command

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4774
2020-05-22 10:25:29 -04:00
Brad King
9c70475755 Merge topic 'autogen-fix-workerpool-locking'
01ad902588 Autogen: Redo locking and state machine for fence handling and the worker pool

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4775
2020-05-22 08:13:53 -04:00
Brad King
a7b3102e00 Merge topic 'support_conda_env'
50879ce412 Conda: Add CONDA_PREFIX as an acceptable system prefix path
cd9c3c000f Tests: Update QtAutogen codeeditor test only include headers needed
d806bd2e8c Tests: Update test suite to run in an Anaconda environment

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4773
2020-05-22 08:12:24 -04:00
Brad King
fa6db3738a Merge branch 'release-3.17' 2020-05-22 06:55:37 -04:00
Brad King
b54280beb7 Merge topic 'cuda-default-runtime'
d8eee80e30 Merge branch 'backport-cuda-default-runtime' into cuda-default-runtime
e55b21e24e CUDA: Compute CMAKE_CUDA_RUNTIME_LIBRARY default from toolchain
1086e930dc CUDA: Propagate CMAKE_CUDA_RUNTIME_LIBRARY state to try_compile
a4ea293153 Help: Correct CMAKE_CUDA_RUNTIME_LIBRARY applicability

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4762
2020-05-22 06:55:37 -04:00
Brad King
0781540a80 Merge topic 'cuda-default-runtime' into release-3.17
e55b21e24e CUDA: Compute CMAKE_CUDA_RUNTIME_LIBRARY default from toolchain
1086e930dc CUDA: Propagate CMAKE_CUDA_RUNTIME_LIBRARY state to try_compile
a4ea293153 Help: Correct CMAKE_CUDA_RUNTIME_LIBRARY applicability

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4762
2020-05-22 06:55:37 -04:00
Brad King
d8eee80e30 Merge branch 'backport-cuda-default-runtime' into cuda-default-runtime 2020-05-22 06:50:19 -04:00
Kitware Robot
23acffe5dd CMake Nightly Date Stamp 2020-05-22 00:01:13 -04:00
Joerg Sonnenberger
01ad902588 Autogen: Redo locking and state machine for fence handling and the worker pool
(1) All CV use must hold the corresponding mutex, otherwise race
conditions happen. This is mandated by the C++ standard.

(2) Introduce a separate CV for the thread waiting for other jobs to
finish before running a fence. This avoids waking up all other workers
blindly. Correctly wake that thread up when the processing of outstanding
jobs is done.

(3) Split the waiting for a fence to become runnable from a fence is
pending. This avoids problems if more than one fence can end up on the
queue. The thread that took a fence off the queue is responsible for
clearing the fence processing flag.
2020-05-21 16:17:36 -04:00
Brad King
94c1e4fdb3 cmake_language: Rename command from cmake_command
Also rename the `INVOKE` signature to `CALL`.

Fixes: #20732
2020-05-21 13:36:52 -04:00
Brad King
9ec09f22ff Merge topic 'multi-ninja-pch-msvc'
f6cb1e646c Multi-Ninja: Fix PCHs for Visual C++

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4771
2020-05-21 11:52:12 -04:00
Peter Hill
3888de23da Ninja: Skip Fortran preprocessing if Fortran_PREPROCESS is OFF
If `Fortran_PREPROCESS` is explicitly turned off for a source file then
we know it does not need to be preprocessed.  Teach the Ninja generator
to skip preprocessing in this case.  Otherwise we still must preprocess
just in case.

Fixes: #18870
2020-05-21 11:46:32 -04:00
Peter Hill
66c4e87282 Ninja: Add helper functions to generate Fortran build 2020-05-21 11:45:58 -04:00
Peter Hill
5cca1ec893 Ninja: Add helper functions to generate Fortran preprocess rule 2020-05-21 11:45:58 -04:00
Peter Hill
b0a6161190 Fortran: Add Fortran_PREPROCESS property
Issue: #18870
2020-05-21 11:44:14 -04:00
Brad King
3c5d52579b Merge topic 'cmake_command_invoke_expand_function_name'
aa55587094 cmake_command: Expand INVOKE function name argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4750
2020-05-21 11:38:32 -04:00
Brad King
8526a8cdef Merge branch 'release-3.17' 2020-05-21 11:36:09 -04:00
Brad King
d8b3160ce9 Merge topic 'FindPython-debug-library-lookup'
596db17cdd Merge branch 'backport-3.17-FindPython-debug-library-lookup' into FindPython-debug-library-lookup
e7b9f928f7 FindPython: use CMAKE specific variables to look-up debug library
71e6854b22 FindPython: use CMAKE specific variables to look-up debug library

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4764
2020-05-21 11:36:09 -04:00
Brad King
0c557a0cab Merge topic 'FindPython-debug-library-lookup' into release-3.17
71e6854b22 FindPython: use CMAKE specific variables to look-up debug library

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4764
2020-05-21 11:36:08 -04:00
Robert Maynard
50879ce412 Conda: Add CONDA_PREFIX as an acceptable system prefix path 2020-05-21 11:32:36 -04:00
Robert Maynard
cd9c3c000f Tests: Update QtAutogen codeeditor test only include headers needed 2020-05-21 11:32:01 -04:00
Robert Maynard
d806bd2e8c Tests: Update test suite to run in an Anaconda environment 2020-05-21 11:31:23 -04:00
Robert Maynard
e55b21e24e CUDA: Compute CMAKE_CUDA_RUNTIME_LIBRARY default from toolchain
Since commit 0d0145138f (CUDA: Add abstraction for cuda runtime
selection, 2019-11-29, v3.17.0-rc1~83^2) we add CUDA runtime library
selection flags by default.

To maintain backwards compatibility the default CUDA runtime
library needs to be computed based on what libraries are found
on the initial compiler invocation. For example a toolchain
could establish initial flags that have all CUDA compilations
using the runtime version, and if we don't detect this we will
try to link to both the static and shared runtime.

Co-Author: Brad King <brad.king@kitware.com>
Fixes: #20708
2020-05-21 11:15:03 -04:00
Kitware Robot
8351a349f7 CMake Nightly Date Stamp 2020-05-21 00:01:14 -04:00
Robert Maynard
1086e930dc CUDA: Propagate CMAKE_CUDA_RUNTIME_LIBRARY state to try_compile 2020-05-20 14:36:55 -04:00
Robert Maynard
a4ea293153 Help: Correct CMAKE_CUDA_RUNTIME_LIBRARY applicability 2020-05-20 14:36:55 -04:00
Brad King
345d707cf0 Merge topic 'cuda-test-nvcc-restore'
4c7cc264af Tests: Restore NVCC-specific CUDA tests

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4768
2020-05-20 10:54:05 -04:00
Brad King
4c7cc264af Tests: Restore NVCC-specific CUDA tests
In commit a653ca9504 (Tests: Update CUDA tests to work with Clang,
2020-03-27) some tests were conditioned using `CMAKE_CUDA_COMPILER_ID`.
That is not defined when configuring CMake itself, so it accidentally
turned off NVCC-specific CUDA tests altogether.  Convert the conditions
to check `CMake_TEST_CUDA` for `Clang` instead.  That option is added
explicitly to builds where we want the tests to run, so we can set it to
a value indicating the CUDA compiler vendor.

In commit a653ca9504 (Tests: Update CUDA tests to work with Clang,
2020-03-27) the NVCC-specific `CudaOnly.GPUDebugFlag` test was
accidentally broken by removing a space when appending `-G` to the CUDA
flags.  This was covered by the test not running.  Restore the space.

Fixes: #20727
2020-05-20 10:48:20 -04:00
Brad King
b2a0e8c8b2 Merge topic 'doc-find_package-xref'
bc735062df Help: Improve formatting and cross-references for find_package()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Brad King <brad.king@kitware.com>
Merge-request: !4772
2020-05-20 09:13:32 -04:00
Brad King
f60ca6b464 Merge topic 'ccmake-check-width'
3aede31cfc ccmake: Check that getmaxyx result width is non-negative

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4770
2020-05-20 09:12:22 -04:00
Brad King
00d6e41a07 Merge topic 'ctest-log-environment'
a1612af749 CTest: Log environment variables as a test measurement

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4760
2020-05-20 09:11:03 -04:00
Brad King
e4b095268b Merge topic 'update-kwsys'
ef215b0851 cmFileCommand: Log cmsys::Glob warnings
ef4d992b54 Merge branch 'upstream-KWSys' into update-kwsys
8fd4c19e1b KWSys 2020-05-18 (146f6b36)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4758
2020-05-20 09:07:50 -04:00
Brad King
bceca2fb47 Merge topic 'export-cmake-policy-version-range'
ca24b70d31 Export: Specify a policy range in exported files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4755
2020-05-20 09:06:17 -04:00
Brad King
1c73776e0b Merge branch 'release-3.16' 2020-05-20 09:04:09 -04:00
Brad King
1174efb6f9 Merge topic 'vs-sln-version' into release-3.17
88ad02f1ec VS: Restore .sln support for VS Version Selector

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4765
2020-05-20 09:03:23 -04:00
Brad King
66a7631d0a Merge branch 'release-3.17' 2020-05-20 09:03:23 -04:00
Brad King
4dfc7846f4 Merge topic 'vs-sln-version'
88ad02f1ec VS: Restore .sln support for VS Version Selector

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4765
2020-05-20 09:03:23 -04:00
Craig Scott
bc735062df Help: Improve formatting and cross-references for find_package() 2020-05-20 20:54:55 +10:00
Craig Scott
ddcc5a350c Merge topic 'doc-CMAKE_SYSTEM_PREFIX_PATH'
6b3d8f281e Document which environment variables effect CMAKE_SYSTEM_PREFIX_PATH

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4748
2020-05-20 06:28:11 -04:00
Cristian Adam
f6cb1e646c Multi-Ninja: Fix PCHs for Visual C++
Fixes: #20711
2020-05-20 11:20:38 +02:00
Kitware Robot
c8fdc54a3b CMake Nightly Date Stamp 2020-05-20 00:01:14 -04:00
Brad King
3aede31cfc ccmake: Check that getmaxyx result width is non-negative
Otherwise GCC 10.1 issues a `-Wstringop-overflow=` diagnostic when
we use the width for indexing.
2020-05-19 15:43:12 -04:00
Cristian Adam
aa55587094 cmake_command: Expand INVOKE function name argument
Fixes: #20707
2020-05-19 19:14:10 +02:00
Robert Maynard
6b3d8f281e Document which environment variables effect CMAKE_SYSTEM_PREFIX_PATH 2020-05-19 10:57:09 -04:00
Kyle Edwards
a1612af749 CTest: Log environment variables as a test measurement 2020-05-19 10:26:57 -04:00
Brad King
2f3a356ea8 Merge topic 'src-named-for-config'
70c85c1d6f Tests: Add case for source files named with CONFIG genex
3b547e2e4b VS: Simplify logic adding source file C/C++ language flag to MSVC
27ead9d4b7 VS: Compute managed type from an existing configuration
1222327c89 VS: Write custom commands for sources from all configurations
65fe58a4b4 cmVisualStudio10TargetGenerator: Adopt Windows Store and Phone infrastructure
3fa3b7a402 cmGeneratorTarget: Remove default config from Get* methods
d6a88d2158 cmTarget: Replace "perConfig" constructor boolean with enum

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4761
2020-05-19 09:56:48 -04:00
Brad King
e14894c4f7 Merge topic 'simplify_cmPropertyDefinitionMap'
6728f0fa85 cmPropertyDefinitionMap: simplify and shorten

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4753
2020-05-19 09:54:39 -04:00