Commit Graph

71322 Commits

Author SHA1 Message Date
Brad King d11dceee4f Merge topic 'process-timeout-short' into release-4.1
6ec2c51f0c execute_process: Restore support for short timeouts

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11399
2025-11-10 09:07:39 -05:00
Brad King 6ec2c51f0c execute_process: Restore support for short timeouts
Since commit 5420639a8d (cmExecuteProcessCommand: Replace cmsysProcess
with cmUVProcessChain, 2023-06-01, v3.28.0-rc1~138^2~8) we've
occasionally observed immediate timeouts on processes that take longer
than the timeout to start, even though we only start the timer after the
child processes start.  The problem is that:

* `uv_loop_init` initializes `uv_loop_t`'s cached "now" time.
* Starting processes takes time but does not update the "now" time.
* `uv_timer_start` computes expiry relative the cached "now" time,
  so short timers may be expired as soon as they are started.
* `uv_run` invokes expired timer callbacks before polling for I/O
  or process completion, so we "timeout" immediately.

Fix this by updating the cached "now" time via `uv_update_time` just
before starting timers.  This is needed only for timers that start
before the `uv_run` event loop.  Update our `uv_timer_ptr` wrapper
to make all callers consider the choice when calling `start()`.
2025-11-09 09:13:43 -05:00
Brad King 61841b7ee4 Merge topic 'doc-cmake.org-tutorial-archive' into release-4.1
5473a45fd8 Tutorial: Restore source archive when published on cmake.org

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11370
2025-10-29 09:29:14 -04:00
Brad King 5473a45fd8 Tutorial: Restore source archive when published on cmake.org
Restore commit 4cb616fed6 (Tutorial: Provide a source archive when
published on cmake.org, 2022-04-27, v3.23.2~22^2).  Its effects were
accidentally reverted by commit 9784834b4c (Help: Use `*.rst` extension
for included files, 2025-04-07, v4.1.0-rc1~354^2).

