Commit Graph
100 Commits
Author SHA1 Message Date
Tyler Yankee 392a79b910 Help/dev: Document use of sphinx-copybutton
Add a section on third-party Sphinx extensions. While we're here, add
a cross-reference on CMake's `README.rst`.
2026-08-21 09:43:48 -04:00
Tyler Yankee 1c5e70c9d0 bootstrap: Add --sphinx-html-copybutton option
Consistent with the SPHINX_HTML_COPYBUTTON CMake option.
2026-08-21 09:43:48 -04:00
Tyler Yankee 1b1225a766 ci: Enable Sphinx copybutton for cmake.org and Sphinx jobs 2026-08-21 09:43:48 -04:00
Tyler Yankee ad5a65dd34 Utilities/Sphinx: Add option to build with copybutton
The copy button is convenient for copying code blocks from CMake's
documentation pages, and can be especially helpful when following the
CMake tutorial. It is implemented optionally so that developers without
the extension installed locally can still preview the site.

Fixes: #28046
2026-08-21 09:43:48 -04:00
Tyler Yankee 59875d4a08 Tests/FindImageMagick: Tolerate pre-release versions
The version installed from the system in our new Fedora 44 CI base
image has a beta version of ImageMagick installed, which the
FindImageMagick module can't parse.
2026-08-21 09:43:48 -04:00
Tyler Yankee 45a426a4e3 codespell: Fix some hyphenated spellings
These were surfaced by an updated `codespell` in the `spellcheck` CI
base image.
2026-08-21 09:43:48 -04:00
Tyler Yankee e42cde3405 cmBuildDatabase: Use cmJSONState to read mcdb's
This approach will be more portable.
2026-08-13 08:20:13 -04:00
Tyler Yankee e2da85c672 VS: Use cmJSONState to read flag table
This approach will be more portable.
2026-08-12 16:56:55 -04:00
Tyler Yankee afb609ce14 cmScanDepFormat: Use cmJSONState to parse P1689 output
This approach will be more portable.
2026-08-03 19:59:19 -04:00
Tyler Yankee 4678b7b34a string(JSON): Use cmJSONState to read input
This approach will be more portable.
2026-08-03 19:52:53 -04:00
Tyler Yankee 76026ce818 Tests/string(JSON): Add comments to test case
Verify that our current JSON parsing allows comments (but throws them
away).
2026-08-03 19:52:53 -04:00
Tyler Yankee 44d8022322 cmPListParser: Use cmJSONState to read plist
This approach will be more portable.
2026-08-03 19:18:20 -04:00
Tyler Yankee c0e1d332af cmCTestSubmitHandler: Use cmJSONState to read responses
This approach will be more portable.
2026-08-01 11:38:10 -04:00
Tyler Yankee 7b7e9c162c VS: Use cmJSONState to read vswhere output
This approach will be more portable.
2026-08-01 11:37:32 -04:00
Tyler Yankee 1a9d3faff1 cmInstrumentation: Use cmJSONState to read snippet files
This approach will be more portable.
2026-07-30 13:53:04 -04:00
Tyler Yankee 8dd00674bd cmInstrumentationCommand: Use cmJSONState to read content args
This approach will be more portable.
2026-07-30 13:52:58 -04:00
Tyler Yankee 26e6188e04 Tests/Instrumentation: Split make cases out to separate suite
These tests experience frequent timeouts in CI, which are either actual
timeouts due to low resource runners, or a platform-specific bug
causing an indefinite hang. Either way, it's beneficial to locate these
in their own test suite to reduce noise and ensure the rest of the
tests pass regularly.
2026-07-30 11:14:48 -04:00
Tyler Yankee 76e4137229 cmJSONState: Allow strictMode toggle
During the refactoring to cmJSONState, some callsites will need to
use "relaxed" parsing to maintain compatibility.
2026-07-30 10:29:20 -04:00
Tyler Yankee 397fcd4663 cmJSONState: Allow input stream as input 2026-07-30 10:29:19 -04:00
Tyler Yankee 6eedfce567 Tests/Instrumentation: Fix indentation level of make cases 2026-07-29 12:59:21 -04:00
Tyler Yankee fb200b417a Tests/Instrumentation: Re-home interrupt case to bottom
Prepare for a future commit which adds another test suite by
consistently locating all variants at the bottom.
2026-07-29 12:59:21 -04:00
Tyler Yankee cfede7be9d Tests/Instrumentation: Split make cases out to separate suite
These tests experience frequent timeouts in CI, which are either actual
timeouts due to low resource runners, or a platform-specific bug
causing an indefinite hang. Either way, it's beneficial to locate these
in their own test suite to reduce noise and ensure the rest of the
tests pass regularly.
2026-07-29 10:59:42 -04:00
Tyler Yankee f880286604 Tests/NinjaMultiConfig: Split into three variants
These experience timeouts in CI. Split into three equally-ish sized
buckets so each can run independently.
2026-07-29 10:51:04 -04:00
Tyler Yankee 7608148194 Tests: Harden assertions around {write,delete}_regv
Issue: #27990
2026-07-28 09:59:22 -04:00
Tyler Yankee c707fde0f2 Help: Move general FILE_SET info to cmake-buildsystem(7)
File sets have evolved to be more ubiquitous throughout a CMake build,
outside the scope of simply the target_sources command. Move general
information to the `cmake-buildsystem(7)` manual and keep only
reference information specific to the syntax of target_sources in its
command page. Sprinkle some more cross-references to the new location.

