1
0
mirror of https://github.com/Kitware/CMake.git synced 2025-06-28 06:58:00 +08:00

599 Commits

Author SHA1 Message Date
Kyle Edwards
853c3eac6d Help: Note that CMAKE_CFG_INTDIR is not fully supported on Ninja Multi-Config 2020-02-25 14:00:43 -05:00
Brad King
5f04dfe57e Merge topic 'ninja-multi-variable-shuffle'
b966f86d86 Ninja Multi-Config: Shuffle variables around

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4305
2020-02-03 14:00:03 -05:00
Kyle Edwards
b966f86d86 Ninja Multi-Config: Shuffle variables around
Remove redundant variable CMAKE_NINJA_MULTI_CROSS_CONFIG_ENABLE.
Rename other variables. Document and improve handling of error
conditions.
2020-02-03 13:27:51 -05:00
Brad King
afcd9fe669 AIX: Add an option to disable automatic exports from shared libraries
Since commit 0f150b69d3 (AIX: Explicitly compute shared object exports
for both XL and GNU, 2019-07-11, v3.16.0-rc1~418^2~2) we always export
all symbols from shared libraries by default.  Add a new target property
called `AIX_EXPORT_ALL_SYMBOLS` that can be explicitly set to OFF to
suppress this behavior and export no symbols by default.

Fixes: #20290
2020-01-31 09:34:06 -05:00
Brad King
1f9321c683 Merge topic 'cuda_runtime_library_controls'
0d0145138f CUDA: Add abstraction for cuda runtime selection

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4178
2020-01-28 10:52:33 -05:00
Robert Maynard
0d0145138f CUDA: Add abstraction for cuda runtime selection
Fixes #17559
Replace our hard-coded default of cudart=static with a first-class abstraction to select the runtime library from an enumeration of logical names.
2020-01-27 16:02:26 -05:00
Brad King
072a95350c Merge topic 'ninja-multi-cross-configs'
b7a2baf38c Ninja Multi-Config: Add variable to control configs used in cross-config build

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4269
2020-01-24 15:02:20 -05:00
Brad King
786b56942b Merge topic 'vs-dotnet-standard-core'
ae1e1909a1 VS: Add support for .NET Standard and .NET Core

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4240
2020-01-24 10:55:26 -05:00
Joerg Bornemann
ae1e1909a1 VS: Add support for .NET Standard and .NET Core
Fixes: #20105
2020-01-24 09:11:05 -05:00
Kyle Edwards
b7a2baf38c Ninja Multi-Config: Add variable to control configs used in cross-config build 2020-01-23 15:47:12 -05:00
Kyle Edwards
8337ed0d73 Ninja Multi-Config: Add variable to control aliases in build.ninja 2020-01-22 10:26:21 -05:00
Brad King
15c573df41 Merge topic 'mark_as_advanced-without-cache'
3ec82b713e cmMarkAsAdvancedCommand: ignore variables which don't exist in the cache
701a5c60e0 cmake: avoid marking local or unused variables as advanced
af158149e7 FindOpenSSL: do not mark a local variable as advanced
74f659f1f2 FindCurses: only mark CURSES_EXTRA_LIBRARY when it is used
7e2ae4e96d FindOpenGL: only mark declared cache variables as advanced
7cc02a0c29 FindLua: only mark LUA_MATH_LIBRARY as advanced if required
85cd26b8a6 FindBoost: only mark Boost_DIR as advanced if defined
338c7916ba CTest: avoid marking undeclared cache variables as advanced
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4150
2020-01-22 09:50:49 -05:00
Ben Boeckel
3ec82b713e cmMarkAsAdvancedCommand: ignore variables which don't exist in the cache
Fixes: #18331
2020-01-20 15:49:29 -05:00
Brad King
cd6f6b2a9f Merge topic 'cmake-ctest-arguments'
4153d8445b Add CMAKE_CTEST_ARGUMENTS variable to pass command-line arguments to ctest

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4168
2020-01-17 09:40:23 -05:00
Brad King
796d66438b Merge topic 'rename-cross-config-variable'
310b58e961 Ninja Multi-Config: Rename variable to be more consistent

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4234
2020-01-17 09:39:32 -05:00
Kyle Edwards
310b58e961 Ninja Multi-Config: Rename variable to be more consistent
Also make some tweaks to the documentation.
2020-01-16 10:34:43 -05:00
Dan Johnston
97c124e30f Ninja: Add a separate job pool for PCH creation
Add a `JOB_POOL_PRECOMPILE_HEADER` target property to specify the pool
name, and its associated `CMAKE_JOB_POOL_PRECOMPILE_HEADER` variable.

