Commit Graph

1322 Commits

Author SHA1 Message Date
Craig Scott
949dcdb3bc Help: Clarify PRE_BUILD option for add_custom_command()
Fixes: #24889
2023-05-19 12:40:36 +10:00
Leonid Pospelov
c64f6d5a5a Help: Document append functionality of string(JSON) 2023-05-03 04:41:53 -04:00
Alex Neundorf
c584882b26 Help: change links to point to the env.vars, not to the cmake vars
The documentation of the find-commands was pointing to the
cmake variables CMAKE_PREFIX_PATH, CMAKE_INCLUDE_PATH etc.
also in the section for environment variables. Now they point
to the documentation for the respective environment variables.
2023-05-01 15:12:23 +02:00
Marc Chevrier
31675964e7 GenEx LIST: list operations
Fixes: #24550, #24547
2023-04-16 12:00:20 +02:00
Brad King
561ae21f40 Help: Clarify that {add,target}_compile_options are not used for linking
Link to alternatives that can be used for adding link options.

Issue: #24662
2023-03-31 11:30:51 -04:00
Brad King
f93b13151e Help: Link to COMPILE_LANGUAGE genex from add_compile_options
Follow-up commit e2830cf16b (Help: Link to COMPILE_LANGUAGE genex
from target_compile_options, 2023-03-28).

Issue: #24639
2023-03-31 11:01:13 -04:00
Brad King
e2830cf16b Help: Link to COMPILE_LANGUAGE genex from target_compile_options
Issue: #24639
2023-03-28 10:57:31 -04:00
Brad King
eb890ba3fc Merge topic 'file-GET_RUNTIME_DEPENDENCIES-windows-casing'
5922c86ed6 file(GET_RUNTIME_DEPENDENCIES): Document case-preserving change on Windows
7dffe99ad8 Tests: Restore CudaOnly.RuntimeControls cudart verification on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kyle Edwards <kyle.edwards@kitware.com>
Merge-request: !8367
2023-03-28 08:13:31 -04:00
Brad King
5922c86ed6 file(GET_RUNTIME_DEPENDENCIES): Document case-preserving change on Windows
In commit fa45594407 (file(GET_RUNTIME_DEPENDENCIES): Preserve casing
for Windows PE binaries, 2023-03-06) we neglected to update associated
documentation.
2023-03-27 09:49:51 -04:00
Brad King
512f64289a Help: Clarify that set(VAR) unsets VAR
Also call out possible exposure of an existing cache entry of the same
name, as we have for the `unset` command since commit 1a0f1a25a4 (Help:
Clarify the unset command, 2018-08-17, v3.13.0-rc1~199^2).

Issue: #24633
2023-03-24 14:44:45 -04:00
Matthew Woehlke
c8f65d2b67 Help: Improve file command signatures
Fix a couple of file command signatures that were not using angle
brackets to mark arguments.
2023-03-15 10:53:25 -04:00
Matthew Woehlke
68fb1572a8 Help: Convert signatures of file command
Convert `file` command to use new `signature` directive. Use '<HASH>'
rather than 'HASH' for relevant signature targets, as this is arguably
more correct, results in less need to specify explicit targets, but
still produces '#hash' as the HTML anchor.

