Commit Graph

34161 Commits

Author SHA1 Message Date
Brad King
861dd60ecf Genex: Restore REMOVE_DUPLICATES preservation of empty elements
Refactoring in commit 72d116ee68 (GenEx: list oriented genexes use
cmList class, 2023-03-29, v3.27.0-rc1~205^2) accidentally caused
empty elements to be dropped by the `REMOVE_DUPLICATES` genex.
Fix it and add a test case.

Fixes: #25080
2023-07-12 11:49:21 -04:00
Brad King
fbe5f49d63 Merge topic 'compile-commands-modules' into release-3.27
677b28dc7b Ninja: include module mapper flags in `compile_commands.json`

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !8611
2023-07-12 10:02:52 -04:00
Ben Boeckel
677b28dc7b Ninja: include module mapper flags in compile_commands.json
Fixes: #24618
2023-07-09 11:04:29 -04:00
Brad King
8a07bcc149 MSVC: Restore support for non-incremental linking without 'rc' in PATH
Since commit 0b552eb877 (MSVC: Embed manifests directly for
non-incremental vs_link_exe links, 2023-02-20, v3.27.0-rc1~438^2) we
tell the MSVC `link` tool to embed manifests directly rather than
running `mt` ourselves.  However, `link` expects `rc` to be in the PATH
when embedding manifests.  Although that is normally true, some users
prepare minimal environments and explicitly specify include and link
directories for the Windows SDK.  In such cases, `rc` is not in the PATH
and is explicitly specified in `CMAKE_RC_COMPILER`.  Restore support for
such cases by explicitly adding the RC location to the end of the PATH.

Fixes: #25047
2023-07-06 08:11:34 -04:00
Brad King
b384058e4b CMake 3.27.0-rc4 2023-06-30 10:31:40 -04:00
Brad King
1cc4e97e87 Merge topic 'debugger-segfault' into release-3.27
764258771a Debugger: Fix threads request segfault after thread exited event

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8604
2023-06-30 09:30:20 -04:00
Ben McMorran
764258771a Debugger: Fix threads request segfault after thread exited event
Fixes: #25041
2023-06-29 13:25:51 -04:00
Brad King
b9c99830c5 VS: Fix C++ modules in source files with the same name
When multiple source files in a single target have the same name, we
already set `ObjectFileName` explicitly to avoid a `.obj` collision. For
C++ module sources, set `Module{Output,Dependencies}File` to avoid
`.ifc` and `.module.json` collisions.

Fixes: #25038
2023-06-28 06:43:10 -04:00
Brad King
f58c7659d8 Merge topic 'vs-sdk-selection' into release-3.27
a4d532e998 VS: Restore Windows SDK selection with platform in generator name

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8583
2023-06-23 10:52:48 -04:00
Andreas Weis
d90a61d671 VS: Make C++ module BMIs public by default for shared libraries
Enable the `AllProjectBMIsArePublic` option for shared libraries in the
VS project files when building with C++20 modules support.
2023-06-22 14:22:56 -04:00
Brad King
a4d532e998 VS: Restore Windows SDK selection with platform in generator name
Refactoring in commit e259063b0a (VS: Defer Windows SDK selection until
CMAKE_GENERATOR_PLATFORM is known, 2023-03-31, v3.27.0-rc1~206^2~5)
accidentally dropped the Windows SDK selection code path for VS
generators named with the old-style platform suffix.

Fixes: #25007
2023-06-22 11:22:08 -04:00
Brad King
0cd5300665 CMake 3.27.0-rc3 2023-06-20 13:11:25 -04:00
Marc Chevrier
1cfaed0684 list(): restore SUBLIST behavior
Fixes: #25002
2023-06-16 15:14:03 +02:00
Brad King
66f7d9e6e0 CMake 3.27.0-rc2 2023-06-12 13:24:29 -04:00
Brad King
a70fe8ec82 Merge topic 'add_test-empty-args' into release-3.27
1df3287bf6 add_test: Restore support for empty test arguments

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8551
2023-06-12 06:41:40 -04:00
Brad King
5741965586 Merge topic 'Makefiles-safer-COLOR-usage' into release-3.27
8195aa3026 Makefiles: quote `$(COLOR)` expansions

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8548
2023-06-09 09:58:25 -04:00
Marc Chevrier
1df3287bf6 add_test: Restore support for empty test arguments
This was regressed by refactoring in commit e08ba229ee (CMake code rely
on cmList class for CMake lists management (part. 1), 2023-04-14,
v3.27.0-rc1~174^2).  Fix it and add a test case.

