Commit Graph

36115 Commits

Author SHA1 Message Date
Brad King
e782811cfe execute_process: Change default ENCODING to UTF-8
Windows is heading toward making UTF-8 the preferred MBCS.  As CMake's
internal encoding, `UTF-8` is effectively equivalent to `NONE`, which
was CMake's behavior prior to 3.15's accidental change to `AUTO`.
Behavior of `ENCODING UTF-8` is independent of CMake's internal
encoding, making it in principle a better default than `NONE`.

Add policy CMP0176 for compatibility and to document the default's
history.

Fixes: #26262
2024-09-16 06:37:46 -04:00
Brad King
9a4533405b cmExecuteProcessCommand: Explicitly ignore unknown ENCODING values
The logic did this implicitly before.  Make it easier to follow.
2024-09-16 06:37:15 -04:00
Brad King
7b5f9f1fa2 Merge topic 'ninja-depfile-quoting'
b11323f1e4 Ninja: Fix depfile binding with spaces in path
ad66be9943 cmNinjaTargetGenerator: Factor out helper to add depfile bindings
269c3a13c8 cmNinjaTargetGenerator: Reduce DEP_FILE binding duplication
48ced5fb12 Tests/RunCMake/BuildDepends: Enable more depfile cases with Ninja
b751a857cc Tests/RunCMake/BuildDepends: Simplify CustomCommandDepends case
006891dab9 Tests/RunCMake/BuildDepends: Prepare CompileDepends check for multiple targets
0915320ddf Tests/RunCMake/BuildDepends: Simplify CompileDepends case
24fbfa915c Tests/RunCMake/BuildDepends: Simplify LinkDepends case

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !9812
2024-09-16 06:20:17 -04:00
Kitware Robot
21e16fa4fa CMake Nightly Date Stamp 2024-09-16 00:01:46 -04:00
Kitware Robot
b346afce4f CMake Nightly Date Stamp 2024-09-15 00:01:18 -04:00
Kitware Robot
0cd71e27c2 CMake Nightly Date Stamp 2024-09-14 00:02:10 -04:00
Brad King
844417294b Merge topic 'file-REAL_PATH-warn-non-existing'
00c1161b01 file(REAL_PATH): Warn on non-existing paths

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9806
2024-09-13 09:25:44 -04:00
Brad King
b11323f1e4 Ninja: Fix depfile binding with spaces in path
In build statements we use a single `DEP_FILE = ...` binding that is
shared between `depfile = $DEP_FILE` and `command = ... $DEP_FILE ...`
bindings in the corresponding rule.  In cases that the command's shell
argument needs quoting, add a separate `depfile = ...` binding to the
build statement to express the depfile path without quoting.  Otherwise
`ninja` tries to open a file path that contains literal quotes.

Fixes: #26287
2024-09-13 09:04:32 -04:00
Kitware Robot
07f0d602c0 CMake Nightly Date Stamp 2024-09-13 00:01:17 -04:00
Brad King
ad66be9943 cmNinjaTargetGenerator: Factor out helper to add depfile bindings 2024-09-12 12:24:48 -04:00
Brad King
269c3a13c8 cmNinjaTargetGenerator: Reduce DEP_FILE binding duplication 2024-09-12 12:24:48 -04:00
Alex Overchenko
00c1161b01 file(REAL_PATH): Warn on non-existing paths
The command is documented to work only for cases that the referenced
path exists.

