Commit Graph

8295 Commits

Author SHA1 Message Date
Martin Duffy
d88458b5ea instrumentation: Improve documentation for CMake Instrumentation 2025-02-10 16:57:45 -05:00
AJIOB
5a2c0407b8 Help: Clarify when execute_process ENCODING UTF-8 became the default
In commit e782811cfe (execute_process: Change default ENCODING to UTF-8,
2024-09-13, v3.31.0-rc1~94^2) we implied this by the version ranges in
the older defaults.  State it explicitly.
2025-02-10 16:18:16 -05:00
Brad King
6e337e469c Merge topic 'instrumentation-build-config'
9689155a05 instrumentation: Add Config value to snippet data
ee3a55fc48 cmMakefileGenerator: Update GetConfigName to return const reference

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10300
2025-02-10 08:25:01 -05:00
Brad King
640cf691fe Merge topic 'instrumentation-build-config' into release-4.0
9689155a05 instrumentation: Add Config value to snippet data
ee3a55fc48 cmMakefileGenerator: Update GetConfigName to return const reference

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10300
2025-02-10 08:24:59 -05:00
Craig Scott
5303ad3823
Presets: Only print presets variables for verbose log level or higher
Fixes: #26664
2025-02-10 22:56:55 +11:00
Brad King
c935c3ff54 Merge topic 'ci-linkcheck'
6f7341ed27 CPack/WIX: Replace documentation links with their permanent redirects

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10308
2025-02-09 12:32:06 -05:00
Martin Duffy
9689155a05 instrumentation: Add Config value to snippet data 2025-02-09 12:29:09 -05:00
Brad King
6f7341ed27 CPack/WIX: Replace documentation links with their permanent redirects 2025-02-08 09:39:02 -05:00
Brad King
d0d15940b0 Merge topic 'aix-id-var'
ff03db6657 AIX: Add platform id variables 'AIX' and 'CMAKE_HOST_AIX'

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10304
2025-02-08 09:29:46 -05:00
Aditya Vidyadhar Kamath
ff03db6657 AIX: Add platform id variables 'AIX' and 'CMAKE_HOST_AIX'
This allows projects to use `if(AIX)` blocks instead of spelling
out `if(CMAKE_SYSTEM_NAME STREQUAL "AIX")`.  We already have similar
variables for many other platforms.
2025-02-07 11:10:43 -05:00
Brad King
516546fd0e Merge topic 'instrumentation-make-hooks'
314440c320 instrumentation: Run preBuild and postBuild hooks before and after make
6598248da7 instrumentation: Avoid busy-wait on postBuild hook
f8339cb944 instrumentation: Enable tests on more Makefile generators
0fbb927bdd instrumentation: Disable preBuild and postBuild hooks on Windows
a13be1301f Tests/RunCMake/Instrumentation: Improve quoting and escaping in CMake code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10295
2025-02-07 08:32:06 -05:00
Brad King
e74ff65385 Merge topic 'instrumentation-make-hooks' into release-4.0
314440c320 instrumentation: Run preBuild and postBuild hooks before and after make
6598248da7 instrumentation: Avoid busy-wait on postBuild hook
f8339cb944 instrumentation: Enable tests on more Makefile generators
0fbb927bdd instrumentation: Disable preBuild and postBuild hooks on Windows
a13be1301f Tests/RunCMake/Instrumentation: Improve quoting and escaping in CMake code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10295
2025-02-07 08:32:04 -05:00
Martin Duffy
314440c320 instrumentation: Run preBuild and postBuild hooks before and after make
Updates the preBuild and postBuild instrumentation hooks to run before and
after make is invoked.
2025-02-06 09:49:09 -05:00
Martin Duffy
0fbb927bdd instrumentation: Disable preBuild and postBuild hooks on Windows
The implementation does not work on Windows.

Issue: #26668
2025-02-06 07:46:09 -05:00
Brad King
21f17656ac Help/dev: Update git command-line conventions in maintainer guide
Replace `git checkout` with `git switch` and `git restore`.
2025-02-05 13:09:50 -05:00
Brad King
208afbf6b8 Begin post-4.0 development 2025-02-05 11:49:36 -05:00
Brad King
410513d7cf Help: Drop development topic notes to prepare release
Release versions do not have the development topic section of
the CMake Release Notes index page.
2025-02-05 11:41:08 -05:00
Brad King
5fdd917f8a Help: Update Sphinx versionadded directives for 4.0 release
Run the script:

    Utilities/Sphinx/update_versions.py --since v3.31.0 --overwrite