Fixes: #27900

Suggested-By: Marc Chevrier <marc.chevrier@gmail.com>
2026-07-27 09:01:37 -04:00
Tyler Yankee 4eda69be82 Tests: Centralize JSON schema validation
As the number of areas in CMake for which we've provided JSON schemas
has expanded, testing infrastructure has mostly been copy-pasted across
the relevant test suites. Unify it to a single reusable validator
script and CMake helper.
2026-07-24 09:55:23 -04:00
Tyler Yankee d3ccd49eeb cmFileAPI: Use cmJSONState to read client queries
This approach will be more portable.
2026-07-24 07:47:19 -04:00
Tyler Yankee 1255d1b9fb curl: Restore check for BoringSSL in vendored build
As of commit 15266bf2a4 (Utilities: Avoid OpenSSL version check under
forks, 2026-07-21) we do, in fact, need this info.

Fixes: #27978
2026-07-23 08:47:53 -04:00
Tyler Yankee 8b653cd50c cmGccDepfileLexerHelper: Use fopen from SystemTools
Delegate to SystemTools for portability and consistency with the rest
of the code base.
2026-07-22 09:30:00 -04:00
Tyler Yankee 15266bf2a4 Utilities: Avoid OpenSSL version check under forks
When finding BoringSSL, LibreSSL, or AWS-LC, version information may be
unavailable. Amend commit 54686cae64 (Utilities: Require OpenSSL >=
3.0.0 at configure time, 2026-06-26) by using the checks from upstream
curl to only error if we're using OpenSSL proper.

Fixes: #27978
2026-07-21 18:51:08 -04:00
Tyler Yankee 027b962a81 VS: Avoid unsupported ScanSourceForModuleDependencies under ClangCl
As of commit ed48feeae8 (clang-cl: Add support for C++ modules,
2026-03-27, v4.4.0-rc1~428^2) CMake tries to support modules for
clang-cl, which can mostly be accomplished, except for the ClangCl VS
toolset, where the /scanDependencies flag is not yet supported.

Amend commit 3022f0363f (VS: set ScanSourceForModuleDependencies at
vcxproj level, 2024-04-27, v3.28.5~3^2) to only emit this setting when
scanning is supported by the toolchain.

Fixes: #27957
Issue: #27977
2026-07-21 17:02:29 -04:00
Tyler Yankee c3c95f3010 GoogleTest: Avoid generation error on duplicate target test discovery
The discovery script created by commit 3748ca9f (GoogleTest: generate
single discovery script, 2026-04-08, v4.4.0-rc1~302^2~1) creates
generate-time collisions if gtest_discover_tests() is called on the
same target in the same directory with the same arguments multiple
times. Handle the case with a warning to preserve compatibility with
existing projects.

