df9c4b1872 find_package: Use <PACKAGENAME>_ROOT variables as search prefixes
4da27a73bd Help: Document <PackageName>_ROOT variable ordering using an ordered list
bfeb16bd5b cmFindPackageCommand: Refactor CMP0074 logic to de-duplicate lookups
c0fcd07e6f cmFindPackageCommand: Factor out methods for package root stack management
acd9636d9d cmSystemTools: Add helpers for reading and parsing PATH env vars
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !8240
This avoids the need to separately execute `mt.exe` to perform the
embedding of manifests into the output for non-incremental links. The
primary motivation for this change is that this separate execution of
`mt.exe` to embed manifests is known to cause intermittent failures due
to AV/security scanning.
The only change in behavior is that any linker generated manifest will
no longer be output as a separate manifest file alongside the output
file.
Fixes: #24531
Extend commit eb35d8884b (find_package: Use PackageName_ROOT variables
as search prefixes, 2018-03-15, v3.12.0-rc1~349^2) to also check
upper-case `<PACKAGENAME>_ROOT` variables. Add policy `CMP0144` to
enable the behavior in a compatible way.
Fixes: #24403
The VersionCompare() function converted version components to
'unsigned long' prior to comparing them. Any version components
too large for 'unsigned long' were treated as equal to ULONG_MAX.
This impacted operators like VERSION_GREATER, VERSION_LESS, and
VERSION_EQUAL. The new code does not limit the length of the
version components for valid comparisons.
With this patch, cmake now generates the targets once for each
config into the kate project file, so users can build the targets
for all configs with this generator.
Add `Green Hills MULTI` to the list of generators checked for the
`COMPILE_LANGUAGE`, `COMPILE_LANG_AND_ID`, `LINK_LANGUAGE`, and
`LINK_LANG_AND_ID` generator expressions, since these are supported by
the generator.
Fixes: #24262
In commit 8527f42b96 (Xcode: Explicitly disable deprecated user include
path feature, 2023-01-31, v3.26.0-rc1~7^2) we dropped the Xcode build
setting `USE_HEADERMAP = NO` because Xcode 14's "Build Documentation"
feature (`xcodebuild RUN_DOCUMENTATION_COMPILER=YES`) fails in some
cases without header maps. However, enabling header maps causes Xcode
to add `-iquote .../foo.hmap` and `-I .../bar.hmap` flags that can
change the intended header file search order based on the contents of
the header maps. This can break existing projects. Restore the
`USE_HEADERMAP = NO` setting to fix the header file search order.
Further investigation will be needed to resolve the problematic cases
with the Xcode 14 "Build Documentation" feature. Meanwhile projects
encountering such cases can set the `XCODE_ATTRIBUTE_USE_HEADERMAP`
target property to `YES` themselves.
Fixes: #24418
Issue: #24379
Add CMake variable `CMAKE_ADD_CUSTOM_COMMAND_DEPENDS_EXPLICIT_ONLY` to enable
option `DEPENDS_EXPLICIT_ONLY` on all uses of `add_custom_command`.
Fixes: #17097
dadaa28638 cmGeneratorTarget: synthetic targets don't have output either
bde9d4ad01 cmCommonTargetGenerator: also consider synthetic targets
c97de1047f cmMakefile: add support for a "synthesized" target
1d0426f642 cmTarget: make Visibility an `enum class`
5b58695321 cmTarget: store visibility as an `enum` rather than bools
Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !8203
The "extra" generators were created in CMake's early years to provide
support for users of specific IDEs by directly generating their project
files alongside make or ninja files. Nowadays the file-api provides a
more generic, maintainable, well-tested, and robust way for IDEs to view
CMake project build trees. Deprecate the legacy "extra" generators to
encourage the corresponding IDEs to use the file-api.
Fixes: #19090
It is a normal target, but will end up copying its internals from
another target. Keep track of this state so that such copying can only
occur when intended.