Commit Graph

67551 Commits

Author SHA1 Message Date
Brad King c7d11a77e4 ctest: Remove outdated optimization of tests running ctest itself
In commit 2c2291bbe0 (ENH: add new feature to ctest so that it can
cmake, build and run a test executable, 2004-01-07, v2.4.0~3483) ctest
was taught to recognize tests that run ctest itself and run them
internally instead of spawning a new process.  This optimization was
removed by commit b9daa192af (ENH: Refactored CTest test execution code
into an object, 2009-08-19, v2.8.0~276) `cmCTestRunTest` replaced
`cmCTestTestHandler::ProcessOneTest`, which was eventually removed by
commit 5a5cc52230 (Fixed conversion warning on 64 bit machines,
2009-08-31, v2.8.0~241).  Since then the optimization was only left in
`--build-and-test` mode, likely by accident, where it makes little
difference.  Remove it to simplify the code.

Also drop the `--force-new-ctest-process` option, originally added by
commit 9255e40d81 (ENH: Add a way to force ctest to be a new process,
2004-05-10, v2.4.0~3101), since it no longer does anything.
2024-10-16 14:13:46 -04:00
Brad King b2b7c4cc28 cmCTest: Remove unused functionality from RunTest method
`cmCTest::RunTest` has been used only for `--build-and-test` mode since
commit b9daa192af (ENH: Refactored CTest test execution code into an
object, 2009-08-19, v2.8.0~276).  Drop code needed only by its old role
of running tests.
2024-10-16 14:13:23 -04:00
Brad King 38ad939383 cmCTest: Fix clang-tidy performance-unnecessary-copy-initialization diagnostic 2024-10-16 14:12:58 -04:00
Brad King ee2eadb252 Merge topic 'ctest-build-and-test'
3d2882290b ctest: Split --build-and-test implementation from handler infrastructure
270ab612b9 cmCTestBuildAndTestHandler: Simplify RunCMakeAndTest signature

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !9903
2024-10-16 09:05:03 -04:00
Brad King 323fb2a662 Merge topic 'unity-relative-paths'
84996a65aa Unity: Add option to use relative paths for unity files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9874
2024-10-16 09:03:30 -04:00
Kitware Robot 9b8c5f4b6b CMake Nightly Date Stamp 2024-10-16 00:01:27 -04:00
Brad King aeaeb83f43 Merge branch 'release-3.31' 2024-10-15 13:57:28 -04:00
Brad King 36f6fa8737 Merge topic 'doc-rel-3.31'
315a8f88cc Help: Add 3.31 release note for file(MAKE_DIRECTORY)'s RESULT option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9904
2024-10-15 13:57:27 -04:00
Brad King 98ccd8800a Merge topic 'doc-rel-3.31' into release-3.31
315a8f88cc Help: Add 3.31 release note for file(MAKE_DIRECTORY)'s RESULT option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9904
2024-10-15 13:57:26 -04:00
Brad King 6bc88448ac Merge branch 'release-3.31' 2024-10-15 13:55:45 -04:00
Brad King f693d77ad4 Merge branch 'release-3.30' 2024-10-15 13:55:43 -04:00
Brad King 0d38588702 Merge branch 'release-3.29' 2024-10-15 13:55:41 -04:00
Brad King 2667406298 Merge branch 'release-3.30' into release-3.31 2024-10-15 13:55:34 -04:00
Brad King 1238adc3d0 Merge branch 'release-3.31' 2024-10-15 13:54:55 -04:00
Brad King 0eb871b856 Merge topic 'doc-rel-3.29'
0e81c12483 Help: Add 3.29 release note for try_compile LINKER_LANGUAGE option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9905
2024-10-15 13:54:55 -04:00
Brad King c7e27f02e8 Merge topic 'doc-rel-3.29' into release-3.31
0e81c12483 Help: Add 3.29 release note for try_compile LINKER_LANGUAGE option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9905
2024-10-15 13:54:54 -04:00
Brad King a56b554775 Merge branch 'release-3.29' into release-3.30 2024-10-15 13:34:23 -04:00
Brad King e3ebf4f5c0 Merge topic 'doc-rel-3.29' into release-3.30
0e81c12483 Help: Add 3.29 release note for try_compile LINKER_LANGUAGE option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9905
2024-10-15 13:34:08 -04:00
Brad King cb981c3b00 Merge topic 'doc-rel-3.29' into release-3.29
0e81c12483 Help: Add 3.29 release note for try_compile LINKER_LANGUAGE option

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9905
2024-10-15 13:33:47 -04:00
Brad King 0e81c12483 Help: Add 3.29 release note for try_compile LINKER_LANGUAGE option
In commit 0f37000304 (try_{compile,run}: add LINKER_LANGUAGE option,
2023-10-12, v3.29.0-rc1~567^2) a release note was accidentally added in
the wrong directory and so was not included in the 3.29 release notes.
2024-10-15 13:30:04 -04:00
Peter Kokot 315a8f88cc Help: Add 3.31 release note for file(MAKE_DIRECTORY)'s RESULT option
In commit 95323c90a1 (file(MAKE_DIRECTORY): Add optional RESULT keyword
to capture failure., 2024-06-16, v3.31.0-rc1~414^2) the release note was
added in the wrong directory so it was not gathered for the 3.31 release.