Fixes: #27940
2026-07-20 13:26:08 -04:00
Tyler Yankee fc1b218b37 GoogleTest: Fix gtest_discover_tests race on POST_BUILD of multiple targets
Restore the logic from commit 6680df042e (GoogleTest: Avoid POST_BUILD
race condition for gtest_discover_tests(), 2025-10-26, v4.2.0-rc2~15^2)
that was lost in the refactoring in commit 3748ca9fc7 (GoogleTest:
generate single discovery script, 2026-04-08, v4.4.0-rc1~302^2~1). Add
a regression test.

Fixes: #27939, #27319, #27972
2026-07-20 11:21:35 -04:00
Tyler Yankee e79506fadf GoogleTest: Fix gtest_discover_tests race on POST_BUILD of multiple targets
Incorporate the logic from commit 6680df042e (GoogleTest: Avoid
POST_BUILD race condition for gtest_discover_tests(), 2025-10-26,
v4.2.0-rc2~15^2) into the JSON test discovery mechanism introduced in
commit 1cdceae8e3 (GoogleTest: Parse discovered test list from JSON
output if supported, 2025-05-02, v4.2.0-rc1~533^2~2). Add a regression
test.

Fixes: #27939, #27319, #27972
2026-07-20 11:19:17 -04:00
Tyler Yankee f1dbb9e1dc Tests/Instrumentation: Disable rsp check on macOS
Issue: #16731
2026-07-17 13:39:11 -04:00
Tyler Yankee 0d320cb496 ctest: Exit nonzero when write to output JUnit or XML fails
`ProcessHandler` can return -1, 0, or 1, and the latter is used in this
particular case.

Fixes: #27949
2026-07-15 15:56:03 -04:00
Tyler Yankee 9d7da095fd Ninja: Restore cmcldeps command-line ordering
Restore the ordering before the refactoring in commit 0f20ba5b68
(Ninja: Swift: Extract helpers and reorder module flags, 2026-04-10,
v4.4.0-rc1~273^2~1) to ensure the correct precedence with launchers.
Add regression tests.

Fixes: #27931, #27934
2026-07-14 12:32:21 -04:00
Tyler Yankee 727522d835 instrumentation: Fully resolve compile trace path
When the build is invoked under the native build tool's (commonly
spelled) `-C` option to change from the current working directory to a
given build tree, the default path to a snippet's `-ftime-trace` file
under its corresponding target's object directory was incorrectly
stored based on the path from the working directory.
2026-07-09 09:43:18 -04:00
Tyler Yankee fd395b25b5 ctest: Improve colorization in output
Refactor CTest's logging to replace custom color code handling with the
infrastructure introduced in commit 329d755dbd (StdIo: Add a Terminal
abstraction to print color text, 2025-05-06).

Avoid ANSI escape sequences in files passed to `--output-log-file`.

Fixes: #27915
2026-07-03 10:02:43 -04:00
Tyler Yankee 273c414ece Help: Dedent multiple install --components note 2026-07-03 09:09:59 -04:00
Tyler Yankee 224463f31c GoogleTest: Avoid cluttering custom working directory during discovery
Backport the functionality from commit b5f555f687 (GoogleTest: Avoid
cluttering custom working directory during discovery, 2026-06-07,
v4.4.0-rc2~12^2). Work around the refactoring done in commit 3748ca9fc7
(GoogleTest: generate single discovery script, 2026-04-08,
v4.4.0-rc1~302^2~1).
2026-06-29 16:50:39 -04:00
Tyler Yankee 54686cae64 Utilities: Require OpenSSL >= 3.0.0 at configure time
The currently-vendored version of curl, when using OpenSSL, errors at
build time without at least version 3. Fail-fast at configure instead.

