Commit Graph

1585 Commits

Author SHA1 Message Date
Kyle Edwards
cf6ac2d365 Merge branch 'master' into cmakepresets-schema 2020-10-20 14:51:42 -04:00
Ben McMorran
0307f7c980 Help: Add JSON schema for CMakePresets.json 2020-10-20 12:07:09 -04:00
Kyle Edwards
54a5c026d0 Merge topic 'cmake-presets-doc-move'
4a123fc28c Help: Clarify purpose of warnings and errors
6c74bcfc20 Help: Make architecture and toolset descriptions generic
45766789a0 Help: Add inheritance to CMakePresets.json example
88c9d6f6eb Help: Add documentation for debug field
efab856008 Help: Show environment field
2208db114c Help: Show multiple ways of doing cacheVariables
d30f85193f Help: Move vendor field into example
b9c8c57860 Help: s/unusedVars/unusedCli/
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5373
2020-10-20 11:59:54 -04:00
Kyle Edwards
4a123fc28c Help: Clarify purpose of warnings and errors 2020-10-19 10:29:19 -04:00
Kyle Edwards
6c74bcfc20 Help: Make architecture and toolset descriptions generic 2020-10-19 10:29:19 -04:00
Kyle Edwards
45766789a0 Help: Add inheritance to CMakePresets.json example 2020-10-19 10:29:19 -04:00
Kyle Edwards
88c9d6f6eb Help: Add documentation for debug field
Oops!
2020-10-19 10:25:57 -04:00
Kyle Edwards
efab856008 Help: Show environment field 2020-10-19 10:25:57 -04:00
Kyle Edwards
2208db114c Help: Show multiple ways of doing cacheVariables
This demonstrates both the simple string and the complex object,
and ensures that they get automated testing.
2020-10-19 10:25:57 -04:00
Kyle Edwards
d30f85193f Help: Move vendor field into example
This ensures that the vendor field gets automated testing from the
example.
2020-10-19 10:25:57 -04:00
Kyle Edwards
b9c8c57860 Help: s/unusedVars/unusedCli/
This was a mistake in the documentation.