Fixes: #24986
2023-06-09 09:47:52 -04:00
Brad King
5b39465ff1 CMake 3.27.0-rc1 2023-06-08 11:10:11 -04:00
Ben Boeckel
8195aa3026 Makefiles: quote $(COLOR) expansions
This handles the case where `COLOR` is set to some ANSI-like color
sequence in the ambient environment. These sequences tend to include `;`
which terminates the command and tries to use the next component
(typically an integer, possibly with a trailing `m`) with errors like:

    /bin/sh: line 1: 2: command not found
    /bin/sh: line 1: 255: command not found
    /bin/sh: line 1: 221: command not found
    /bin/sh: line 1: 255m: command not found

Also add a test that sets `COLOR` in the environment which affects the
generated Makefiles behavior.

See: https://discourse.cmake.org/t/cmake-failing-gcc-compiler-checks/8277
2023-06-08 11:05:11 -04:00
Brad King
aebf8ad1aa Merge topic 'cmcldeps-rc' into release-3.27
0e1abf7afa cmcldeps: Avoid passing /nologo more than once to RC compiler
f694e8d9c8 cmcldeps: Do not pass linker flags to cl
8600fb263b cmcldeps: Remove unused C and CXX support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8541
2023-06-08 10:45:45 -04:00
Brad King
0e1abf7afa cmcldeps: Avoid passing /nologo more than once to RC compiler
`rc /nologo /nologo ...` fails:

    fatal error RC1106: invalid option: -ologo

Fixes: #24974
Inspired-by: Benjamin Buch <benjamin.buch@technoteam.de>
2023-06-07 10:12:57 -04:00
Benjamin Buch
f694e8d9c8 cmcldeps: Do not pass linker flags to cl
Avoid cl `Command line warning D9035`.

Fixes: #24906
Co-authored-by: Brad King <brad.king@kitware.com>
2023-06-07 10:05:39 -04:00
Benjamin Buch
8600fb263b cmcldeps: Remove unused C and CXX support
We never set `CMAKE_NINJA_CMCLDEPS_{C,CXX}` anymore.
2023-06-07 08:16:40 -04:00
Brad King
c01091d2cf Begin 3.27 release versioning 2023-06-06 13:36:58 -04:00
Kyle Edwards
af69d59b09 Merge topic 'verify-interface-header-sets-skip-linting'
36ec89639a VERIFY_INTERFACE_HEADER_SETS: Skip header files that have SKIP_LINTING

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8540
2023-06-06 10:51:27 -04:00
Kyle Edwards
36ec89639a VERIFY_INTERFACE_HEADER_SETS: Skip header files that have SKIP_LINTING
Fixes: #24972
2023-06-06 10:45:22 -04:00
Brad King
53d9234395 Merge topic 'Apple-tbd-runpath-handling'
bfa5b430b3 Apple text-based stubs: ensure runpath is correctly defined

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8536
2023-06-06 09:55:34 -04:00
Kyle Edwards
0eada92663 Merge topic 'cmuvprocesschain-status-getexception'
154fe00ca5 cmUVProcessChain: Add Status::GetException() method

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8528
2023-06-06 08:41:58 -04:00
Kitware Robot
722c801da7 CMake Nightly Date Stamp 2023-06-06 00:01:11 -04:00
Kyle Edwards
154fe00ca5 cmUVProcessChain: Add Status::GetException() method 2023-06-05 11:27:45 -04:00
Brad King
3760ac9845 Merge topic 'file-api-query-command'
99b2ccf80d cmake_file_api: New project command

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8530
2023-06-05 09:45:02 -04:00
Brad King
da6bb1621d Merge topic 'hip-usr-include'
f4d28d9e27 HIP: Fix implicit include directory detection under /usr/include

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8534
2023-06-05 06:42:37 -04:00
Brad King
7838ae4fd8 Merge topic 'ctest-timeout-signal'
54c5654f7d ctest: Optionally terminate tests with a custom signal on timeout
e38c05688e CTest/cmProcess: Adopt field tracking reason for the process timeout
25c1468314 cmCTestTestHandler: Remove outdated comment
41e8507ab7 IWYU: Add mapping for bits/chrono.h to chrono

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8472
2023-06-05 06:33:36 -04:00
Craig Scott
99b2ccf80d cmake_file_api: New project command
Projects can use the new command to request file API replies for the current
run. No query files are generated, the query is tracked internally. Replies are
created in the file system at generation time in the usual way.