Although actual textual changes to `file` are fairly minimal, large
portions of the content have been re-indented and in many cases,
re-flowed. Some tabular content in literal text blocks has also been
converted to actual tables.
2023-03-15 10:53:25 -04:00
Matthew Woehlke
a239a2a414 Help: Convert signatures of list and set commands
Convert documentation of the `list` and `set` commands to use new
`signature` directive. Use new `cref` role in the `list` introduction so
that the subcommands there are links rather than just text. Turn
references into `string` subcommands into actual links. Reformat some
prose as definition lists.
2023-03-15 10:53:25 -04:00
Brad King
3600be4e31 Help: Use signature directive for 'if' command 2023-03-07 13:38:39 -05:00
Brad King
bedd62d52c Help: Improve sentence structure around "if so" 2023-03-07 13:38:29 -05:00
Brad King
ae7c4a5ff4 Help: Add internal cross-references to 'if' command docs 2023-03-07 08:50:31 -05:00
Brad King
95bfacb8bb Help: Indent 'if' command docs more consistently 2023-03-07 08:50:31 -05:00
Brad King
3d6075da4d Merge topic 'improve-doc-signatures'
533ebb072b Help: Use signature directive for string command
cd33f461a6 Help: Use signature directive for cmake_language command
74e3c1d313 Utilities/Sphinx: Add a directive to document command signatures
c09b760484 Utilities/Sphinx: Drop commented-out code from cmake domain impl
6e85ad7f8b Help/dev: Add per-directive sections in CMake Documentation Guide

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8243
2023-03-07 08:49:30 -05:00
Matthew Woehlke
533ebb072b Help: Use signature directive for string command 2023-03-06 09:52:52 -05:00
Matthew Woehlke
cd33f461a6 Help: Use signature directive for cmake_language command 2023-03-06 09:52:12 -05:00
Brad King
1d7fb31778 Merge topic 'Apple-handle-Text-Stubs'
ede33f30cf Apple: Handle generation and comsuption of text-based stubs (.tbd files)
fcbd723a50 Enhance support functions

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Brad King <brad.king@kitware.com>
Merge-request: !8204
2023-03-02 09:53:03 -05:00
Brad King
5691e7e900 Merge topic 'try-doc'
b6cfbe7b17 Help:try_{compile,run}: clarify, encourage new syntax

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8262
2023-03-01 09:11:55 -05:00
Marc Chevrier
ede33f30cf Apple: Handle generation and comsuption of text-based stubs (.tbd files)
Fixes: #24123
2023-03-01 12:23:28 +01:00
scivision
b6cfbe7b17 Help:try_{compile,run}: clarify, encourage new syntax 2023-02-28 08:59:16 -05:00
scivision
9b56aabd99 Help:file: document HTTPHEADER more
Some servers have allow-lists for HTTP UserAgent for example.
CMake project devs would benefit from this hint about setting
authorization tokens and HTTP User Agent.
2023-02-24 12:32:41 -05:00
Brad King
df9c4b1872 find_package: Use <PACKAGENAME>_ROOT variables as search prefixes
Extend commit eb35d8884b (find_package: Use PackageName_ROOT variables
as search prefixes, 2018-03-15, v3.12.0-rc1~349^2) to also check
upper-case `<PACKAGENAME>_ROOT` variables.  Add policy `CMP0144` to
enable the behavior in a compatible way.

Fixes: #24403
2023-02-23 09:15:14 -05:00
Brad King
4da27a73bd Help: Document <PackageName>_ROOT variable ordering using an ordered list
Make room to add more steps in a documented order.
2023-02-23 09:12:29 -05:00
Brad King
d18806e673 Merge topic 'ninja-custom-command-depends'
ea2a05f402 Add variable CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8220
2023-02-20 08:34:34 -05:00
Abdelmaged Khalifa
ea2a05f402 Add variable CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY
Add CMake variable `CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY` to enable
option `DEPENDS_EXPLICIT_ONLY` on all uses of `add_custom_command`.

Fixes: #17097
2023-02-17 17:12:12 +02:00
Brad King
f7be10b26a Merge topic 'ci-linkcheck'
0787148785 gitlab-ci: Report sphinx logs as artifacts of its lint job
14506f49a2 Utilities/Sphinx: Configure linkcheck allowed permanent redirects
3c5b34af9d Help: Replace links with their permanent redirects
1004be159f FindCUDAToolkit: Replace broken links to NVIDIA documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8210
2023-02-17 08:54:51 -05:00
Brad King
3c5b34af9d Help: Replace links with their permanent redirects 2023-02-17 08:45:01 -05:00
scivision
6e71c31afd Help:add_test: emphasize important points
* enable_testing must be called to enable testing
* can only set properties on tests created in same directory
* WILL_FAIL still fails on segfault and similar
* compact wording
2023-02-15 16:23:35 -05:00
Brad King
e2ed34abf8 Merge topic 'ninja-custom-command-depends'
082ccd7530 add_custom_command: Add DEPENDS_EXPLICIT_ONLY option for Ninja

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8198
2023-02-15 08:57:32 -05:00
scivision
68a46505a3 Help: math: note that floating point inputs are invalid 2023-02-14 13:33:31 -05:00
Abdelmaged Khalifa
082ccd7530 add_custom_command: Add DEPENDS_EXPLICIT_ONLY option for Ninja
Add option `DEPENDS_EXPLICIT_ONLY` to `add_custom_command` to indicate
that implicit dependencies coming from users of the output are not
needed, and only consider dependencies explicitly specified in the
custom command.