Fixes: #20217
2020-01-16 10:32:25 -05:00
Robert Goulet
4153d8445b Add CMAKE_CTEST_ARGUMENTS variable to pass command-line arguments to ctest
Fixes: #20172
2020-01-15 15:02:56 -05:00
Brad King
4aa8397a4f Merge topic 'fix-global-autogen-target-help'
3104dc059c Help: Fix variable name on CMAKE_GLOBAL_AUTOGEN_TARGET page

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4212
2020-01-14 09:00:21 -05:00
Joerg Bornemann
3104dc059c Help: Fix variable name on CMAKE_GLOBAL_AUTOGEN_TARGET page
CMAKE_GLOBAL_AUTORCC_TARGET was mentioned accidentally.
2020-01-13 17:41:06 +01:00
Kyle Edwards
e8032e202e Ninja Multi-Config: Make cross-config building opt-in
Many users will want to use the Ninja Multi-Config generator like a
traditional Visual Studio-style multi-config generator, which doesn't
mix configurations - custom commands are built using target executables
of the same configuration the command is for. We do not want to force
these people to generate an N*N build matrix when they only need N*1,
especially if they have lots of targets. Add a new variable,
CMAKE_NINJA_CROSS_CONFIG_ENABLE, to opt-in to the cross-config build
matrix.
2020-01-10 16:31:29 -05:00
Cristian Adam
1a9f6bad98 ObjC: Add _COMPILE_LAUNCHER support
Fixes: #20178
2020-01-09 13:52:37 -05:00
Robert Maynard
f3c9396260 Help: Document CMAKE_FIND_DEBUG_MODE 2019-12-19 08:09:49 -05:00
Brad King
37a30f228a Merge topic 'fix-vs-winrt-by-default'
557ea4614e VS: Change CMAKE_VS_WINRT_BY_DEFAULT to not implicitly enable WinRT
7bcef355bf Vs: Add test for VS_WINRT_BY_DEFAULT

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4127
2019-12-17 11:11:24 -05:00
Petr Polezhaev
557ea4614e VS: Change CMAKE_VS_WINRT_BY_DEFAULT to not implicitly enable WinRT
Original behaviour would unconditionally enable WinRT for all projects
so source file flag generation code can acknowledge WinRT being present
and disable it for C language source files.  An unintentional result of
that approach is that WinRT is enabled for ALL projects, including C++
projects/source files with no way to disable it

Instead use `CMAKE_VS_WINRT_BY_DEFAULT` as a hint that the platform is
WinRT-by-default and set global `CompileAsWinRT` flag to `false` unless
it was explicitly requested by either `WINRT_COMPONENT` option or `/ZW`
compilation option - similar to what Windows Phone/Windows Store
platform logic does

In case WinRT compilation is enabled for a project by either of
aforementioned methods, C language source file override logic will still
kick in and disable CompileAsWinRT for C source files

Fixes: #20063
2019-12-16 13:46:59 -05:00
Kyle Edwards
8c062f9d99 Help: Add documentation and release notes for multi-config Ninja 2019-12-13 10:52:07 -05:00
Kyle Edwards
966a9eece3 Merge topic 'function-var-current'
24fdd51f45 Refactor: Replace CMAKE_CURRENT_LIST_DIR with CMAKE_CURRENT_FUNCTION_LIST_DIR
90e3e2a777 cmFunctionCommand: Introduce `CMAKE_CURRENT_FUNCTION*` variables
dd54290dab Refactor: Modernize `function` command

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !4000
2019-12-12 14:00:41 -05:00
Brad King
4fb9c88042 Merge topic 'add_cuda_meta_compiler_features'
2467a2b318 CUDA: Add cuda meta-features (e.g. ``cuda_std_11``) support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3992
2019-12-12 11:57:18 -05:00
Brad King
0e0571599f Merge topic 'ctest-drmemory-support'
676befdf52 ctest: add support for memcheck using Dr. Memory
2db0a65f56 cmCTestMemCheckHandler.cxx: minor refactoring

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4119
2019-12-12 11:54:54 -05:00
Kyle Edwards
106137492b Merge topic 'ctest-configuration-type'
e6f758be6d ctest: Populate CTEST_CONFIGURATION_TYPE from the -C command line when set

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4109
2019-12-11 11:00:13 -05:00
Robert Maynard
2467a2b318 CUDA: Add cuda meta-features (e.g. `cuda_std_11`) support 2019-12-10 17:56:48 -05:00
Dietmar Scheidl
676befdf52 ctest: add support for memcheck using Dr. Memory
Fixes: #19788
2019-12-10 14:42:30 -05:00
Alex Turbov
90e3e2a777 cmFunctionCommand: Introduce CMAKE_CURRENT_FUNCTION* variables
`CMAKE_CURRENT_FUNCTION`
  Can be used for diagnostic or debugging messages like the
  `__PRETTY_FUNCTION__` macro of GCC.