Manually renumber `3.32` to `4.0` since the script is meant for
minor version increments.  Also filter out changes to documents
that were added for long-existing variables.
2025-02-05 09:17:06 -05:00
Brad King
fb69ed725e Help: Organize and revise 4.0 release notes
Add section headers similar to the 3.31release notes and move each
individual bullet into an appropriate section.  Revise a few bullets.
2025-02-05 09:15:16 -05:00
Brad King
1191647a0e Help: Consolidate 4.0 release notes
Run the `Utilities/Release/consolidate-relnotes.bash` script to move
notes from `Help/release/dev/*` into `Help/release/4.0.rst`.
2025-02-05 09:11:41 -05:00
Brad King
7065e7a555 Merge topic 'instrumentation-build-hooks'
2680f30caf instrumentation: Allow multiple CALLBACK arguments
fc1d55f6a5 instrumentation: Add preBuild and postBuild hooks for ninja
f62a4ab2ee instrumentation: Refactor cmInstrumentation constructor and usage
c57d1752d4 cmUVProcessChain: Add Detached option for spawning daemons

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10230
2025-02-05 09:08:33 -05:00
Brad King
0a17f39596 Merge topic 'cpack-archive-name'
7c825fd15f cpack: Respect CPACK_ARCHIVE_FILE_NAME for non-component packages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Alex Turbov <i.zaufi@gmail.com>
Merge-request: !10287
2025-02-05 09:06:47 -05:00
Martin Duffy
2680f30caf instrumentation: Allow multiple CALLBACK arguments
Don't require quotes around CALLBACK argument and allow it to be passed
multiple times.
2025-02-04 11:15:20 -05:00
Martin Duffy
fc1d55f6a5 instrumentation: Add preBuild and postBuild hooks for ninja
Allows instrumentation indexing and callbacks to occur at the start or end of
every `ninja` invocation.
2025-02-04 11:15:11 -05:00
Nikita Nemkin
7c825fd15f cpack: Respect CPACK_ARCHIVE_FILE_NAME for non-component packages
The variable CPACK_ARCHIVE_FILE_NAME (added in 9e06e97d30)
only works if per-component packaging is enabled. This isn't obvious
from the documentation.

Make it also work for non-component packages and adjust documentation.

Fixes: #8769
2025-02-04 20:36:10 +05:00
Brad King
8dfb1f40b7 Merge topic 'execute_process-cmd-bat'
74c9d40876 execute_process: Fix invocation of .cmd/.bat with spaces
104ca10208 cmWorkerPool: Adopt MaybePrependCmdExe calls to reduce duplication
cf7ba6d43d cmWorkerPool: Convert RunCommand signature to move semantics
c091fd1420 cmUVProcessChain: Convert AddCommand signature to move semantics
c1f6b04176 cmSystemTools: Teach MaybePrependCmdExe to always use backslashes
817b3967f8 cmSystemTools: Teach MaybePrependCmdExe to return GetShortPathNameW failure
611a3000f7 cmSystemTools: Make MaybePrependCmdExe case-insensitive
98fed0f116 cmSystemTools: Adopt MaybePrependCmdExe

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10270
2025-02-04 09:02:48 -05:00
Brad King
796db3a229 Merge topic 'ExternalData-add-httpheader'
5106f34eed ExternalData: Add option to specify HTTP headers

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10275
2025-02-04 08:59:42 -05:00
Brad King
76d874386a Merge topic 'fix-rst-code'
8d8fd9de2c Help: Fix typos in RST found by the `rst-backticks` hook

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10277
2025-02-03 13:21:56 -05:00
Jakob Ronestjärna
5106f34eed ExternalData: Add option to specify HTTP headers
Add a `ExternalData_HTTPHEADERS` variable to specify them.

Fixes: #26638
2025-02-03 11:30:59 -05:00
Brad King
0c5898558e Merge topic 'find-cps-components'
894f256a12 find_package: Find CPS components
ac20cd43c0 find_package: Fix reporting of transitive dependency errors

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10262
2025-02-03 10:07:25 -05:00
Brad King
74c9d40876 execute_process: Fix invocation of .cmd/.bat with spaces
The `CreateProcessW` documentation states "to run a batch file, you must
start the command interpreter".  Use `cmd /c the.bat` to run batch files.
Also, use a "short path" to the `.bat` file if needed to avoid spaces.

Previously this worked in some cases only due to undocumented behavior
of `CreateProcessW` when given a `.bat` file.

Fixes: #26655
2025-02-03 09:13:26 -05:00
Alex Turbov
8d8fd9de2c
Help: Fix typos in RST found by the rst-backticks hook 2025-02-02 18:56:26 +04:00
Brad King
d65f522a50 Merge topic 'FindRuby-compat-vars'
2d86cf314f FindRuby: Drop upper-case RUBY_ results in favor of Ruby_ variables

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10273
2025-02-02 07:03:10 -05:00
Brad King
4a11fd8dde Merge topic 'help-formatting'
d1d134534d Help: Add formatting to FindGettext and FindGnuplot
d138555959 Help: Use Title Case for all "Imported Targets" sections
bbbf3536c9 Help: Make sure all deprecated utility modules have a notice
969b039f40 Help: Reference correct variables in 3.6 release notes
9c963de998 Help: Remove stray spaces and one colon
51e4d81f16 Help: Remove accidental blockquotes around lists
718043b540 Help: Convert some literal blocks into tables and lists
914d580a4f Utilities/Sphinx: Ignore warning in generated texinfo documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10269
2025-02-01 07:19:04 -05:00
Brad King
2d86cf314f FindRuby: Drop upper-case RUBY_ results in favor of Ruby_ variables
Add policy CMP0185 for compatibility.