Fixes: #17097
2023-02-14 08:56:59 -05:00
Brad King
df31400648 Merge topic 'doc-find_package-root-case'
20e727a408 Help: Clarify that <PackageName>_ROOT variable names are case-preserved

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8182
2023-02-09 10:01:52 -05:00
Brad King
20e727a408 Help: Clarify that <PackageName>_ROOT variable names are case-preserved
The name comes from the case-preserved first argument to
`find_package`.
2023-02-08 14:06:38 -05:00
Brad King
9492ca9a3f Merge topic 'KateImprovements'
e7f7bff4f5 Kate: improve the way the VCS-specific files are searched
96389b4cd3 Kate: add support for hg and fossil
4c32623f5f Help: fix typo in docs for set_property()
9a7612d2d0 Kate: make it possible to force a mode for the "files" entry
8a7aa2642b Help: add documentation for Kate-related variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8154
2023-02-07 09:48:23 -05:00
Alexander Neundorf
4c32623f5f Help: fix typo in docs for set_property() 2023-02-06 10:21:35 -05:00
scivision
1e95f765d5 Help: Clarify interaction of execute_process *_FILE and *_VARIABLE options
These parameters are so important that it's worthwhile to be more
explicit about their interaction.

Fixes: #24392
2023-02-06 09:47:52 -05:00
Brad King
abddcd370f Help: Clarify add_custom_command OUTPUT relative path behavior
Issue: #24372
2023-01-30 13:50:01 -05:00
Robert Maynard
c89d467bf2 Help: configure_file doc example use target_include_directories
Fixes #24351
2023-01-25 12:30:15 -05:00
Brad King
1d6d10cbf6 Merge topic 'isdir_empty'
a1dc38a567 Help: Document behavior of if(EXISTS,IS_DIRECTORY) for empty paths

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8109
2023-01-25 11:15:46 -05:00
scivision
a1dc38a567 Help: Document behavior of if(EXISTS,IS_DIRECTORY) for empty paths
Document and add explicit tests for empty string input:
`if(EXISTS "")` and `if(IS_DIRECTORY "")` are always false.
This avoids need for users to do extra checks due to
CMake non-short-circuit logic as below:

    if("${p}")
      if(EXISTS "${p}")
2023-01-24 14:13:52 -05:00
Robert Maynard
b787be2714 Help: Update supported languages in project and enable_language 2023-01-20 13:55:38 -05:00
Brad King
a78cba5197 message: Add CONFIGURE_LOG mode to record a message in the configure log
Provide a replacement for `file(APPEND .../CMake{Output,Error}.log)`
that records messages in the configure log.

Issue: #23200
2023-01-18 11:37:11 -05:00
Brad King
645671d36f Help: Document configure log behavior in try_compile and try_run 2023-01-18 11:37:02 -05:00
Brad King
d4bf7d80c6 try_compile: Add a NO_LOG option to skip recording in the configure log 2023-01-16 17:16:12 -05:00
Brad King
9d9e8450a8 try_compile: Add optional LOG_DESCRIPTION to record in configure log
Issue: #23200
2023-01-16 16:58:50 -05:00
Gustaf Borgström
b64a69b6c4 Help: Fix typo in configure_file docs 2023-01-11 16:32:35 -05:00