Fixes: #21303
2020-10-19 10:25:57 -04:00
Kyle Edwards
c436aaaad1 Help: Move CMakePresets.json documentation into a separate file 2020-10-19 10:25:57 -04:00
Brad King
860e40de6b Merge topic 'doc-CMP0111'
5c3a91c808 CMP0111: Clarify that the new error is on a missing property setting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Alex Reinking <alex_reinking@berkeley.edu>
Merge-request: !5385
2020-10-19 10:23:50 -04:00
Brad King
5c3a91c808 CMP0111: Clarify that the new error is on a missing property setting
The previous wording could be confused with the file missing on disk.
2020-10-16 08:26:00 -04:00
Brad King
9952ee063a server: remove deprecated 'cmake -E server' mode
The server mode has been deprecated since commit 996e1885c4 (server:
deprecate in favor of the file-api, 2019-04-19, v3.15.0-rc1~198^2).
Clients should now be using the file-api.  Remove the server mode.
2020-10-14 16:41:50 -04:00
Brad King
c555959717 Merge topic 'ninja-depfile-transformation'
146e1e6ba1 Ninja: Transform DEPFILEs with policy CMP0116
596439b1bb cmCustomCommandGenerator: Add option to transform depfile
b2c14bc774 cmake -E: Add cmake_transform_depfile internal command
946adadd40 cmGccDepfileReader: Rework helper code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5325
2020-10-14 11:49:51 -04:00
Kyle Edwards
e41009fe9e Merge topic 'cmake-help-fix'
7d811ceb3a Help: Fix invalid code-block in cmake(1) manual

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5369
2020-10-14 10:09:06 -04:00
Kyle Edwards
7d811ceb3a Help: Fix invalid code-block in cmake(1) manual
Fixes: #21304
2020-10-14 09:47:28 -04:00
Kyle Edwards
146e1e6ba1 Ninja: Transform DEPFILEs with policy CMP0116
Fixes: #21267
2020-10-13 10:19:46 -04:00
Kyle Edwards
a1988e4c80 Merge topic 'explicit-source-extensions'
fd50a75fa0 CMP0115: Require source file extensions to be explicit

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Ben Boeckel <ben.boeckel@kitware.com>
Merge-request: !5346
2020-10-13 10:17:14 -04:00
Kyle Edwards
fd50a75fa0 CMP0115: Require source file extensions to be explicit 2020-10-13 09:46:54 -04:00
Kyle Edwards
94c955e508 Tests: Test the CMakePresets.json example in the documentation 2020-10-09 15:35:54 -04:00
Kyle Edwards
d6af1e83bc Help: Fix documentation of CMakePresets.json's cacheVariables
cacheVariables is a map with variable names as the keys, but the
example in the documentation was not updated to reflect this. Fix
the example.
2020-10-09 11:41:47 -04:00
Kyle Edwards
0a638e86b2 Help: Add note about Visual Studio tools for Android 2020-10-07 10:24:38 -04:00
Kyle Edwards
55689ce800 Help: Add ref to Ninja Generators section 2020-10-07 10:23:31 -04:00
Kyle Edwards
a395cb516b CMakePresets.json: Prohibit empty variable names 2020-10-06 12:09:38 -04:00
Kyle Edwards
1d25760198 Help: Add presets documentation and release notes 2020-10-05 09:49:59 -04:00
Brad King
e8b0359a43 cmake_language: Add signature to DEFER calls to later times
Fixes: #19575
2020-09-29 17:12:33 -04:00
Brad King
0021d24fb3 Merge topic 'add_lang_agnostic_check_compile_flag_module'
90dead024c CheckCompilerFlag: unified way to check compiler flags per language

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5281
2020-09-29 05:45:07 -04:00
Robert Maynard
90dead024c CheckCompilerFlag: unified way to check compiler flags per language 2020-09-28 09:07:54 -04:00
Betsy McPhail
0aea38d25e Help: Change User Interaction image paths to be relative to source file 2020-09-25 14:45:01 -04:00
Robert Maynard
357e2ef429 CheckSoureRuns: Add a unified way to check if a source runs 2020-09-23 12:28:37 -04:00
Robert Maynard
10ae907de0 CheckSoureCompiles: Add a unified way to check if a source compiles 2020-09-23 12:28:37 -04:00
Brad King
2c896c381b Merge topic 'comp-ti-std-options'
6a66bb13ed Compiler/TI: Add std options for C++14
fe9cddf181 Compiler/TI: Add std options for C++98
55fc045aa8 Compiler/TI: Add std options for C11
2e69993101 Compiler/TI: Check default C standard
8300030f71 Compiler/TI: Check compiler version for C99 support
0b4582f229 Compiler/TI: Fix definition of std options
a70df0d6f0 Compiler/TI: Avoid generic variable name in macro

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5249
2020-09-22 07:48:24 -04:00
Josef Angstenberger
fe9cddf181 Compiler/TI: Add std options for C++98
The TI compiler does not support C++98, only C++03
(based on manual of current version).

This change sets the C++98 option to C++03 based on the fact that it
is done this way for the SunPro compiler already.
2020-09-21 00:57:20 +02:00
Brad King
2db623f554 Xcode: Add option to specify build system variant
Extend the `-T <toolset>` option to support a `buildsystem=` field with
the Xcode generator.  Add a `CMAKE_XCODE_BUILD_SYSTEM` variable to
inform project code about the selected build system variant.
2020-09-18 12:49:17 -04:00
Brad King
de9a2f1ef6 Help: Move CMAKE_XCODE_GENERATE_SCHEME to proper manual section 2020-09-14 13:14:38 -04:00
Brad King
b4fc4da903 ExternalProject: Add policy CMP0114 to refine step target dependencies
`ExternalProject_Add_StepTargets` and `INDEPENDENT_STEP_TARGETS` have
some limitations and lack some sanity checks.  They can cause confusing
build systems to be generated.  The basic problems are:

* The notion of step independence is attached to the step target
  rather than the step itself.

* The custom commands implementing the steps are duplicated in the
  step targets and the primary targets.  This can cause races.
  It is also incompatible with the Xcode "new build system".

Fix this by introducing policy CMP0114 to change the way step target
dependencies are handled.  Define independence from external
dependencies as a property of each individual step regardless of whether
there is a target for it.  Add dependencies among the primary target and
the step targets such that each custom command only appears in one
target.  When some steps are disconnected from the primary target, add
step targets for the steps commonly depended upon so that there is a
place to hold their custom commands uniquely.