Fixes: #26640
2025-02-01 07:12:30 -05:00
Matthew Woehlke
894f256a12 find_package: Find CPS components
Implement finding components of CPS packages. Specifically, reject any
candidate packages that don't provide all required components, and
ignore appendices that don't provide requested (required or optional)
components. This applies to both top-level searches and also searching
for package dependencies.
2025-02-01 06:44:43 -05:00
Nikita Nemkin
bbbf3536c9 Help: Make sure all deprecated utility modules have a notice 2025-01-31 12:23:29 -05:00
Nikita Nemkin
969b039f40 Help: Reference correct variables in 3.6 release notes 2025-01-31 12:23:29 -05:00
Nikita Nemkin
9c963de998 Help: Remove stray spaces and one colon 2025-01-31 12:23:29 -05:00
Nikita Nemkin
51e4d81f16 Help: Remove accidental blockquotes around lists
Indenting a list relative to the previous paragraph creates
a blockquote. Combined with the natural list indent it results
in an overly large left margin.
2025-01-31 12:23:29 -05:00
Nikita Nemkin
718043b540 Help: Convert some literal blocks into tables and lists
Also, ensure that header-less tables have a top border in cmake.css.
2025-01-31 12:23:29 -05:00
Johnny Jazeix
09d5a4d7f0 CPack: add uncompressed TAR support
Fixes: #26646
2025-01-31 10:11:32 -05:00
Brad King
9d4be239b2 Help: Improve CPack Archive generator format list layout 2025-01-31 10:09:56 -05:00
Brad King
3e64c6a56e Merge topic 'msvc-runtime-checks'
2b2344b412 MSVC: Add abstraction for runtime checks
49dcd1ce5d Help: Fix MSVC_DEBUG_INFORMATION_FORMAT description of example
2f8e643d9d CMP0141: Fix documentation copied from CMP0091

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Alex <leha-bot@yandex.ru>
Merge-request: !10214
2025-01-30 08:48:01 -05:00
Brad King
0870e6c06b Merge topic 'enum_set-enhancements'
35dafcb5a1 cmext/enum_set: add various enhancements to increase usability
a3ae58c9c5 C++ features: add cm::is_scoped_enum from C++23

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10248
2025-01-30 08:44:35 -05:00
Brad King
a832d31474 Merge topic 'cmake_sarif_output'
abbe41578d cmake: Add SARIF diagnostics output support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: scivision <michael@scivision.dev>
Merge-request: !10139
2025-01-30 08:43:11 -05:00
Nikita Nemkin
9890cfc4ec Help: More syntax highlighting for literal blocks
Covers almost all blocks containing actual code, except:

* Parsed-literal blocks can't be highlighted, including many command
  summaries and substitution-heavy docs like find_... commands.
  This is a Sphinx limitation.

* Code with errors, like CMP0049, DEPLOYMENT_ADDITIONAL_FILES,
  DEPLOYMENT_REMOTE_DIRECTORY, @PACKAGE_INIT@ substitution in the
  tutorial, bracket arguments/comments in cmake-language.7 and
  cmake-developer.7.

* FindQt4 module, which needs reformatting.
2025-01-29 16:48:53 -05:00
AJIOB
2b2344b412 MSVC: Add abstraction for runtime checks
Replace our hard-coded default for `/RTC1` with a first-class
abstraction to select runtime checks from an enumeration of logical
names.  Add a `MSVC_RUNTIME_CHECKS` target property and corresponding
`CMAKE_MSVC_RUNTIME_CHECKS` variable.

Removing the old default flag requires a policy because existing
projects may rely on string processing to edit them and choose
runtime checks under the old behavior.  Add policy CMP0184 to
provide compatibility.

Fixes: #26614
2025-01-29 13:07:41 -05:00
Brad King
ec7cc80370 Merge topic 'patch-lower-case-style'
4e6a13f211 Use lower case style for commands

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: Alex Turbov <i.zaufi@gmail.com>
Merge-request: !10245
2025-01-29 11:37:51 -05:00
Brad King
e509c0a423 Merge topic 'patch-else'
9f2efc3270 Remove optional arguments from else() and end*() commands

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: Alex Turbov <i.zaufi@gmail.com>
Merge-request: !10243
2025-01-29 11:35:30 -05:00
Brad King
fbb69f867c Merge topic 'FindCURL-version-var'
d039da1c24 FindCURL: Add CURL_VERSION variable to match upstream cmake package

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10250
2025-01-29 11:32:39 -05:00
Daniel Tierney
abbe41578d cmake: Add SARIF diagnostics output support
Closes: #26587
2025-01-29 08:43:19 -05:00
Peter Kokot
4e6a13f211 Use lower case style for commands
Where possible this syncs the CS for command names:

- check_c_source_compiles()
- check_cxx_compiler_flag()
- check_cxx_source_compiles()
- check_cxx_symbol_exists()
- check_include_file_cxx()
- check_include_file()
- check_include_files()
- check_library_exists()
- check_source_compiles()
- check_struct_has_member()
- check_symbol_exists()
- check_type_size()
- cmake_dependent_option()
- cmake_parse_arguments()
- feature_summary()
- file()
- find_package_handle_standard_args()
- if(), endif...
- install(FILES)
- list()
- message()
- pkg_check_modules()
- select_library_configurations()
- set_package_info()
- test_big_endian()
2025-01-28 13:51:46 -05:00
Marc Chevrier
a3ae58c9c5 C++ features: add cm::is_scoped_enum from C++23 2025-01-28 17:52:36 +01:00
Brad King
d039da1c24 FindCURL: Add CURL_VERSION variable to match upstream cmake package
`find_package(CURL CONFIG)` provides `CURL_VERSION` from the upstream
cmake package version file.

Upstream curl commit `699ac9430c` (cmake: publish/check supported
protocols/features via `CURLConfig.cmake`, 2024-12-29) extends the
upstream cmake package to provide our old `CURL_VERSION_STRING`.
Provide both names from CMake's own module to aid transition.

