Fix two minor issues with how default configurations are set from CPS
packages. First, imported configurations were (appropriately) being
converted to upper case, but default configurations weren't. Second,
default configurations were being set only after importing components
from the root package configuration file, resulting in configurations
specified in the root file preceding the default configurations.
Modify how CMake handles required components of a CPS transitive
dependency to not pass them as COMPONENTS if a CMake-script package is
found as the resolved dependency. This is necessary as many CMake-script
package description files do not treat component requests as target
requests (which, in CPS-land, they effectively are), but do implement
logic to mark themselves 'not found' if requested components are
missing. As a result, passing in the required targets as required
components is likely to cause the dependency to be spuriously not found
if it is only available via a CMake-script package configuration file.
Fix this by introducing a new 'required targets' concept, and by passing
CPS component requirements as both required targets and optional
components. The latter serves as a hint for packages that might provide
only a subset of themselves. The former is used to post-validate a
CMake-script package, or is folded on-the-fly into required components
when considering CPS packages.
Note that this functionality is not exposed to the user at this time,
and is only used when resolving transitive dependencies for a CPS
package.
5a36d0c9e7 Ninja: Fix regression with a large number of subdirectories
a30cf4a66a Tests/RunCMake/Configure: Split ninja-specific RerunCMake case
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10420
Since commit 8d83487e60 (CONTRIBUTORS: Factor contributors list out of
license file, 2025-03-02) the copyright line has reStructuredText
markup. Filter it out of the copyright line printed by `bootstrap`.
Since commit f50fb77a4f (Ninja: Regenerate when test or install scripts
are missing, 2024-10-29, v4.0.0-rc1~516^2) the list of paths we pass to
`ninja -t restat` scales with the number of project subdirectories.
Run it in blocks to avoid "command line too long" errors, particularly
on Windows.
Fixes: #26738
Split the test case from commit f50fb77a4f (Ninja: Regenerate when test
or install scripts are missing, 2024-10-29, v4.0.0-rc1~516^2) into a
dedicated case.
In commit 2f852580fb (CONTRIBUTORS: Improve formatting of
per-contributor hyperlinks, 2025-03-02) we accidentally added `mailto:`
on a few URLs that should use `https://` instead.
Reported-by: Rolf Eike Beer <eb@emlix.com>
283a48403f CPack/RPM: Fix detection of RPM support for weak dependencies
ab4e74ad0b CPack/RPM: Remove redundant conditions for presence of rpmbuild
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !10403
Add a missing `find_program` call to populate `RPM_EXECUTABLE`.
This was left out of two previous changes that intended to query
the `rpm` executable:
* In commit 9b53eca317 (CPack/RPM: Fix weak dep support, 2021-06-29,
v3.21.0-rc2~4^2), without `RPM_EXECUTABLE` the query always failed,
so we were concluding that weak dependencies are not supported even
when they are.
* In commit 488de6294a (CPack: correctly perform querytags on old
versions of RPM, 2025-01-09, v4.0.0-rc1~182^2~3), without
`RPM_EXECUTABLE` the query always failed. This change has not
yet been in a release anyway.
Also fix the test case for the "suggests" field to verify this.
Issue: #22350
Reported-by: Balazs Kosaras <balazskosaras@gmail.com>
The recent addition of component handling for CPS neglected to update
the documentation of how find_package handles component requests when
importing from CPS. Make those changes now.
The phrase "requires string" refers to the RPM `Requires` tag, but it
had been copied from the description of `CPACK_RPM_PACKAGE_REQUIRES`
without adjusting the text.
GNU ld 2.39 added warnings of the form
ld: warning: %pB has a LOAD segment with RWX permissions
They appear when linking test binaries on `hppa` and `sparc`.
Debian-Issue: https://bugs.debian.org/1098956
Debian-Issue: https://bugs.debian.org/1098970
This dependency is not expressed in upstream libuv. It was added to
CMake by commit 6a497bb0a3 (libuv: Link with kvm on FreeBSD, 2016-09-08,
v3.7.0-rc1~143^2~1). It is needed only on NetBSD.
Fixes: #26722