summaryrefslogtreecommitdiffstats
path: root/Source
Commit message (Collapse)AuthorAgeFilesLines
* cmFindPackageCommand: Drop ComputeIfDebugModeWanted overloadBrad King2022-02-102-9/+2
| | | | | | The overload for `--debug-find-pkg` has the same signature as the base class method for `--debug-find-var`. To avoid confusion, drop the overload and inline it its only call site.
* Merge topic 'restore-target-export-includes' into release-3.23Brad King2022-02-106-13/+23
|\ | | | | | | | | | | | | | | 83d79636bf install(TARGETS): Restore per-export INCLUDES DESTINATION Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !6969
| * install(TARGETS): Restore per-export INCLUDES DESTINATIONEugene Shalygin2022-02-096-13/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit 55e4753bbb (Refactor cmTargetExport removing InterfaceIncludeDirecories, 2021-07-20, v3.22.0-rc1~337^2~1) the storage of `INCLUDES DESTINATION` was moved into each target. However, a target may be installed in multiple exports, and their `INCLUDES DESTINATION` should not be mixed. Convert the IncludeDirectoriesEntries vector to a map and modify access function to store the directories lists with respect to cmExportTarget object. This fixes error when the same target is exported more than once via different exports and each for consequent export its include directories list grows. Add a test for this case. Fixes: #23183
| * Merge topic 'message-flush' into release-3.22Brad King2022-01-281-2/+2
| |\ | | | | | | | | | | | | | | | | | | 634587e322 message: Restore explicit flushing of messages on stderr Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6913
| * \ Merge topic 'nmake-rsp-encoding' into release-3.22Brad King2022-01-271-2/+15
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | d5ee6d50ee NMake: Use UTF-8 BOM in response files only with MSVC tooling cab631c2e2 NMake: Document response file encoding heuristic in a comment Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6905
| * | | CMake 3.22.2v3.22.2Brad King2022-01-251-1/+1
| | | |
* | | | CMake 3.23.0-rc1v3.23.0-rc1Brad King2022-02-081-1/+1
| | | |
* | | | Merge topic 'dotnet_sdk' into release-3.23Brad King2022-02-085-34/+154
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5cdd774d51 VS: Handle build target correct for .NET SDK style projects with Any CPU 309191052c VS: Set Visual Studio versions read out from solution file f7791698cb VS: Allow setting output directory in .NET SDK style projects Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6944
| * | | | VS: Handle build target correct for .NET SDK style projects with Any CPUFlorian Schweiger2022-02-074-32/+119
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Extend Visual Studio solution parser for reading build target * Map solution build target to project build target (especially for Any CPU) * Use C++ <optional> template instead of pointer return value for cmSlnData::GetProjectByGUID
| * | | | VS: Set Visual Studio versions read out from solution fileFlorian Schweiger2022-02-072-2/+24
| | | | |
| * | | | VS: Allow setting output directory in .NET SDK style projectsFlorian Schweiger2022-02-071-0/+11
| | | | |
* | | | | Merge topic 'vs-simplify-pch' into release-3.23Brad King2022-02-041-9/+16
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dd1e2cc80c VS: Simplify generation of per-source PCH settings Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6950
| * | | | | VS: Simplify generation of per-source PCH settingsBrad King2022-02-031-9/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid looking up the PCH create/use flags just to map them through flag tables back to the `.vcxproj` settings. Instead, simply generate the PCH settings directly for each source file. Since commit 9df1f33c9a (VisualStudio: move PCH rules to projects when possible., 2020-10-15, v3.20.0-rc1~638^2) we already do this for the target-wide PCH settings.
* | | | | | Replace DEVEL_CMAKE_VERSION with literal 3.23 release versionBrad King2022-02-041-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was accidentally left out of commit 736663deed (Begin 3.23 release versioning, 2022-02-03). The step is documented as part of the release branching process in the CMake Maintainer Guide `Help/dev/maint.rst`.
* | | | | | Begin 3.23 release versioningBrad King2022-02-031-3/+3
|/ / / / /
* | | | | Merge topic 'cmake-ignore-prefix-path'Brad King2022-02-036-38/+114
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 201d8c4298 find_*(): Add CMAKE_IGNORE_PREFIX_PATH variable bd805a51ae Refactor: Keep track of prefixes in cmSearchPath Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !6880
| * | | | | find_*(): Add CMAKE_IGNORE_PREFIX_PATH variableKyle Edwards2022-02-026-12/+61
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: #20878
| * | | | | Refactor: Keep track of prefixes in cmSearchPathKyle Edwards2022-02-024-27/+54
| | | | | |
* | | | | | Merge topic 'cmake-presets-configure-preset-reachability'Brad King2022-02-032-3/+14
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | c18409cdac CMakePresets.json: Ensure configurePreset is reachable from current file Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6937
| * | | | | | CMakePresets.json: Ensure configurePreset is reachable from current fileKyle Edwards2022-02-022-3/+14
| |/ / / / /
* | | | | | CMake Nightly Date StampKitware Robot2022-02-031-1/+1
|/ / / / /
* | | | | Merge topic 'cuda_generic_arch_all'Brad King2022-02-021-8/+16
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 8f64df0a7c CUDA: Generic all and all-major support Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Alex <leha-bot@yandex.ru> Merge-request: !6816
| * | | | | CUDA: Generic all and all-major supportRaul Tambre2022-02-011-8/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 14d8a276 (CUDA: Support nvcc 11.5 new -arch=all|all-major flags, 2021-08-17) added all and all-major options to CUDA_ARCHITECTURES. These are fairly generic and likely to see real-world use by distributors. Thus it's desirable to support these also for Clang and older NVCC versions. The supported architectures are dependent on the toolkit version. We determine the toolkit version prior to compiler detection. For NVCC we get the version from the vendor identification output, but for Clang we need to invoke NVCC separately. The architecture information is mostly based on the Wikipedia list with the earliest supported version being CUDA 7.0. This could be documented and expanded in the future to allow projects to query CUDA toolkit version and architecture information. For Clang we additionally constrain based on its support. Additionally the architecture mismatch detection logic is fixed, improved and updated for generic support: * Commit 01428c55 (CUDA: Fail fast if CMAKE_CUDA_ARCHITECTURES doesn't work during detection, 2020-08-29) enabled CMAKE_CUDA_COMPILER_ID_REQUIRE_SUCCESS if CMAKE_CUDA_ARCHITECTURES is specified. This results in CMakeDetermineCompilerID.cmake printing the compiler error and our code for presenting the mismatch in a user-friendly way being useless. The custom logic seems preferable so go back to not enabling it. * Commit 14d8a276 (CUDA: Support nvcc 11.5 new -arch=all|all-major flags, 2021-08-17) tried to support CMP0054 but forgot to add x to the interpolated result. Thus the conditions would always evaluate to false. This is fixed as a byproduct of removing NVIDIA specific checks, improving the error message and replacing architectures_mode with a simpler architectures_explicit. Visual Studio support omits testing the flags during detection due to complexities in determining the toolkit version when using it. A long-term proper implementation would be #23161. Implements #22860.
* | | | | | Merge topic 'dotnet_ref_in_sdk'Brad King2022-02-021-0/+1
|\ \ \ \ \ \ | |_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5ee3154f65 VS: .Net SDK Style projects can add Reference to dlls Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6932
| * | | | | VS: .Net SDK Style projects can add Reference to dllsSumit Bhardwaj2022-02-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When support for `DOTNET_SDK` was added, only a minimal set of options were built in. Based on user feedback, support for reference to dlls (not just projects) is needed. That support is added here. Fixes: #23166
* | | | | | CMake Nightly Date StampKitware Robot2022-02-021-1/+1
| | | | | |
* | | | | | Merge topic 'refactor-find-package-cmake-ignore-path'Brad King2022-02-014-11/+28
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 11f97d1968 find_package(): Refactor CMAKE_[SYSTEM_]IGNORE_PATH 30e5c1d92b find_package(): Add tests for CMAKE_IGNORE_PATH Acked-by: Kitware Robot <kwrobot@kitware.com> Tested-by: buildbot <buildbot@kitware.com> Merge-request: !6918
| * | | | | | find_package(): Refactor CMAKE_[SYSTEM_]IGNORE_PATHKyle Edwards2022-01-314-11/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the old implementation, CMAKE_[SYSTEM_]IGNORE_PATH was handled in cmFindCommon. Move it into cmFindPackageCommand.
* | | | | | | Merge topic 'update-kwsys'Brad King2022-02-011-1/+1
|\ \ \ \ \ \ \ | |_|/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1e242a95d0 Merge branch 'upstream-KWSys' into update-kwsys 7d9204a7e2 KWSys 2022-01-31 (9fd1660a) Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6930
| * | | | | | Merge branch 'upstream-KWSys' into update-kwsysBrad King2022-01-311-1/+1
| | |/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | # By KWSys Upstream * upstream-KWSys: KWSys 2022-01-31 (9fd1660a)
* | | | | | CMake Nightly Date StampKitware Robot2022-02-011-1/+1
|/ / / / /
* | | | | Merge topic 'link-interface-direct'Brad King2022-01-3110-115/+375
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | f3ad061858 Add usage requirements to update direct link dependencies 193a999cd5 cmTarget: Add INTERFACE_LINK_LIBRARIES_DIRECT{,_EXCLUDE} backtrace storage 22d5427aa6 cmGeneratorTarget: Add LookupLinkItem option to consider own target name f3d2eab36a cmGeneratorTarget: Fix link interface caching of partial results d75ab9d066 cmGeneratorTarget: Clarify CMP0022 logic in ComputeLinkInterfaceLibraries f3e9e03fe0 cmGeneratorTarget: Simplify CMP0022 warning check 216aa14997 cmGeneratorTarget: Return early from ExpandLinkItems with no items 1bc98371d1 Tests: Remove unnecessary policy setting from ObjectLibrary test ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6886
| * | | | Add usage requirements to update direct link dependenciesBrad King2022-01-296-26/+203
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Link line construction starts with `LINK_LIBRARIES` and appends dependencies from the transitive closure of `INTERFACE_LINK_LIBRARIES`. Only the entries of `LINK_LIBRARIES` are considered direct link dependencies. In some advanced use cases, particularly involving static libraries and static plugins, usage requirements need to update the list of direct link dependencies. This may mean adding new items, removing existing items, or both. Add target properties to encode these usage requirements: * INTERFACE_LINK_LIBRARIES_DIRECT * INTERFACE_LINK_LIBRARIES_DIRECT_EXCLUDE Fixes: #22496
| * | | | cmTarget: Add INTERFACE_LINK_LIBRARIES_DIRECT{,_EXCLUDE} backtrace storageBrad King2022-01-292-0/+61
| | | | | | | | | | | | | | | | | | | | These properties will be given meaning by later commits.
| * | | | cmGeneratorTarget: Add LookupLinkItem option to consider own target nameBrad King2022-01-292-7/+14
| | | | |
| * | | | cmGeneratorTarget: Fix link interface caching of partial resultsBrad King2022-01-291-16/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `GetLinkInterface` and `GetLinkInterfaceLibraries` cache their results to avoid repeating work. In the case that the result does not depend on the "head" target, they re-use results computed from the first call with any "head" target. However, if `GetLinkInterfaceLibraries` is called first, then not all of the link interface is populated. If `GetLinkInterface` is later called, it needs to finish populating the link interface even if a partially completed interface was cached.
| * | | | cmGeneratorTarget: Clarify CMP0022 logic in ComputeLinkInterfaceLibrariesBrad King2022-01-291-56/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Follow up commit 1d709ea2f5 (cmGeneratorTarget: Propagate backtraces from INTERFACE_LINK_LIBRARIES, 2021-12-15), which made the logic a bit more complicated due to having backtraces for CMP0022 NEW behavior.
| * | | | cmGeneratorTarget: Simplify CMP0022 warning checkBrad King2022-01-291-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 1d709ea2f5 (cmGeneratorTarget: Propagate backtraces from INTERFACE_LINK_LIBRARIES, 2021-12-15) we can use the special storage of the property directly.
| * | | | cmGeneratorTarget: Return early from ExpandLinkItems with no itemsBrad King2022-01-291-0/+3
| | | | |
| * | | | PCH: Clear link interface cache when adding PCH object to itBrad King2022-01-293-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On platforms using `CMAKE_LINK_PCH`, the implementation of `PRECOMPILE_HEADERS_REUSE_FROM`, when re-using the PCH from one object library in another, adds a PCH object file to the link interface. Clear any cached link interface to ensure it is used.
| * | | | cmLinkItem: Clarify name of CMP0027 check memberBrad King2022-01-293-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The only purpose of `cmLinkImplItem`'s `FromGenex` member is to decide whether to check CMP0027. That won't be needed for link items added by new interfaces in the future. Clarify the name to indicate that we do not always need to know if the item came from a generator expression.
| * | | | cmGeneratorExpressionDAGChecker: Re-order EvaluatingLinkLibraries conditionBrad King2022-01-291-3/+3
| | | | | | | | | | | | | | | | | | | | Place the modern properties first.
* | | | | Merge topic 'shorter-obj'Brad King2022-01-311-12/+18
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5f8c5657a9 Shorten object name even if still longer than CMAKE_OBJECT_PATH_MAX Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !6915
| * | | | | Shorten object name even if still longer than CMAKE_OBJECT_PATH_MAXNick Little2022-01-281-12/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some cases the shortened path may end up working in practice, even if it is over CMAKE_OBJECT_PATH_MAX, where the original path does not. If the original path is too long, do the MD5 substitution whenever it makes the path shorter. Retain the warning if it is still too long.
* | | | | | Merge topic 'update-kwsys'Brad King2022-01-312-3/+12
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | e83bb75160 Merge branch 'upstream-KWSys' into update-kwsys d01d634bc7 KWSys 2022-01-29 (389a74dc) Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6919
| * | | | | | Merge branch 'upstream-KWSys' into update-kwsysBrad King2022-01-292-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # By KWSys Upstream * upstream-KWSys: KWSys 2022-01-29 (389a74dc)
* | | | | | | CMake Nightly Date StampKitware Robot2022-01-311-1/+1
| | | | | | |
* | | | | | | CMake Nightly Date StampKitware Robot2022-01-301-1/+1
|/ / / / / /
* | | | | | Merge topic 'gcc12-warning'Brad King2022-01-291-2/+2
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ae101921e8 Source: Avoid gcc 12 compilation warning Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6916
| * | | | | | Source: Avoid gcc 12 compilation warningBrad King2022-01-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GCC 12 warns: warning: '%04d' directive output may be truncated writing between 4 and 11 bytes into a region of size 5 [-Wformat-truncation=] The surrounding logic guarantees the formatted integer will never be more than 4 bytes, but it doesn't hurt to use a larger buffer. This GCC behavior is documented: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104012#c5