Fixes: #26634
2025-01-28 09:52:22 -05:00
Peter Kokot
477737b7bf
load_cache: Add note about export()
The export() command can be a better option when outside project can be
adjusted in such way.
2025-01-28 15:22:29 +01:00
Brad King
aeff709a27 Merge topic 'patch-load-cache-script-mode'
18ae68a97c load_cache: Mention script mode support (-P)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10241
2025-01-28 09:19:58 -05:00
Brad King
d6a7a83700 Merge topic 'fix-typos-found-by-pygrep-hooks'
bc4c71627a Help: Fix typos found by the `rst-backticks` hook
c833629508 Help: Fix typos found by the `rst-directive-colons` hook

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10237
2025-01-28 08:35:19 -05:00
Brad King
0e0fc63bd8 Merge topic 'codespell'
d2752135cb codespell: Fix typos found by version 2.4

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10236
2025-01-28 08:25:51 -05:00
Peter Kokot
9f2efc3270
Remove optional arguments from else() and end*() commands
This adds a brief explanation of the optional condition in the `else()`
and removes all legacy usages of `else()` and `end*()` commands.
2025-01-28 03:01:23 +01:00
Peter Kokot
18ae68a97c
load_cache: Mention script mode support (-P)
When using the relevant load_cache(READ_WITH_PREFIX) signature, it also
works in script mode (cmake -P ...), unlike the 2nd obsolete signature.
2025-01-28 00:59:50 +01:00
Brad King
59113292b2 Merge topic 'install-parallel-doc-fix'
f1a80380ae Help: Improve language in INSTALL_PARALLEL doc

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10238
2025-01-27 11:21:49 -05:00
Brad King
3ffac3063d Merge topic 'doc-policy-deprecation-schedule'
3e0720a2ae Help: Add cmake_minimum_required(VERSION) example to cmake-policies(7)
085de39879 Help: Document policy transition schedule in cmake-policies(7)
60e302a539 Help: Drop policy scope from cmake-policies(7)
3b926b32e3 Help: Drop CMAKE_MINIMUM_REQUIRED_VERSION from cmake-policies(7)
ec9e5feb93 Help: Organize cmake-policies(7) by supported and unsupported policies
6be0fe22be Help: Mention CMAKE_POLICY_DEFAULT_CMP<NNNN> in cmake_minimum_required

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10222
2025-01-27 11:18:46 -05:00
Alex Turbov
d2752135cb codespell: Fix typos found by version 2.4 2025-01-27 10:55:58 -05:00
Brad King
3e0720a2ae Help: Add cmake_minimum_required(VERSION) example to cmake-policies(7) 2025-01-27 10:35:04 -05:00
Brad King
085de39879 Help: Document policy transition schedule in cmake-policies(7)
Rewrite the introduction of the manual to focus on policies' role in
evolution of CMake and how projects should be updated to account for
them over time.

Issue: #26613
2025-01-27 10:35:04 -05:00
Brad King
60e302a539 Help: Drop policy scope from cmake-policies(7)
The policy stack is covered by the `cmake_policy`, `include`, and
`find_package` command documentation.  Avoid distracting readers with
such details in the main policy introduction.
2025-01-27 10:35:04 -05:00
Brad King
3b926b32e3 Help: Drop CMAKE_MINIMUM_REQUIRED_VERSION from cmake-policies(7)
The variable has little role with respect to policies, particularly
since introduction of the `...<policy_max>` syntax.  Furthermore,
any role it may have is primarily in CMake's own modules.
2025-01-27 10:35:04 -05:00
Brad King
ec9e5feb93 Help: Organize cmake-policies(7) by supported and unsupported policies 2025-01-27 10:34:56 -05:00
Brad King
084f6055a8 Merge topic 'patch-CMAKE_OBJDUMP'
dc7aabf4d0 Help: Document CMAKE_OBJDUMP variable
4bd3519e89 CPack: Avoid mentioning internal CMake module in documentation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10224
2025-01-27 10:30:58 -05:00
Brad King
304f086b71 Merge topic 'doc-cmake_host_system_information-OS_NAME'
ff11a95962 Help: Clarify cmake_host_system_information OS_NAME

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Nicole Mazzuca <nicole.mazzuca@remarkable.no>
Acked-by: scivision <michael@scivision.dev>
Merge-request: !10232
2025-01-27 10:26:33 -05:00
Brad King
16f9016605 Merge topic 'help-json'
7be01178a0 Help: JSON argument should be quoted

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10231
2025-01-27 10:24:45 -05:00
Martin Duffy
f1a80380ae Help: Improve language in INSTALL_PARALLEL doc
Remove unneeded comma, clarify and link reference to Ninja generators, and substitute ``ON`` for enabled.
2025-01-27 09:41:59 -05:00
Alex Turbov
bc4c71627a
Help: Fix typos found by the rst-backticks hook
The corresponding `pre-commit` configuration is coming in the
separate MR.

Signed-off-by: Alex Turbov <i.zaufi@gmail.com>
2025-01-27 01:43:26 +04:00
Alex Turbov
c833629508
Help: Fix typos found by the rst-directive-colons hook
The corresponding `pre-commit` configuration is coming in the
separate MR.

Signed-off-by: Alex Turbov <i.zaufi@gmail.com>
2025-01-27 01:00:46 +04:00
Marc Chevrier
3d2709c1ae Linker configuration: rely now on CMAKE_<LANG>_LINK_MODE variable.
CMake now provides the CMAKE_<LANG>_LINK_MODE variable which specify how
the link step is done. So, the CMAKE_<LANG>_USING_LINKER_MODE variable
is no longer needed.
2025-01-26 14:45:21 +01:00
scivision
7be01178a0 Help: JSON argument should be quoted
The error that results from a semicolon anywhere in a JSON string
is not obvious.