Fixes: #26260
2024-09-12 08:20:29 -04:00
Brad King
d3518bbb17 Merge topic 'vs-output-name-net-sdk'
66bd326e28 VS: Use OUTPUT_NAME in DOTNET_SDK projects

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9808
2024-09-12 08:12:51 -04:00
Brad King
b91ea1b368 Merge topic 'file-archive-workdir'
d8a9aabd24 file(ARCHIVE_CREATE): add WORKING_DIRECTORY option
d65b5a8e03 Help: Format file(ARCHIVE*) options as definition lists

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9803
2024-09-12 08:10:54 -04:00
Brad King
2321b88edf Merge topic 'cpack-ifw-product-images'
5b8fa21512 Tests: Add a test covering the CPack IFW Generator
3331c7032f CPack/IFW: Add option for ProductImages URLs
d58f90f628 CPack/IFW: Actually ignore missing ProductImages
3c214f2638 CPack/IFW: Fix generation of ProductImages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9798
2024-09-12 08:09:32 -04:00
Kitware Robot
8ae543d85c CMake Nightly Date Stamp 2024-09-12 00:01:14 -04:00
Yuri Witte
d8a9aabd24 file(ARCHIVE_CREATE): add WORKING_DIRECTORY option
Fixes: #25260
Issue: #21653
2024-09-11 09:52:32 -04:00
Brad King
ac410c7add Merge topic 'genex-tco-subgraph'
4a11772618 GenEx: Limit TARGET_PROPERTY transitive closure optimization to subgraphs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Acked-by: Robert Maynard <robertjmaynard@gmail.com>
Merge-request: !9789
2024-09-11 09:33:28 -04:00
Brad King
dd023d9707 Merge topic 'add_custom_command-arg-handling'
ec519f3e97 add_custom_command: Validate arguments more rigorously
8dc8be0884 AndroidTestUtilities: Remove DEPENDS that was being silently ignored
316840b430 Tests: Add missing POST_BUILD to custom commands
f5f80305ef ExternalProject: Ensure keywords requiring an argument have one

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !9785
2024-09-11 09:32:24 -04:00
Brad King
6971e816ce Merge topic 'parallel-install-bugfix'
a980418f7b cmake --install: Fix concurrency level of parallel install

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !9802
2024-09-11 09:27:45 -04:00
Brad King
42556539d7 Merge topic 'update-kwsys'
d195e2c9c8 Merge branch 'upstream-KWSys' into update-kwsys
5293b8ded0 KWSys 2024-09-10 (ac1555b4)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9805
2024-09-11 09:26:15 -04:00
Julien Marrec
3331c7032f CPack/IFW: Add option for ProductImages URLs
Add a `CPACK_IFW_PACKAGE_PRODUCT_IMAGE_URLS` variable for them.
2024-09-11 08:44:09 -04:00
Julien Marrec
d58f90f628 CPack/IFW: Actually ignore missing ProductImages 2024-09-11 08:10:52 -04:00
Calum Robinson
66bd326e28 VS: Use OUTPUT_NAME in DOTNET_SDK projects
Fixes: #26285
2024-09-11 12:25:08 +01:00
Kitware Robot
bc5f3ed586 CMake Nightly Date Stamp 2024-09-11 00:02:42 -04:00
Julien Marrec
3c214f2638 CPack/IFW: Fix generation of ProductImages
Entries of `CPACK_IFW_PACKAGE_PRODUCT_IMAGES` each need their own
`ProductImage element.

Fixes: #26268
2024-09-10 14:31:47 +02:00
Brad King
d195e2c9c8 Merge branch 'upstream-KWSys' into update-kwsys
# By KWSys Upstream
* upstream-KWSys:
  KWSys 2024-09-10 (ac1555b4)
2024-09-10 07:49:38 -04:00
Michael Herwig
4a11772618 GenEx: Limit TARGET_PROPERTY transitive closure optimization to subgraphs
Fixes: #25728
2024-09-10 13:24:24 +02:00
Kitware Robot
605ecca2a4 CMake Nightly Date Stamp 2024-09-10 00:01:23 -04:00
Craig Scott
ec519f3e97 add_custom_command: Validate arguments more rigorously
Add a new CMP0175 policy to preserve backward compatibility
for projects that were using unsupported keywords or arguments.

Fixes: #26096, #21089, #18976
2024-09-10 08:19:09 +10:00
Martin Duffy
a980418f7b cmake --install: Fix concurrency level of parallel install
- Increment the number of currently working installs
- Call uv_run only once
2024-09-09 17:36:08 -04:00
Kitware Robot
6c120379df CMake Nightly Date Stamp 2024-09-09 00:06:27 -04:00
Kitware Robot
26791532be CMake Nightly Date Stamp 2024-09-08 00:01:12 -04:00
Kitware Robot
9f150960ad CMake Nightly Date Stamp 2024-09-07 00:01:15 -04:00
Brad King
a53e8e4e81 Merge topic 'vs-instance'
e801d2b243 VS: Make CMAKE_GENERATOR_INSTANCE usable without VS Installer

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9794
2024-09-06 11:35:08 -04:00
Kitware Robot
2001edfef7 CMake Nightly Date Stamp 2024-09-06 00:01:20 -04:00
Brad King
9c5f6d22f3 Merge topic 'windows-kernel-mode-driver-includes'
b151bcfc9e WindowsKernelModeDriver: Add WDK include and link paths on MSVC

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9705
2024-09-05 09:21:35 -04:00
Brad King
2daeb0b504 Merge topic 'build-databases'
e77655555c cmExperimental: gate build database support behind a flag
23cbeb5035 ci: enable `build_database` CXXModules tests
6863c1d823 Tests/CXXModules: add tests for module commands
123107c1a4 Tests/CXXModules: add support for running targets under a given config
438038b5e1 Tests/CXXModules: support building specific targets of example trees
84bc710d84 cmGlobalGenerator: generate build database files for targets
670f753f24 cmDyndepCollation: write build database metadata
dcf9a66ffe cxxmodules: plumb control data for exporting build databases
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9708
2024-09-05 09:20:23 -04:00
Brad King
cc527ab583 Merge topic 'fix-Wdeprecated-redundant-constexpr-static-def'
1650683c9d cmExportPackageInfoGenerator: Fix -Wdeprecated-redundant-constexpr-static-def

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9792
2024-09-05 09:18:20 -04:00
Brad King
def3073d46 Merge topic 'update-kwsys'
7016a75b87 Merge branch 'upstream-KWSys' into update-kwsys
65ecc7b190 KWSys 2024-09-03 (9c5f00b7)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !9790
2024-09-05 09:15:49 -04:00
Kitware Robot
3bf4bcba11 CMake Nightly Date Stamp 2024-09-05 00:01:24 -04:00
huangqinjin
e801d2b243 VS: Make CMAKE_GENERATOR_INSTANCE usable without VS Installer
On Windows and Wine, both the COM interface and `vswhere` might not be
available.  `CMAKE_GENERATOR_INSTANCE` is still supposed to work since
commit 195d47e213 (VS: Allow CMAKE_GENERATOR_INSTANCE to specify
portable instance, 2021-10-21, v3.23.0-rc1~452^2).

Issue: #21639
2024-09-04 14:14:11 -04:00
Brad King
1650683c9d cmExportPackageInfoGenerator: Fix -Wdeprecated-redundant-constexpr-static-def
In commit 3d52d70b84 (export: Add initial CPS support, 2024-07-26) we
added a static definition of a `constexpr` member to help older
AppleClang and SunPro linkers.  This is deprecated by C++17 and Clang
now warns about it, so preserving the approach would require complex
conditions. There is no significant benefit to `constexpr` here, so use
a traditional file-scoped definition instead.
2024-09-04 08:37:15 -04:00
Brad King
7b51809d9a Merge topic 'msvc-v100-manifest-tooling'
09a47c7972 MSVC: Restore support for non-incremental linking with v100 toolset and older

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !9783
2024-09-04 08:11:42 -04:00
Kitware Robot
7b59f55b31 CMake Nightly Date Stamp 2024-09-04 00:01:44 -04:00
Joseph Snyder
b151bcfc9e WindowsKernelModeDriver: Add WDK include and link paths on MSVC
Detect Windows Kernel-Mode Driver include directories and library search
paths from the WDK command-line environment.  Require toolchain files to
specify the KMDF target version via a new variable.

Since this changes the behavior of the WindowsKernelModeDriver
experimental feature, update its UUID.
2024-09-03 11:10:35 -04:00
Brad King
7016a75b87 Merge branch 'upstream-KWSys' into update-kwsys
# By KWSys Upstream
* upstream-KWSys:
  KWSys 2024-09-03 (9c5f00b7)
2024-09-03 11:04:29 -04:00
Rüdiger Ihle
09a47c7972 MSVC: Restore support for non-incremental linking with v100 toolset and older
Since commit 0b552eb877 (MSVC: Embed manifests directly for
non-incremental vs_link_exe links, 2023-02-20, v3.27.0-rc1~438^2) we use
`/MANIFEST:EMBED`, but that is not supported by older MSVC linkers.
Restore use of the standalone manifest tool.

Update `Tests/MSManifest` to recognize `dpiAwareness` in the manifest
content as written by MSVC v100 tooling.

Fixes: #26179
2024-09-03 10:58:28 -04:00
Ben Boeckel
e77655555c cmExperimental: gate build database support behind a flag
Given that the feature currently only supports C++ sources and is not
formally accepted by ISO yet, gate it behind a flag.
2024-09-03 10:05:40 -04:00
Kitware Robot
fa69f7587e CMake Nightly Date Stamp 2024-09-03 00:01:29 -04:00