Fixes: #27902
2026-06-26 19:57:25 -04:00
Tyler Yankee a3b5591bbc fileapi: Omit NONE language entries from toolchains
Fixes: #27885
2026-06-23 08:42:00 -04:00
Tyler Yankee bf71991174 instrumentation: Add JSON schema for snippet files
Issue: #27504
2026-06-15 10:35:53 -04:00
Tyler Yankee b736acdc3b Tests/instrumentation: Check errors for query schema validation 2026-06-15 10:35:27 -04:00
Tyler Yankee 1f32d51dbb Help/file: Reference curl documentation for error codes
Fixes: #27866
2026-06-11 13:47:24 -04:00
Tyler Yankee ef5e1e3a5b Help: Fix references to cmake_language(GET_MESSAGE_LOG_LEVEL)
While we're at it, use the new `:cmake-option:` role to shorten some
references to `--log-level`.
2026-06-04 09:03:55 -04:00
Tyler Yankee 1bc30bd30d Help/ctest: Improve formatting of dashboard options
We must differentiate between the `ctest -D` dashboard and `ctest -D`
variable options.
2026-06-02 13:49:16 -04:00
Tyler Yankee 54be7af178 Tests: Remove empty CMakePresets *.cmake files
When adding a presets test case, the per-case `.cmake` files are
sometimes not necessary to exercise the test logic. Relax the inclusion
of such files and remove all empty placeholders.

Note that some non-empty `CMakePresets/Trace-*.cmake` files are also
removed; they only include other empty files, and nothing in the test
case assertions (trace outputs / stderr) exercises the include
statements themselves.
2026-06-01 16:31:58 -04:00
Tyler Yankee 69be06bad3 Help/fileAPI: Add version modified directives
Extend (part of) commit f26e9fcbae (Help: Generate presets JSON schema,
documentation, 2026-04-08) to the `cmake-file-api(7)` page, for each of
the currently applicable object kinds (i.e., only those which have
undergone changes, which is predominantly the codemodel).

This standardization helps to improve both the readability and
maintainability of the document.
2026-05-22 08:22:04 -04:00
Tyler Yankee c0eddfb8c8 ctest: Add missing help strings for documented options 2026-05-19 11:49:29 -04:00
Tyler Yankee 2f3de9e2f3 Help/ctest: Improve formatting and grammar 2026-05-19 11:49:29 -04:00
Tyler Yankee 36e486555d Help, ctest: Add argument placeholders
Conventionally, CMake help modes and manuals/documentation specify
placeholders for options which take one or many values after the option
name. Several existing `ctest` options do not follow this.

Fixes: #27827
2026-05-19 11:49:28 -04:00
Tyler Yankee e16767d962 presets: Fix command help for --presets-file
Amends commit 95edd93948 (presets: Support loading from arbitrary file,
2026-03-18).
2026-05-19 11:49:26 -04:00
Tyler Yankee e93ac092a7 cmake: Disallow --preset with -P script mode
Fixes: #25495
2026-05-17 14:47:42 -04:00
Tyler Yankee 2e55f86bb3 cmHexFileConverter: Avoid stack buffer overflow
Prevent overflow on maliciously-crafted Motorola S1 record files which
have a maximum line length over the 256-byte maximum.
2026-05-16 16:13:30 -04:00
Tyler Yankee 4b093ae12e Tutorial: Move multi-config install note to the first exercise
The context is needed when running all exercises in this step.

Revise both this note and its mirror for `ctest` in Step 7 to
cross-reference the relevant flags.
2026-05-14 18:22:14 -04:00
Tyler Yankee 653356bed0 Tutorial: Describe install prefix
Give a brief overview of what the install prefix is and the various
ways it can be set.
2026-05-14 18:11:41 -04:00
Tyler Yankee fdc4511f18 Tutorial: Fix some typos 2026-05-14 17:54:34 -04:00
Tyler Yankee 50ce808ca7 Tests: Move cache variable help string test
Even though it doesn't necessarily reuse infrastructure, the other
cases in `RunCMake.CacheNewlines` are covering more similar code to
this case than those in `RunCMake.Configure`.
2026-05-13 18:24:46 -04:00
Tyler Yankee 053f02a41c cmCacheManager: Fix warning comment for cache vars containing newlines
Reuse the logic from commit 637a0f7ed4 (cmCacheManager: Prevent
corruption from multiline help strings, 2025-02-04, v4.0.0-rc1~52^2)
for the warning message placed in the cache when a cache variable's
value contains one or more newline characters.