Issue: #26628
2025-01-24 12:00:56 -05:00
AJIOB
49dcd1ce5d Help: Fix MSVC_DEBUG_INFORMATION_FORMAT description of example 2025-01-24 11:48:57 -05:00
AJIOB
2f8e643d9d CMP0141: Fix documentation copied from CMP0091 2025-01-24 11:48:56 -05:00
Brad King
ff11a95962 Help: Clarify cmake_host_system_information OS_NAME
Fixes: #26631
2025-01-24 10:58:35 -05:00
Peter Kokot
dc7aabf4d0 Help: Document CMAKE_OBJDUMP variable 2025-01-24 10:43:18 -05:00
Brad King
a2267f337a Merge topic 'doc-auto-export'
7a69f9037e Help: Document more WINDOWS_EXPORT_ALL_SYMBOLS limitations on data symbols

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10219
2025-01-24 10:24:36 -05:00
Brad King
5f6114f8b8 Merge topic 'patch-load-cache'
6fc8d20250 load_cache: Improve explanation of command signatures

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10216
2025-01-24 10:20:13 -05:00
Brad King
ac601c8a51 Merge topic 'clang-format-18'
0b96ae1f6a Revise C++ coding style using clang-format with "east const"
6ef947ea97 Empty commit at end of history preceding clang-format "east const" transition
08f1cae4e8 clang-format: Enforce "east const" qualifier placement
b2ba64add9 Revise C++ coding style using clang-format-18
c03bab9610 Empty commit at end of history preceding clang-format-18 style transition
e641442149 clang-format.bash: update to clang-format-18

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !10225
2025-01-24 09:53:52 -05:00
Kitware Robot
0b96ae1f6a Revise C++ coding style using clang-format with "east const"
Run the `clang-format.bash` script to update all our C and C++ code to a
new style defined by `.clang-format`, now with "east const" enforcement.
Use `clang-format` version 18.

* If you reached this commit for a line in `git blame`, re-run the blame
  operation starting at the parent of this commit to see older history
  for the content.

* See the parent commit for instructions to rebase a change across this
  style transition commit.

Issue: #26123
2025-01-23 13:09:50 -05:00
Brad King
e641442149 clang-format.bash: update to clang-format-18
The `.clang-format` configuration needs no changes to make the
version 18 format close to what version 15 produced before.

Issue: #26123
2025-01-23 11:42:52 -05:00
Brad King
cf44774fd0 Merge branch 'release-3.31' 2025-01-23 11:27:53 -05:00
Brad King
9fe70fd764 CMake 3.31.5 2025-01-23 10:53:36 -05:00
Brad King
e2a0790be5 Merge branch 'release-3.30' 2025-01-23 10:40:41 -05:00
Brad King
ba5aaa73ba Merge branch 'release-3.30' into release-3.31 2025-01-23 10:40:25 -05:00
Brad King
d437178a10 CMake 3.30.7 2025-01-23 09:59:38 -05:00
Brad King
6be0fe22be Help: Mention CMAKE_POLICY_DEFAULT_CMP<NNNN> in cmake_minimum_required
We already mention it in equivalent text for `cmake_policy`.
2025-01-23 09:41:08 -05:00
Brad King
1d4d4362d9 Merge topic 'remove-old-compatibility'
77f71ad4e2 Remove compatibility with CMake versions older than 3.5
fb1bd1d330 CMP0065: Remove support for OLD behavior
d9dd38cccf CMP0064: Remove support for OLD behavior
d88047c329 Remove compatibility with CMake versions older than 3.3
ac1a9cb160 CMP0063: Remove support for OLD behavior
36fffb673a CMP0062: Remove support for OLD behavior
789a7d73d4 CMP0061: Remove support for OLD behavior
3dc19e24cb CMP0060: Remove support for OLD behavior
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10210
2025-01-23 09:36:59 -05:00
Brad King
63924c4afa Merge topic 'ci-typos'
c3777c1536 ci: Extend spellcheck job with 'typos' tool
d11552c2d9 codespell: Exclude paths by patterns following pre-commit check conventions
11d0a631d4 codespell: Split multi-valued configuration across multiple lines
54dfadaf5a ci: Rename "codespell" job to more general name "spellcheck"
17fc94e5e3 ci: Add typos 1.29.4 to Fedora base image
ddf8220572 ci: Use Fedora 41 default flang package now that it is new enough
1e2d19ea4f gitignore: Tell tools honoring .gitignore to ignore .git too
0d0a94bcfb Tests: Fix Fortran syntax for initialized variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10211
2025-01-23 09:34:02 -05:00
Peter Kokot
6fc8d20250
load_cache: Improve explanation of command signatures
This extends the descriptions of command signatures and options.
Additional examples are listed at the bottom for better understanding
and overview of this command.
2025-01-22 23:40:39 +01:00
Brad King
7a69f9037e Help: Document more WINDOWS_EXPORT_ALL_SYMBOLS limitations on data symbols
Issue: #26604
2025-01-22 16:58:52 -05:00
Brad King
77f71ad4e2 Remove compatibility with CMake versions older than 3.5
This compatibility has been deprecated since commit 3a4791548d
(Deprecate compatibility with CMake versions older than 3.5, 2023-02-09,
v3.27.0-rc1~508^2).  The behavior itself has been deprecated
since CMake 3.5.

Issue: #26613
2025-01-22 10:40:55 -05:00
Brad King
fb1bd1d330 CMP0065: Remove support for OLD behavior 2025-01-22 10:40:55 -05:00
Brad King
d9dd38cccf CMP0064: Remove support for OLD behavior 2025-01-22 10:40:55 -05:00
Brad King
d88047c329 Remove compatibility with CMake versions older than 3.3
This compatibility has been deprecated since commit 3a4791548d
(Deprecate compatibility with CMake versions older than 3.5, 2023-02-09,
v3.27.0-rc1~508^2).  The behavior itself has been deprecated
since CMake 3.3.