Fixes: #26377
2024-10-15 13:27:30 -04:00
James Moore 84996a65aa Unity: Add option to use relative paths for unity files
Add a target property that will be read on unity file generation to
attempt to use a relative path to the source file from the CMake Source
Directory or the generated unity file. Additionally add the CMake
Source Directory and the CMake Binary directory to the include path of
the generated unity files.

Closes: #26352
2024-10-15 09:44:18 -07:00
Brad King 3d2882290b ctest: Split --build-and-test implementation from handler infrastructure
It does not follow the pattern of the dashboard-mode step handlers.
2024-10-15 11:59:51 -04:00
Brad King 270ab612b9 cmCTestBuildAndTestHandler: Simplify RunCMakeAndTest signature
Since commit 1a165dc60d (ENH: Move the build-and-test code to a handler,
2005-06-03, v2.4.0~1632), factored RunCMakeAndTest out of cmCTest, its
argument has been unnecessary.  In commit e60e4dfc88
(cmWorkingDirectory: Check success of current dir changes, 2018-03-04,
v3.12.0-rc1~395^2~1) unnecessary branching was added based on the
argument.  Remove both the argument and branching.
2024-10-15 11:47:34 -04:00
Brad King f521d20cb4 Merge topic 'ctest-command-line'
c0c4d48ba2 cmCTest: Use cmCommandLineArgument command-line parsing infrastructure
67dc003467 cmCTest: Add missing const
9b09c3733a cmCTestBuildAndTestHandler: Simplify constructor
30ece11e66 cmCommandLineArgument: Do not treat negative numbers as flags

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !9901
2024-10-15 10:42:30 -04:00
Brad King 3bd8ac5b77 Merge branch 'release-3.31' 2024-10-15 10:31:02 -04:00
Brad King 027dc94922 Merge topic 'vs-fortran-ipo'
a36df0220f VS: Honor INTERPROCEDURAL_OPTIMIZATION for Fortran targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9899
2024-10-15 10:31:01 -04:00
Brad King 093a9dac38 Merge topic 'vs-fortran-ipo' into release-3.31
a36df0220f VS: Honor INTERPROCEDURAL_OPTIMIZATION for Fortran targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9899
2024-10-15 10:31:00 -04:00
Brad King f3ae0cd561 Merge branch 'release-3.31' 2024-10-15 10:29:59 -04:00
Brad King d9baceead0 Merge topic 'bug_remove_nvjitlink_from_nvrtc'
9d29544082 FindCUDAToolkit: nvrtc shouldn't hard depend on nvJitLink

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9902
2024-10-15 10:29:58 -04:00
Brad King 2fa6f6ff53 Merge topic 'bug_remove_nvjitlink_from_nvrtc' into release-3.31
9d29544082 FindCUDAToolkit: nvrtc shouldn't hard depend on nvJitLink

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9902
2024-10-15 10:29:57 -04:00
Brad King c58d07ba7c Merge topic 'findcurl-target-properties'
76c2d7781e FindCURL: Add more target properties from pkg-config

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9900
2024-10-15 10:28:20 -04:00
Kitware Robot 9c25632ba0 CMake Nightly Date Stamp 2024-10-15 00:01:20 -04:00
Brad King c0c4d48ba2 cmCTest: Use cmCommandLineArgument command-line parsing infrastructure 2024-10-14 12:12:51 -04:00
Brad King 67dc003467 cmCTest: Add missing const 2024-10-14 10:52:59 -04:00
Brad King 9b09c3733a cmCTestBuildAndTestHandler: Simplify constructor 2024-10-14 10:52:59 -04:00
Brad King 30ece11e66 cmCommandLineArgument: Do not treat negative numbers as flags 2024-10-14 10:52:59 -04:00
Pavel Liavonau a36df0220f VS: Honor INTERPROCEDURAL_OPTIMIZATION for Fortran targets
Also map `-Qipo` to its `.vfproj` attribute.