Fixes: #24951
2023-06-05 06:20:50 -04:00
Kitware Robot
8f8a5e56f4 CMake Nightly Date Stamp 2023-06-05 00:01:35 -04:00
Marc Chevrier
bfa5b430b3 Apple text-based stubs: ensure runpath is correctly defined
This is a complement to !8204.
2023-06-04 15:29:42 +02:00
Kitware Robot
326bd503ed CMake Nightly Date Stamp 2023-06-04 00:01:08 -04:00
Kitware Robot
b0cda51ff1 CMake Nightly Date Stamp 2023-06-03 00:01:09 -04:00
Cordell Bloor
f4d28d9e27 HIP: Fix implicit include directory detection under /usr/include
The `CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES` are computed using
`try_compile` in `CMAKE_DETERMINE_COMPILER_ABI`, but the implicit
include directories are not known during that `try_compile`.  This can
be a problem when the HIP runtime include path is `/usr/include`,
because the runtime include path is always added to the userDirs and the
compiler automatically includes standard library headers via
`__clang_hip_runtime_wrapper.h`.

Issue: #24562
2023-06-02 11:25:06 -04:00
Brad King
a67743392b Merge topic 'cxxmodules-remove-dyndep-variable'
0183e1bca3 cxxmodules: remove `CMAKE_EXPERIMENTAL_CXX_MODULE_DYNDEP` variable

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !8524
2023-06-02 09:39:28 -04:00
Brad King
54c5654f7d ctest: Optionally terminate tests with a custom signal on timeout
CTest normally terminates test processes on timeout using `SIGKILL`.
Offer tests a chance to exit gracefully, on platforms supporting POSIX
signals, by setting `TIMEOUT_SIGNAL_{NAME,GRACE_PERIOD}` properties.

Fixes: #17288
2023-06-02 06:51:13 -04:00
Kitware Robot
17a43ee192 CMake Nightly Date Stamp 2023-06-02 00:01:16 -04:00
Ben Boeckel
0183e1bca3 cxxmodules: remove CMAKE_EXPERIMENTAL_CXX_MODULE_DYNDEP variable
It is now subsumed by the UUID setting completely.
2023-06-01 14:43:26 -04:00
Brad King
f6435f799e Merge topic 'automoc-moc-options-test'
1f4b374d6e cmQtAutoGenInitializer: Reduce string copies
b6f66b445a cmQtAutoGenInitializer: Remove no-op calls
55d93bdabf cmQtAutoGenInitializer: Improve const correctness
feb56a666f cmTarget: Improve const correctness of AddUtility
5e513e562f Help: Add AUTOMOC_MOC_OPTIONS example
5380ad9d58 Tests: Add test for AUTOMOC_MOC_OPTIONS

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8523
2023-06-01 11:19:19 -04:00
Kyle Edwards
99e80ea0ac Merge topic 'cmuvprocesschain-finished'
22e5775cde cmUVProcessChain: Add Finished() method

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8526
2023-06-01 10:30:02 -04:00
Brad King
64a4d1f104 Merge topic 'remove-header-unit-fileset-type'
7b62a83c6f cxxmodules: update the experimental UUID
6ff5cdc533 cxxmodules: remove support for `CXX_MODULE_HEADER_UNITS` filesets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8510
2023-06-01 09:53:34 -04:00
Brad King
54a4aa5779 Merge topic 'cuda-ipo-arch'
45584508fa CUDA/NVIDIA: fix LTO with explicit architectures

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Raul Tambre <raul@tambre.ee>
Merge-request: !8508
2023-06-01 09:49:15 -04:00
Brad King
aa3675d281 Merge topic 'cmake-compile-no-warning-as-error'
da27ff1e96 Preserve --compile-no-warning-as-error in automatic CMake re-runs
e0b48284a1 Xcode: Internally uses -S instead of -H to specify source directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !8522
2023-06-01 09:45:56 -04:00
Kitware Robot
1606184460 CMake Nightly Date Stamp 2023-06-01 00:01:18 -04:00
Kyle Edwards
22e5775cde cmUVProcessChain: Add Finished() method 2023-05-31 17:21:52 -04:00