Issue: #26613
2025-01-22 10:40:54 -05:00
Brad King
ac1a9cb160 CMP0063: Remove support for OLD behavior 2025-01-22 10:40:54 -05:00
Brad King
36fffb673a CMP0062: Remove support for OLD behavior 2025-01-22 10:40:54 -05:00
Brad King
789a7d73d4 CMP0061: Remove support for OLD behavior 2025-01-22 10:40:54 -05:00
Brad King
3dc19e24cb CMP0060: Remove support for OLD behavior 2025-01-22 10:40:54 -05:00
Brad King
1393fbf13f CMP0059: Remove support for OLD behavior 2025-01-22 10:40:54 -05:00
Brad King
8f9f01b24d CMP0058: Remove support for OLD behavior 2025-01-22 10:40:53 -05:00
Brad King
c283aafe62 CMP0057: Remove support for OLD behavior 2025-01-22 10:40:53 -05:00
Brad King
cf6114886a Merge topic 'CMAKE_LANG_DEVICE_LINK_MODE'
53de9d0125 Introduce CMAKE_<LANG>_DEVICE_LINK_MODE variable.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10209
2025-01-22 09:24:27 -05:00
Alex Turbov
c3777c1536 ci: Extend spellcheck job with 'typos' tool
Unlike the `codespell`, `typos` is capable of finding typos
in combined identifiers (`CamelCase` or `snake_case`).
2025-01-22 08:51:45 -05:00
Brad King
9204721eda Help: Clarify 'ctest --extra-submit'
Also fix its test to submit a valid file.

Fixes: #26611
2025-01-21 14:55:25 -05:00
Brad King
e7a90d0551 Help: Document CTEST_EXTRA_SUBMIT_FILES variable 2025-01-21 14:55:14 -05:00
Brad King
123e002168 Help: Document CTEST_NOTES_FILES variable 2025-01-21 14:52:14 -05:00
Brad King
2782d095b0 Remove compatibility with CMake versions older than 3.2
This compatibility has been deprecated since commit 3a4791548d
(Deprecate compatibility with CMake versions older than 3.5, 2023-02-09,
v3.27.0-rc1~508^2).  The behavior itself has been deprecated
since CMake 3.2.

Issue: #26613
2025-01-21 09:44:05 -05:00
Brad King
cbe7fc4b81 CMP0056: Remove support for OLD behavior 2025-01-21 09:44:05 -05:00
Brad King
cfcb36ca34 CMP0055: Remove support for OLD behavior 2025-01-21 09:44:05 -05:00
Brad King
7a39d926e8 Merge topic 'remove-old-compatibility'
381c446ff7 VS: Remove support for appending a platform to the generator name
dc24d88062 Remove compatibility with CMake versions older than 3.1
90d814f024 CMP0054: Remove support for OLD behavior
292aaffb78 Source: Remove unused cmCommandArgument{Lexer,Parser}
1150fae89a CMP0053: Remove support for OLD behavior
f0b1ca4d70 CMP0052: Remove support for OLD behavior
e4fddc8e37 CMP0051: Remove support for OLD behavior

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10205
2025-01-21 09:43:10 -05:00
Brad King
2902d3f827 Merge topic 'patch-file-make-directory'
2e02e5589d file(MAKE_DIRECTORY): Document current source directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: scivision <michael@scivision.dev>
Merge-request: !10203
2025-01-21 09:32:46 -05:00
Brad King
a91a01747d Merge topic 'patch-installation-components'
5a974b99fe install: Document where the components are used

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10202
2025-01-21 09:31:05 -05:00
Brad King
d15845d27a Merge topic 'doc/configure_log_api'
4699554c62 Help: Document when file-api configureLog was added

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10204
2025-01-21 09:28:40 -05:00
Marc Chevrier
53de9d0125 Introduce CMAKE_<LANG>_DEVICE_LINK_MODE variable.
This is a complement to commit 00932ea864 (Introduce CMAKE_<LANG>_LINK_MODE variable., 2025-01-09)
2025-01-21 15:17:05 +01:00
Brad King
381c446ff7 VS: Remove support for appending a platform to the generator name
Compatibility with CMake versions prior to 3.1 is no longer supported.

Fixes: #26481
2025-01-21 08:08:22 -05:00
Cristian Le
4699554c62 Help: Document when file-api configureLog was added
Issue: #23200
Signed-off-by: Cristian Le <git@lecris.dev>
2025-01-20 11:21:54 -05:00
Brad King
dc24d88062 Remove compatibility with CMake versions older than 3.1
This compatibility has been deprecated since commit 3a4791548d
(Deprecate compatibility with CMake versions older than 3.5, 2023-02-09,
v3.27.0-rc1~508^2).  The behavior itself has been deprecated
since CMake 3.1.

Issue: #26613
2025-01-20 09:46:55 -05:00
Brad King
90d814f024 CMP0054: Remove support for OLD behavior 2025-01-20 09:46:55 -05:00
Brad King
1150fae89a CMP0053: Remove support for OLD behavior 2025-01-20 09:46:55 -05:00
Brad King
f0b1ca4d70 CMP0052: Remove support for OLD behavior 2025-01-20 09:46:54 -05:00
Brad King
e4fddc8e37 CMP0051: Remove support for OLD behavior 2025-01-20 09:46:54 -05:00
Peter Kokot
2e02e5589d
file(MAKE_DIRECTORY): Document current source directory
Relative paths in the directories list argument are treated as relative
to the current source directory.
2025-01-20 14:59:38 +01:00
Peter Kokot
5a974b99fe
install: Document where the components are used 2025-01-20 12:02:23 +01:00
Brad King
8e0a0291ef Remove compatibility with CMake versions older than 3.0
This compatibility has been deprecated since commit 3a4791548d
(Deprecate compatibility with CMake versions older than 3.5, 2023-02-09,
v3.27.0-rc1~508^2).  The behavior itself has been deprecated
since CMake 3.0.