Fixes: #18663
2020-09-14 10:48:16 -04:00
Brad King
48ed3bae58 Merge topic 'pch-instantiate-templates'
8c8f03422e PCH: Template instantiation support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Raul Tambre <raul@tambre.ee>
Acked-by: Cristian Adam <cristian.adam@gmail.com>
Tested-by: Raul Tambre <raul@tambre.ee>
Merge-request: !5168
2020-09-10 16:32:39 -04:00
Brad King
45fedf0e17 Makefile: Add policy CMP0113 to avoid duplication of custom commands
Do not attach a custom command to a target if it is already attached to one of
the target's dependencies.  The command's output will be available by the time
the target needs it because the dependency containing the command will have
already been built.

This may break existing projects that do not properly mark non-created
outputs with the `SYMBOLIC` property.  Previously a chain of two custom
commands whose intermediate dependency is not created would put both
commands in a dependent project's Makefile even if the first command is
also in its dependency's Makefile.  The first command would run twice
but the build would work.  Now the second command needs an explicit
`SYMBOLIC` mark on its input to tell CMake that it is not expected to
exist.  To maintain compatibility with projects that left out the mark,
add a policy activating the behavior.
2020-09-08 15:38:40 -04:00
Brad King
d0ccc7cf2a Merge topic 'ispc_improvements'
a020787a9b ISPC: Support generation for multiple instruction sets
5a1750017e ISPC: Add compiler launcher support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5173
2020-09-08 11:19:28 -04:00
Marc Chevrier
eb583b0a66 cmake_path command: path management
Fixes: #19568, #20922
2020-09-06 10:52:25 +02:00
Robert Maynard
a020787a9b ISPC: Support generation for multiple instruction sets 2020-09-04 08:37:07 -04:00
Tobias Hieta
8c8f03422e PCH: Template instantiation support
Adds PCH_INSTANTIATE_TEMPLATES target property for enabling template
instantiation in precompiled headers.
Enabled by default. Currently only supported for Clang 11 and newer.

Implements #21133.
2020-09-02 08:30:55 +02:00
Brad King
8f73ff0c37 Merge topic 'target_genex_dependency'
f14b390198 GenEx: Remove unneeded dependencies from target info queries

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Raul Tambre <raul@tambre.ee>
Merge-request: !5127
2020-09-01 09:59:08 -04:00
Craig Scott
3001e8b5d9 Merge topic 'xcode-link-phase-all'
525464ed2a Xcode: Use "Link Binary With Libraries" build phase in some cases
dc0898205c Xcode: Add special case for file type extension map for .xcassets
7b3d8411a2 Xcode: Refactor build setting append code and attribute getter naming

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5036
2020-09-01 09:38:05 -04:00
Robert Maynard
f14b390198 GenEx: Remove unneeded dependencies from target info queries
Only generate a graph dependency between a custom command and
a target when the custom command queries for the file path
of an artifact of the target.

This makes generator expressions such as `TARGET_FILE_DIR`
behave the same way as `TARGET_PROPERTY` which never generated
a graph dependency.
2020-09-01 09:25:19 -04:00
Brad King
f10682b796 Merge topic 'ispc_lang_support'
5ece12b7e4 gitlab-ci: add ISPC to the Fedora CI image
8976817d6d ISPC: Update help documentation to include ISPC
2368f46ba4 ISPC: Support building with the MSVC toolchain
e783bf8aa6 ISPC: Support ISPC header generation byproducts and parallel builds
34cc6acc81 Add ISPC compiler support to CMake
419d70d490 Refactor some swift only logic to be re-used by other languages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5065
2020-09-01 09:15:39 -04:00
Gusts Kaksis
525464ed2a Xcode: Use "Link Binary With Libraries" build phase in some cases
OBJECT and STATIC libraries (framework or non-framework) do not use
this build phase. Not all items to be linked use this build phase either.

Co-Authored-By: Craig Scott <craig.scott@crascit.com>
2020-09-01 07:38:48 +10:00
Robert Maynard
8976817d6d ISPC: Update help documentation to include ISPC 2020-08-28 11:21:31 -04:00