Open
Description
Summary
It should be possible to use the following syntax in packages:
has_code = True
version("6.0", has_code=False)
version("5.0", sha256="67865a0e3cdc7dec1fd676f0927f7011ad4036c18eb320a2b41dbd56282f33b8")
(or the converse).
Rationale
Xorg protocols used to be distributed as individual packages, but are now distributed as a bundle. One way to express this in spack is to have a multiple build system package for the individual protocols, with newer versions not containing code and deferring to the new combined Xorg protocols package as a dependency instead, using a BundlePackage as implementation. See discussion at #45569 (specifically #45569 (comment)).
Description
Adding has_code
to directives.py
is trivial enough, but the parsing of optional version attributes in fetch_strategy.py
happens well after the pkg.has_code
has been evaluated.
Additional information
No response
General information
- I have searched the issues of this repo and believe this is not a duplicate