Reported-by: Vito Gamberini <vito.gamberini@kitware.com>
2025-10-29 09:17:14 -04:00
Brad King 66095fd31d Merge topic 'improve-cps-project-error' into release-4.1
f2b7184b98 cmPackageInfoArguments: Improve error message

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11363
2025-10-28 09:17:37 -04:00
Brad King 48908f04f6 Merge topic 'improve-cps-export-namespace-error' into release-4.1
86e647ef2a CPS: Improve invalid namespace error

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11364
2025-10-28 09:16:36 -04:00
Matthew Woehlke 86e647ef2a CPS: Improve invalid namespace error
When CPS export fails due to a dependency on an improperly named
external target, reiterate the "canonical namespace" in the error
message for clarity.
2025-10-27 14:40:34 -04:00
Matthew Woehlke f2b7184b98 cmPackageInfoArguments: Improve error message
When given the name of a project that doesn't exist, report it as an
"unknown project" rather than an "invalid project". This is more
consistent with other, similar reporting.
2025-10-27 12:29:40 -04:00
Brad King 748921b693 Merge branch 'release-4.0' into release-4.1 2025-10-27 09:25:34 -04:00
Brad King 1b97439d3e Merge branch 'release-3.31' into release-4.0 2025-10-27 09:25:09 -04:00
Brad King 4e2aeae7ba Merge topic 'xcode-macos-deployment-target' into release-4.1
de53a46a91 Help: Add 4.1 release note for restored Xcode default deployment target
85ba6f5d1b Merge branch 'backport-4.0-xcode-macos-deployment-target'
884260ced6 Help: Add 4.0 release note for restored Xcode default deployment target
1a37c83c7e Xcode: Restore default CMAKE_OSX_DEPLOYMENT_TARGET to run on host
e927408047 Apple: Initialize deployment target after SDK

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11361
2025-10-27 09:12:00 -04:00
Brad King 847ce737c2 Merge topic 'doc-3.31.9-typo' into release-4.1
d07cedf9b3 Help: Fix typo in 3.31.9 release note heading

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11362
2025-10-27 09:11:22 -04:00
Brad King 5c67530c0f Merge topic 'ci-macos-sdk' into release-4.1
baa8cab401 ci: Revert packaging to macOS 15.5 SDK to restore cmake-gui rendering
aa1a122514 ci: Add script to install macOS SDK version 15.5
b33a5366f4 ci: Add script to repackage macOS SDKs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11359
2025-10-27 09:11:01 -04:00
Brad King 0e2331fc51 Merge topic 'backport-4.0-xcode-macos-deployment-target' into release-4.0
884260ced6 Help: Add 4.0 release note for restored Xcode default deployment target
1a37c83c7e Xcode: Restore default CMAKE_OSX_DEPLOYMENT_TARGET to run on host
e927408047 Apple: Initialize deployment target after SDK

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11361
2025-10-27 09:09:22 -04:00
Brad King 9f6c47a2a2 Merge topic 'doc-3.31.9-typo' into release-4.0
d07cedf9b3 Help: Fix typo in 3.31.9 release note heading

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11362
2025-10-27 09:08:08 -04:00
Brad King e195639d33 Merge topic 'ci-macos-sdk' into release-4.0
baa8cab401 ci: Revert packaging to macOS 15.5 SDK to restore cmake-gui rendering
aa1a122514 ci: Add script to install macOS SDK version 15.5
b33a5366f4 ci: Add script to repackage macOS SDKs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11359
2025-10-27 09:07:58 -04:00
Brad King b4cdd8aab5 Merge topic 'doc-3.31.9-typo' into release-3.31
d07cedf9b3 Help: Fix typo in 3.31.9 release note heading

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11362
2025-10-27 09:06:53 -04:00
Brad King 0fba1500c3 Merge topic 'ci-macos-sdk' into release-3.31
baa8cab401 ci: Revert packaging to macOS 15.5 SDK to restore cmake-gui rendering
aa1a122514 ci: Add script to install macOS SDK version 15.5
b33a5366f4 ci: Add script to repackage macOS SDKs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11359
2025-10-27 09:06:25 -04:00
Brad King d07cedf9b3 Help: Fix typo in 3.31.9 release note heading 2025-10-26 14:06:25 -04:00
Brad King de53a46a91 Help: Add 4.1 release note for restored Xcode default deployment target 2025-10-26 11:20:10 -04:00
Brad King 85ba6f5d1b Merge branch 'backport-4.0-xcode-macos-deployment-target' 2025-10-26 11:19:58 -04:00
Brad King 884260ced6 Help: Add 4.0 release note for restored Xcode default deployment target 2025-10-26 11:19:19 -04:00
Brad King 1a37c83c7e Xcode: Restore default CMAKE_OSX_DEPLOYMENT_TARGET to run on host
Xcode by default targets the SDK's macOS version rather than the host's
macOS version.  In commit 7b19531291 (macOS: Do not pass any
SDK/-isysroot to compilers by default, 2024-11-06, v4.0.0-rc1~511^2) we
reverted commit 24aafbde11 (Xcode: Adjust deployment target SDK version
to host version, 2015-10-11, v3.4.0-rc2~6^2), but it is still needed for
Xcode.  Restore the behavior so binaries run on the host by default.

Fixes: #27309
2025-10-26 11:19:19 -04:00
Brad King e927408047 Apple: Initialize deployment target after SDK 2025-10-26 11:16:45 -04:00
Brad King baa8cab401 ci: Revert packaging to macOS 15.5 SDK to restore cmake-gui rendering
Since commit 965a12cb8a (ci: update macOS jobs to use Xcode 26.0,
2025-09-18, v4.1.2~9^2) and commit 9d302ecd47 (ci: update macOS jobs to
use Xcode 26.0 in CMake 3.31 branch, 2025-10-07) our macOS 10.13+
packages are built using the macOS 26 SDK, with which Qt 5.15.2 does not
render buttons in `cmake-gui` correctly.  Revert to an older macOS SDK
to avoid the problem until we update our Qt version.