`CMAKE_CURRENT_FUNCTION_LIST_DIR`
  Eliminates the necessity of the additional "global"
  variables inside a module used to access additional "resource"
  files from functions defined in the module.

...
2019-12-10 16:43:27 +02:00
Julien Jomier
e6f758be6d ctest: Populate CTEST_CONFIGURATION_TYPE from the -C command line when set 2019-12-09 13:10:59 -05:00
Brad King
1da7fa3b47 Merge topic 'compiler-launcher-env'
6f48c59257 launcher: support setting a compiler launcher through the environment

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4095
2019-12-09 11:19:57 -05:00
Brad King
c4c74c7693 Merge topic 'doc-rpath'
fb4a39a900 Help: Clarify INSTALL_RPATH_USE_LINK_PATH documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4108
2019-12-06 08:38:20 -05:00
Ben Boeckel
6f48c59257 launcher: support setting a compiler launcher through the environment
This makes it much easier to use a launcher for all CMake projects in an
environment rather than having to remember to pass the setting to every
CMake build.
2019-12-05 14:25:36 -05:00
Hong Xu
fb4a39a900 Help: Clarify INSTALL_RPATH_USE_LINK_PATH documentation
State explicitly that directories containing linked library files
are also included even if they are not in the linker search path.
2019-12-05 12:45:45 -05:00
Hong Xu
e622832211 Help: Fix CMAKE_HOST_SYSTEM_PROCESSOR use of uname
Currently the document says that `CMAKE_HOST_SYSTEM_PROCESSOR` is the
output of `uname -p` if a system supports `uname`.  Update the
documented behavior to match `CMakeDetermineSystem.cmake` code.

Fixes: #20004
2019-12-04 14:59:37 -05:00
Gregor Jasny
92c4c852db Xcode: Add custom working directory property
Closes: #19967
2019-11-18 22:34:34 +01:00
Brad King
55f7df4961 Merge topic 'objc-standard-docs'
665954fa8d ObjC: Document ObjC/ObjCXX standard properties / variables

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4031
2019-11-12 09:47:44 -05:00
Cristian Adam
665954fa8d ObjC: Document ObjC/ObjCXX standard properties / variables
Fixes: #19919
2019-11-11 16:10:19 +01:00
Craig Scott
b613eecfa0 Merge topic 'docs-UNITY_BUILD'
fcacd8ce8d Help: Improve readability and fix inaccuracies in unity build docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4019
2019-11-10 15:55:43 -05:00
Craig Scott
fcacd8ce8d Help: Improve readability and fix inaccuracies in unity build docs 2019-11-09 19:48:34 +11:00
Brad King
2d83709038 Merge branch 'docs-INSTALL_REMOVE_ENVIRONMENT_PATH' into release-3.16
Merge-request: !3985
2019-11-05 11:30:56 -05:00
Brad King
20fdf9a92b Merge topic 'docs-INSTALL_REMOVE_ENVIRONMENT_PATH'
dd05ef429a Help: Fix inaccuracies in INSTALL_REMOVE_ENVIRONMENT_RPATH docs
ac8de0dbcf RPATH: Remove stray indent in generated file(RPATH_CHANGE) command

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3985
2019-11-05 11:21:25 -05:00
Craig Scott
abb0119350 Merge topic 'add_CMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY'
55df3954d3 find_package: Add support for CMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3968
2019-11-05 07:17:17 -05:00
Robert Maynard
55df3954d3 find_package: Add support for CMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY
Extend the change from commit 1d00ba9ccf (Find: find_package prefers
variable CMAKE_FIND_USE_REGISTRY, 2018-11-13, v3.16.0-rc1~461^2~1)
to cover the system package registry too.

Fixes: #19890
2019-11-04 10:31:16 -05:00
Craig Scott
dd05ef429a Help: Fix inaccuracies in INSTALL_REMOVE_ENVIRONMENT_RPATH docs
The previous docs assumed one had to set INSTALL_RPATH for
this target property to have an effect, but the actual condition is
only that the install rpath is different to the build rpath. Even if
the install rpath is empty, it is possible that CMake will rewrite
the rpath during install because the build rpath could be
non-empty.
2019-11-04 17:02:57 +11:00
Brad King
8db410f336 Merge topic 'docs-find-vars'
a0a7a45dbc Help: Fix markup errors, improve wording of CMAKE_FIND... variable docs
049dbdd38c Help: Document that <PackageName>_ROOT applies to config packages too

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3952
2019-10-29 10:33:16 -04:00