While we're at it, remove a superfluous early-exit in the help strings
method.

Fixes: #27807

Suggested-By: Yauheni Khnykin <yauheni.khnykin@here.com>
2026-05-13 18:21:04 -04:00
Tyler Yankee d67c1b04ec cmELF: Protect against OOM on malformed files
Cap the number of ELF sections, the section size, and the number of
dynamic entries to reasonable limits for real-world binaries to prevent
OOM on malformed inputs.
2026-05-13 15:51:55 -04:00
Tyler Yankee 9f4cf1cef7 fileAPI: Report full backtraces for sources in multiple file sets
Previously, if a single source file was added to multiple file sets via
multiple `target_sources` calls, only the first call originally adding
it to the target was stored in the backtrace graph and referenced by
index in the singular "backtrace" field.

Add a "backtraces" field expanding this to cover all command
invocations which associate the given source file with that target.
Preserve the original "backtrace" field for compatibility. Update
spellings in the test suite to check against both fields.

Issue: #27035
2026-05-12 16:45:13 -04:00
Tyler Yankee 3d249d2aa9 fileAPI: Support files added to multiple file sets
The `fileSetIndex` field of target sources replies is incomplete, as a
single source file can be added to arbitrarily many file sets. Add a
`fileSetIndexes` field to report all file sets to which a source
belongs, and preserve `fileSetIndex` for compatibility as the index of
the most recent addition.

Tweak the test suite to use the plural spelling only in expected JSON
snippets and verify that the singular `fileSetIndex` is always the last
element of the new list. (Note that remaining occurrences of the
singular spelling correspond to "installers" objects, which is entirely
different.)

Fixes: #27035
2026-05-12 16:45:12 -04:00
Tyler Yankee 935c8525f6 libarchive: Backport "Validate pathname in record_hardlink"
Backport libarchive commit `16ad931073` (cpio reader: Validate pathname
in record_hardlink, 2026-05-08).

Add a fuzzing test case to expose this to dynamic analysis tools.
2026-05-09 19:38:34 -04:00
Tyler Yankee c6e81bf30e Help/presets: Disallow empty env keys in build presets also
Build presets have a non-standard environment variable definition in
the schema yaml since they need extra Sphinx content. However, it was
missing the rule to disallow empty keys that the base environment
variable definition has.
2026-05-01 13:18:41 -04:00
Tyler Yankee 95edd93948 presets: Support loading from arbitrary file
Allow CMake, CTest, and CPack to read presets from a path given by
command-line argument instead of always requiring `CMakePresets.json`
or `CMakeUserPresets.json` in the source tree. This makes the presets
feature more extensible to cases in which the user doesn't have access
to the presets defined in the source tree (e.g., if the source tree is
not writable).

For now, there is no equivalent implementation of such an option in the
`cmake-gui`, nor for the recent presets functionality implemented in
`ctest_configure` and `ctest_build`.

Fixes: #27329
2026-04-30 08:04:26 -04:00
Tyler Yankee 81c22a67b6 presets: Factor out command line arguments
Create a separate hierarchy of classes to manage command-line arguments
for CMake presets to facilitate shared definitions across our programs.
2026-04-30 07:49:43 -04:00
Tyler Yankee e75b62fd73 presets: Convert allowNoFiles to enum class
This improves readability at the call site when "yes" is desired.
2026-04-30 07:49:42 -04:00
Tyler Yankee 8476469b72 Help: Add cmake-workflow-option role 2026-04-30 07:49:42 -04:00
Tyler Yankee 5e76987626 Help/presets: Use preset role for configurePreset references 2026-04-30 07:49:41 -04:00
Tyler Yankee 2d8e8213d4 Help/presets: Improve include field formatting
Note the presets version which added it, and use the new `preset`
role when referencing it from other sections.
2026-04-30 07:49:40 -04:00
Tyler Yankee 43f5fc8ac8 Help, Tests: Consolidate presets terminology and references
References to `CMake[User]Presets.json` should correspond to behavior
pertaining to those files in particular, while references to presets
files generally should be disambiguated from that.