Issue: #26613
2025-01-19 09:41:04 -05:00
Brad King
6973f8304e CMP0050: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
9f6011e307 CMP0049: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
292048874f CMP0048: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
05b2c563bb CMP0047: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
d9498a474e CMP0046: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
1e8a744f07 CMP0045: Remove support for OLD behavior 2025-01-19 09:41:03 -05:00
Brad King
9094eaa778 CMP0044: Remove support for OLD behavior 2025-01-19 09:41:02 -05:00
Brad King
ed99370f63 CMP0043: Remove support for OLD behavior
Note that per-source `COMPILE_DEFINITIONS_<CONFIG>` are not covered by
the policy, and are still supported.
2025-01-19 09:41:02 -05:00
Brad King
1bb0066b0c Help: Clarify deprecation of source-file property COMPILE_DEFINITIONS_<CONFIG>
It is not covered by policy `CMP0043`.  Also fix its link
to the `COMPILE_DEFINITIONS` source file property.
2025-01-19 09:41:02 -05:00
Brad King
9b148ed1ac CMP0042: Remove support for OLD behavior 2025-01-19 09:41:02 -05:00
Brad King
7193c2d23d CMP0041: Remove support for OLD behavior 2025-01-19 09:41:02 -05:00
Brad King
cddac8736d CMP0040: Remove support for OLD behavior 2025-01-19 09:41:02 -05:00
Brad King
0b6412b514 CMP0039: Remove support for OLD behavior 2025-01-19 09:41:01 -05:00
Brad King
af28f030d8 CMP0038: Remove support for OLD behavior 2025-01-19 09:41:01 -05:00
Brad King
84f737545f CMP0037: Remove support for OLD behavior 2025-01-19 09:41:01 -05:00
Brad King
850174c507 CMP0036: Remove support for OLD build_name command 2025-01-19 09:41:01 -05:00
Brad King
5b255fe7da CMP0035: Remove support for OLD variable_requires command 2025-01-19 09:41:01 -05:00
Brad King
84c3943873 CMP0034: Remove support for OLD utility_source command 2025-01-19 09:41:01 -05:00
Brad King
76702e36e3 CMP0033: Remove support for OLD export_library_dependencies command 2025-01-19 09:41:00 -05:00
Brad King
ff6d55f8c5 CMP0032: Remove support for OLD output_required_files command 2025-01-19 09:41:00 -05:00
Brad King
dc0c6734d3 CMP0031: Remove support for OLD load_command command 2025-01-19 09:41:00 -05:00
Brad King
6bdf4efbb3 CMP0030: Remove support for OLD use_mangled_mesa command 2025-01-19 09:41:00 -05:00
Brad King
683a02f5a0 CMP0029: Remove support for OLD subdir_depends command 2025-01-19 09:41:00 -05:00
Brad King
59ba0948a3 Help: Add boilerplate text for removed policies of disallowed commands 2025-01-19 09:40:59 -05:00
Brad King
84b7c9f5dd CMP0028: Remove support for OLD behavior 2025-01-19 09:40:59 -05:00
Brad King
5754c9f731 CMP0027: Remove support for OLD behavior 2025-01-19 09:40:59 -05:00
Brad King
f8bc8780c1 CMP0026: Remove support for OLD behavior 2025-01-19 09:40:59 -05:00
Brad King
796cf2d8eb CMP0025: Remove support for OLD behavior 2025-01-19 09:40:59 -05:00
Brad King
65b45de1dd CMP0024: Remove support for OLD behavior 2025-01-19 09:40:59 -05:00
Brad King
3c4afba8cc Remove compatibility with CMake versions older than 2.8.12
This compatibility has been deprecated since commit 5845c218d7
(Deprecate compatibility with CMake versions older than 2.8.12,
2020-06-12, v3.19.0-rc1~629^2).  The behavior itself has been
deprecated since CMake 2.8.12.