Fixes: #27325
2025-10-25 20:57:13 -04:00
Brad King aa1a122514 ci: Add script to install macOS SDK version 15.5
With Xcode 16.4, run

    env SDKROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk \
    .gitlab/ci/repackage/macos.sh

and host `MacOSX15.5.sdk.tar.bz2` ourselves.
2025-10-25 20:54:16 -04:00
Brad King b33a5366f4 ci: Add script to repackage macOS SDKs 2025-10-25 20:49:13 -04:00
Brad King 197069bc6a Merge branch 'release-4.0' into release-4.1 2025-10-25 09:15:42 -04:00
Brad King aa8f174479 Merge topic 'FindPython-3.15' into release-4.1
7f628ea04b FindPython: Add support for Python 3.15
5b78983813 Tests/FindBoost/TestPython: Improve python version list formatting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11350
2025-10-25 09:15:27 -04:00
Brad King a0e480ca89 Merge branch 'release-3.31' into release-4.0 2025-10-25 09:15:19 -04:00
Brad King 91525f6eb0 Merge topic 'FindPython-3.15' into release-4.0
7f628ea04b FindPython: Add support for Python 3.15
5b78983813 Tests/FindBoost/TestPython: Improve python version list formatting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11350
2025-10-25 09:15:04 -04:00
Brad King 9d2aa76bb7 Merge topic 'FindPython-3.15' into release-3.31
7f628ea04b FindPython: Add support for Python 3.15
5b78983813 Tests/FindBoost/TestPython: Improve python version list formatting

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11350
2025-10-25 09:14:38 -04:00
Karolina Surma 7f628ea04b FindPython: Add support for Python 3.15 2025-10-24 17:42:44 -04:00
Brad King 5b78983813 Tests/FindBoost/TestPython: Improve python version list formatting 2025-10-24 17:42:44 -04:00
Brad King 68721a1726 Merge branch 'release-4.0' into release-4.1 2025-10-22 19:11:44 -04:00
Brad King efe6ffc2f5 Merge topic 'backport-4.0-cross-compile-macos' into release-4.1
61d0bdf6b7 macOS: Avoid relying on sw_vers when cross-compiling from another OS
d9d65ab54f macOS: Remove outdated condition for CMAKE_OSX_DEPLOYMENT_TARGET

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11340
2025-10-22 19:09:36 -04:00
Brad King 9a2ee83045 Merge topic 'backport-4.0-cross-compile-macos' into release-4.0
61d0bdf6b7 macOS: Avoid relying on sw_vers when cross-compiling from another OS
d9d65ab54f macOS: Remove outdated condition for CMAKE_OSX_DEPLOYMENT_TARGET

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11340
2025-10-22 19:08:46 -04:00
Brad King 61d0bdf6b7 macOS: Avoid relying on sw_vers when cross-compiling from another OS
We have a few code paths needed only to support builds hosted on
macOS 10.4.  Update the conditions to work when cross-compiling
to macOS from another platform.

This backports commit eb8facd396 (macOS: Avoid relying on sw_vers
when cross-compiling from another OS, 2025-04-28, v4.1.0-rc1~260^2)
to CMake 4.0.

Fixes: #26814
2025-10-22 17:26:36 -04:00
Brad King d9d65ab54f macOS: Remove outdated condition for CMAKE_OSX_DEPLOYMENT_TARGET
Revert commit 2853326e7a (BUG: Only set CMAKE_OSX_DEPLOYMENT_TARGET on
Mac OSX 10.4 or later, 2009-01-27, v2.8.0~1169).  AFAIK no one is using
macOS versions older than 10.4 anymore.