Re-spell "preset file" to "presets file" where applicable.

Make a few references to `cmake-presets(7)` more consistent.

Issue: #27329
2026-04-30 07:49:40 -04:00
Tyler Yankee c49ebb67da Help: Use POSIX slashes for 'generated by' in presets files 2026-04-30 07:49:39 -04:00
Tyler Yankee 57444e1d3f math: Avoid FPE on INT_MIN by -1 2026-04-27 09:22:26 -04:00
Tyler Yankee 86dfdbee1f libarchive: Backport "Fix use of uninitialized values from Huffman table"
Backport libarchive commit `1f5454575f` (cab reader: Fix use of
uninitialized values from Huffman, 2026-04-23).

Add a fuzzing test case to expose this to dynamic analysis tools.
2026-04-26 18:25:06 -04:00
Tyler Yankee bf5512260b Tests/Fuzzing: Update link to local repro
The page has been moved.
2026-04-26 18:03:00 -04:00
Tyler Yankee 703eaf5ca2 Tests/instrumentation: Simplify some conditionals 2026-04-24 14:24:54 -04:00
Tyler Yankee 9bef6169f2 presets: Collapse source directory to avoid trailing slash
Fixes: #25754
2026-04-23 08:18:44 -04:00
Tyler Yankee 4229667859 Tests: Extend symlink-related archive tests to cross-platform
Use `cmake -E create_symlink` or `file(CREATE_LINK)` as appropriate
instead of `ln -sf` on UNIX only to extend cases of (a) symlinks inside
archives and (b) archive extraction to a directory symlink to non-UNIX
platforms where either of these modes may be supported.

The latter relies on the NEW behavior of CMP0205 as it uses
`COPY_ON_ERROR` for platforms where directory symlinks aren't
supported.

Issue: #27756
2026-04-22 13:59:20 -04:00
Tyler Yankee 19f8fcfd24 Tests/File_Archive: Relax more stderr line matching
Much the same flavor as commit 6e638ce109 (Tests/File_Archive: Relax
stderr line matching, 2026-04-14, v4.3.2~9^2~1).
2026-04-22 13:46:49 -04:00
Tyler Yankee 550a8c16ae ci: Use strict GCC options on merge requests
Migrate over the incidental non-coverage-specific options from our GCC
Gcov job to Fedora Ninja on merge requests to reduce development latency.
2026-04-16 09:24:09 -04:00
Tyler Yankee 57ca3dc521 file(CREATE_LINK): Fix CMP0205 to not remove content behind directory symlink
When removing the destination directory link when it already exists
before making the new link, only the (destination) link should be
removed, not the (source) directory itself. When COPY_ON_ERROR is
specified and the destination is a directory, only then should CMake
remove it, since it could likely be placing a new directory there in
its place.

With this new behavior, adjust the conditions for the symlink test from
commit a73ddd2ddb (file(CREATE_LINK): Implement COPY_ON_ERROR for
directories, 2025-10-15, v4.3.0-rc1~599^2). The newly modified test
case should be run on systems that do and don't support directory
symlinks, with slightly different outcomes that are verified.

Fixes: #27747
2026-04-15 14:03:40 -04:00
Tyler Yankee a6470b4681 Help/file: Clarify behavior change with CMP0205 2026-04-15 14:03:39 -04:00
Tyler Yankee b894942d3e file(CREATE_LINK): Revise CMP0205 warning
Ensure we only warn when COPY_ON_ERROR is specified. While we're at it,
tweak the spelling and apply consistent policy & logic ordering in
compound conditions.
2026-04-15 14:02:50 -04:00
Tyler Yankee 4397f89c16 Restore archive extraction between directory symlinks
Commit 03f19aa4ea (cmSystemTools: Fix path traversal vulnerability in
archive extraction, 2026-01-06, v4.3.0-rc1~179^2) incidentally
introduced the `ARCHIVE_EXTRACT_SECURE_SYMLINKS` flag when extracting
archives, which prevents extraction of objects whose location would be
altered by a symlink on disk. However, this particular behavior change
was never documented or tested alongside the other changes in the
commit (absolute paths and path traversal components).