Fixes: #26361
2024-10-14 10:17:12 -04:00
Robert Maynard 9d29544082 FindCUDAToolkit: nvrtc shouldn't hard depend on nvJitLink
The dependency on nvJitLink was due to misunderstanding how runtime compiled code that uses
LTO is used. It doesn't require nvrtc to have a dependency on nvJitLink, just the caller.
2024-10-14 10:16:29 -04:00
Tobias Mayer 76c2d7781e FindCURL: Add more target properties from pkg-config
In case libcurl was found via pkg-config, the properties
`INTERFACE_LINK_LIBRARIES`, `INTERFACE_LINK_OPTINS`, and
`INTERFACE_COMPILE_OPTINS` can be populated from the `PC_CURL_*`
variables if available.

Fixes: #26365
2024-10-14 10:11:15 -04:00
Brad King 8c622959e9 Merge topic 'ctest-core'
774fcbe49c CTest: Base command line mode on top of scripting commands
5115c01e1f CTestCommandLine tests: Make sure to test successful run

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9881
2024-10-14 10:02:05 -04:00
Kitware Robot 82dafe874e CMake Nightly Date Stamp 2024-10-14 00:02:54 -04:00
Kitware Robot 3e8a6e08f0 CMake Nightly Date Stamp 2024-10-13 00:01:53 -04:00
Brad King f20a9dd84c Merge topic 'ctest-log'
6fcb64d6b4 cmCTest: Reduce string copies during logging
97b95f24fd cmCTest: Simplify log flushing
134df24ff1 cmCTest: Remove undocumented option to log internal line numbers
24daa48a7d cmCTest: Strengthen log type enumeration
c73215d922 cmCTest: Remove RunTest log argument not used by any caller

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9898
2024-10-12 10:33:16 -04:00
Brad King ac76ce71f0 Merge topic 'ctest-empty-binary'
bcb396996c cmCTestEmptyBinaryDirectoryCommand: turn into a free function
9a5525cae7 cmCTestSleepCommand: implement as free function
f7ed0bd2f3 cmCTestCommand: remove CTestScriptHandler member
1440b05bf1 cmMakefile: invoke callback after command execution

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9869
2024-10-12 10:32:16 -04:00
Brad King 2f470f873c Merge topic 'tidy-readability-redundant'
58c5f77837 clang-tidy: fix `readability-redundant-*` warnings

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9893
2024-10-12 10:31:15 -04:00
Brad King 9b2fcb7779 Merge topic 'LINKER-prefix-support-for-libraries'
aba1c9d172 target_link_libraries: Add support for the LINKER: prefix

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9882
2024-10-12 10:30:12 -04:00
Brad King 04217e88ad Merge topic 'xcode-target-sorting'
e3be24da68 Xcode: case-insensitive target ordering
80d0770250 Xcode: Fix target ordering operator to meet std::sort requirements

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9897
2024-10-12 10:29:10 -04:00
Daniel Pfeifer 774fcbe49c CTest: Base command line mode on top of scripting commands
Make sure that all CMake variables that are translated into
CTest options in `cmCTest*Command` implementations are translated
from CTest options into CMake variables before the functions are
called.  This back-and-forth translation should be temporary.
It is a necessary prerequisite for refactoring `cmCTest*Handler`
implementations to operate on CMake variables directly rather
than CTest options.
2024-10-12 06:42:02 -04:00
Kitware Robot 25c09519d2 CMake Nightly Date Stamp 2024-10-12 00:01:30 -04:00