This backports commit 476b2a386f (macOS: Remove outdated condition
for CMAKE_OSX_DEPLOYMENT_TARGET, 2025-04-28, v4.1.0-rc1~260^2~1)
to CMake 4.0.
2025-10-22 17:26:31 -04:00
Brad King 458ef4ad11 Merge branch 'release-4.0' into release-4.1 2025-10-21 11:03:29 -04:00
Brad King 3a953fcfff Merge branch 'release-3.31' into release-4.0 2025-10-21 11:03:18 -04:00
Brad King a606bc4a7f Merge topic 'backport-3.31-ios-compiler-inspection' into release-4.1
636d3a7a2f Apple: Backport "Enable linking during iOS toolchain inspection" to 3.31

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11333
2025-10-21 11:03:01 -04:00
Brad King 42b3b74bde Merge topic 'backport-3.31-ios-compiler-inspection' into release-4.0
636d3a7a2f Apple: Backport "Enable linking during iOS toolchain inspection" to 3.31

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11333
2025-10-21 11:02:39 -04:00
Brad King d83b2e8fe0 Merge topic 'backport-3.31-ios-compiler-inspection' into release-3.31
636d3a7a2f Apple: Backport "Enable linking during iOS toolchain inspection" to 3.31

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11333
2025-10-21 11:01:39 -04:00
Brad King 636d3a7a2f Apple: Backport "Enable linking during iOS toolchain inspection" to 3.31
Backport commit 79a83ddb08 (Apple: Enable linking during
iOS/tvOS/visionOS/watchOS toolchain inspection, 2024-11-14,
v4.0.0-rc1~471^2) to 3.31.

Since commit 11da882a12 (Apple: Introduce separate system name for iOS,
tvOS, and watchOS, 2018-01-15, v3.14.0-rc1~14^2~1) our toolchain
inspection steps, like ABI detection, tell `try_compile` to use a
`STATIC_LIBRARY` instead of an `EXECUTABLE`.  This was needed at the
time to avoid codesign requirements.  However, commit d3a64c4e3f (Xcode:
Explicitly turn off signing in try_compile projects, 2020-07-16,
v3.19.0-rc1~483^2) introduced a more general solution to that problem.
Restore linking during toolchain inspection so that we can detect and
identify the linker.

Suggested-by: Marc Chevrier <marc.chevrier@gmail.com>
Fixes: #26443
2025-10-21 09:22:41 -04:00
Brad King a2ebda45e2 Merge topic 'collect-genex-fix' into release-4.1
6e637b1102 install(PACKAGE_INFO): Fix error when usage requirements contain certain genex

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11322
2025-10-20 13:41:30 -04:00
Martin Duffy 6e637b1102 install(PACKAGE_INFO): Fix error when usage requirements contain certain genex
Since commit 13c7bb5b0c (cmGeneratorExpression: Update strip function to
collect parsed expressions, 2025-04-08, v4.1.0-rc1~361^2~1), the logic
to strip generator expressions would error if the stripped expressions
were being collected and an expression without a `:` was found inside an
expression with a `:`. This resulted in an error when exporting a target
that contained such a generator expression in its link libraries or
compile definitions.

Address the error by checking whether the latest `$<` proceeded the
latest `:`.
2025-10-17 11:34:43 -04:00
Brad King ae2cdad16c Merge branch 'release-4.0' into release-4.1 2025-10-07 16:47:47 -04:00
Brad King d4837302fe Merge branch 'release-3.31' into release-4.0 2025-10-07 16:45:24 -04:00
Brad King 892b0de5d4 Merge topic 'backport-ci-xcode-26' into release-3.31
9d302ecd47 ci: update macOS jobs to use Xcode 26.0 in CMake 3.31 branch
f6f1c5ca1f Tests: Teach RunCMake to ignore Xcode an IDERunDestination warning

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !11292
2025-10-07 16:44:28 -04:00