Divergent behavior of this flag from `libarchive` on Windows and
non-Windows platforms needs further investigation. In particular, on
Windows, archives cannot be extracted through directory symlinks, but
can be extracted through junctions. On Linux, archives *can* still be
extracted through symlinks, and archives containing symlinks can be
extracted as well.

The symlink change breaks compatibility with many common use cases of
existing projects, e.g., when extracting an archive inside a symlinked
build directory. Revert the flag until this issue can be explored in a
future version of CMake.

Fixes: #27752
Reported-by: scivision <scivision@users.noreply.github.com>
2026-04-14 15:57:13 -04:00
Tyler Yankee 6e638ce109 Tests/File_Archive: Relax stderr line matching
"Compression format unsupported" errors of this form can only possibly
come from `file(ARCHIVE_CREATE)`, so we don't need to track the line
number of the called function. Reduce the need to update these numbers
every time the test helper script is updated.
2026-04-14 15:48:36 -04:00
Tyler Yankee cec6248a94 Help/ctest_*: Improve documentation around the edges
Improve standardization and cross-references. This doesn't make any
substantial changes to the existing prose.
2026-04-13 14:32:01 -04:00
Tyler Yankee c8b6725977 Help: Mention CMAKE_<LANG>_LINK_FLAGS where relevant
Also, correct the documentation added in commit 98f9874703 (cmake:
Add per-language link flags for all target types, 2025-12-17) by
placing the variables in the proper section of cmake-variables(7).

Issue: #21934
2026-04-07 10:14:28 -04:00
Tyler Yankee 7c42602e90 ci: Remove experimental UUID for instrumentation
As of commit 95dc40d8a8 (Experimental: Remove Instrumentation
experimental gating, 2026-02-03) this is no longer needed.
2026-04-07 09:45:32 -04:00
Tyler Yankee 0a6237c6fd Tests/Instrumentation: Reduce to C only
Testing with both C and C++ is not currently required to support any
functionality in the test cases, so remove the C++ toolchain detection
which, when repeated for each test case, makes it run substantially
faster.
2026-04-06 16:46:36 -04:00
Tyler Yankee 6ff2057b93 Help/if: Improve formatting
Consolidate the description of precedence during evaluation. Use xrefs
to improve syntax highlighting. Remove an outdated `versionadded`
directive for CMake 2.6.
2026-04-03 09:36:04 -04:00
Tyler Yankee 2b924b885c cmCTest: Use consistent command-line parsing for presets 2026-03-30 09:04:06 -04:00
Tyler Yankee f4d4700d6b cmake: Move preset argument parsing to dedicated method 2026-03-29 14:50:49 -04:00
Tyler Yankee 858fdd426b add_custom_command: Disallow exe-suffixed targets in DEPENDS
Two targets whose names differ only in a `.exe` suffix create a
conflict when adding target- and file-level dependencies for a custom
command. Add CMP0212 to provide compatibility with the old behavior.

Issue: #27612
2026-03-23 09:50:46 -04:00
Tyler Yankee 58ab03c031 add_custom_command: Update dependency search heuristics
Search for a target with the `.exe` suffix stripped from its name only
if a target by the original name doesn't exist.

Fixes: #27612
2026-03-23 09:49:28 -04:00
Tyler Yankee ef95ae2e45 cmake --workflow: Improve errors when no preset is specified
Add a better error message and tests to verify.
2026-03-19 10:24:33 -04:00
Tyler Yankee af78be98c5 cmake --build: Improve errors when no preset is specified
Add a better error message and tests to verify.
2026-03-19 10:18:31 -04:00
Tyler Yankee 6014f09e97 cpack: Improve errors when no preset is specified
Add a better error message and tests to verify.
2026-03-19 10:18:31 -04:00
Tyler Yankee f8ae1bbbec ctest: Improve errors when no preset is specified
Apply the same logic to both "equals" and non-"equals" forms of the
argument when no preset is specified, and add test cases.
2026-03-19 10:18:22 -04:00