Issue: #26613
2025-01-18 09:51:45 -05:00
Brad King
0453f70400 CMP0023: Remove support for OLD behavior 2025-01-18 09:51:45 -05:00
Brad King
888259c894 CMP0022: Remove support for OLD behavior 2025-01-18 09:51:45 -05:00
Brad King
e31d1c7600 CMP0021: Remove support for OLD behavior 2025-01-18 09:51:44 -05:00
Brad King
094b42b643 CMP0020: Remove support for OLD behavior 2025-01-18 09:51:44 -05:00
Brad King
092d6de4be CMP0019: Remove support for OLD behavior 2025-01-18 09:51:44 -05:00
Brad King
41a7a0119f CMP0018: Remove support for OLD behavior 2025-01-18 09:51:44 -05:00
Brad King
d74210a8bd CMP0017: Remove support for OLD behavior 2025-01-18 09:51:44 -05:00
Brad King
ae13e27225 CMP0016: Remove support for OLD behavior 2025-01-18 09:51:43 -05:00
Brad King
a43470b9ba CMP0015: Remove support for OLD behavior 2025-01-18 09:51:43 -05:00
Brad King
8ef1b4001b Merge topic 'remove-old-compatibility'
785523a136 Remove compatibility with CMake versions older than 2.8.0
35282387ea CMP0014: Remove support for OLD behavior
fad9c55b8b CMP0013: Remove support for OLD behavior
98a59ba8ad CMP0012: Remove support for OLD behavior
3c0dbb66f5 CMP0011: Remove support for OLD behavior
cf832e75bc CMP0010: Remove support for OLD behavior
77f8c374f3 CMP0009: Remove support for OLD behavior
43ef139567 CMP0008: Remove support for OLD behavior
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !10188
2025-01-18 09:50:27 -05:00
Brad King
c2838829f2 Merge topic 'instrumentation-target-labels'
9d34069ca8 instrumentation: Add targetLabels field to link snippets
32444714e5 instrumentation: Update tests so that snippet verification runs
11bcf2efb8 instrumentation: Correct example v1 Data snippet in manual

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: Roscoe A. Bartlett <rabartl@sandia.gov>
Merge-request: !10185
2025-01-18 09:46:29 -05:00
Martin Duffy
9d34069ca8 instrumentation: Add targetLabels field to link snippets
Adds a new data field `targetLabels` to link snippets which contains a list of
text labels from the LABELS target property.
2025-01-17 11:07:30 -05:00
Martin Duffy
11bcf2efb8 instrumentation: Correct example v1 Data snippet in manual 2025-01-17 10:29:02 -05:00
Brad King
785523a136 Remove compatibility with CMake versions older than 2.8.0
This compatibility has been deprecated since commit 5845c218d7
(Deprecate compatibility with CMake versions older than 2.8.12,
2020-06-12, v3.19.0-rc1~629^2).  The behavior itself has been
deprecated since CMake 2.8.0.

Issue: #26613
2025-01-17 09:36:10 -05:00
Brad King
35282387ea CMP0014: Remove support for OLD behavior 2025-01-17 09:28:37 -05:00
Brad King
fad9c55b8b CMP0013: Remove support for OLD behavior 2025-01-17 09:28:37 -05:00
Brad King
98a59ba8ad CMP0012: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
3c0dbb66f5 CMP0011: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
cf832e75bc CMP0010: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
77f8c374f3 CMP0009: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
43ef139567 CMP0008: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
d77a7e8d1c CMP0007: Remove support for OLD behavior 2025-01-17 09:28:36 -05:00
Brad King
5fd46699fc CMP0006: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
03934f16fa CMP0005: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
2a0a7401ce CMP0004: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
9dd9321a18 CMP0003: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
136528aa1b CMP0002: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
03a215643d CMP0001: Remove support for OLD behavior 2025-01-17 09:28:35 -05:00
Brad King
e62b6cb748 CMP0000: Remove support for OLD behavior 2025-01-17 09:28:34 -05:00
Brad King
6a1a08e634 Help: Add boilerplate text to use for removed policies 2025-01-17 09:28:34 -05:00
Brad King
759b55991a Merge topic 'renumber-to-4.0'
bd176b430c Renumber post-3.31 development from 3.32 to 4.0

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10183
2025-01-17 08:56:31 -05:00
Brad King
e95fce2849 Merge topic 'LINK_WARNING_AS_ERROR-extend-capabilities'
b350f95ecf LINK_WARNING_AS_ERROR property: extend capabilities
216c469214 MSVC: Use dash-style flag for LINK_WARNING_AS_ERROR

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !10133
2025-01-17 08:50:32 -05:00
Marc Chevrier
b350f95ecf LINK_WARNING_AS_ERROR property: extend capabilities
Fixes: #26536
2025-01-16 22:35:00 +01:00
Brad King
bd176b430c Renumber post-3.31 development from 3.32 to 4.0
Issue: #26613
2025-01-16 09:18:21 -05:00
Brad King
1d5c1b0023 Merge topic 'policy-cleanup'
b010a1fb1d Help: Update try_compile list of automatic policies
5e9b40b6a5 Help: Update cmake-buildsystem(7) TARGET_POLICY example to a newer policy
9ffbc0e628 Tests/RunCMake/cmake_minimum_required: Generalize deprecated version case name
0eca249ac7 Tests/RunCMake: Update more cmake_minimum_required versions to 3.10
a8cf033a74 Tests/RunCMake/return: Use newer cmake_minimum_required VERSION

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10178
2025-01-16 09:01:48 -05:00
Brad King
e87c6c6259 Merge topic 'execute-process-error'
3ece058d97 execute_process: Allow setting default COMMAND_ERROR_IS_FATAL value
85035dd954 Help/command/execute_process: Fix definition list formatting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10169
2025-01-16 08:59:00 -05:00
Brad King
8018f2a6c4 Merge topic 'instrumentation'
097d4fd1b5 instrumentation: Collect and record project build system metrics
8a3c195188 Tests/RunCMake: Add RunCMake_CHECK_ONLY Option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Alex <leha-bot@yandex.ru>
Merge-request: !9791
2025-01-16 08:55:25 -05:00
Brad King
7ea82512ca Merge topic 'patch-GenerateExportHeader'
319dd29ef0 GenerateExportHeader: Use lowercase command names

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !10176
2025-01-16 08:52:33 -05:00
Brad King
b010a1fb1d Help: Update try_compile list of automatic policies 2025-01-15 11:21:21 -05:00
Brad King
5e9b40b6a5 Help: Update cmake-buildsystem(7) TARGET_POLICY example to a newer policy 2025-01-15 11:21:21 -05:00