concretizer: make rules on virtual packages more linear#20680
Merged
tgamblin merged 1 commit intospack:developfrom Jan 6, 2021
Merged
concretizer: make rules on virtual packages more linear#20680tgamblin merged 1 commit intospack:developfrom
tgamblin merged 1 commit intospack:developfrom
Conversation
fixes spack#20679 In this refactor we have a single cardinality rule on the provider, which triggers a rule transforming a dependency on a virtual package into a dependency on the provider of the virtual.
alalazo
commented
Jan 5, 2021
| % if you declare a dependency on a virtual AND the package is not an external, | ||
| % you depend on one of its providers | ||
| 1 { | ||
| depends_on(Package, Provider, Type) : possible_provider(Provider, Virtual) |
Member
Author
There was a problem hiding this comment.
This is the gist of the issue: we shouldn't use possible_provider since we don't know if the possible provider is actually a provider. For some reasons in #20679 libiconv was selected as the iconv provider to satisfy the link dependency, while libc was selected to satisfy the build dependency without being a provider of anything (but being a possible provider of iconv).
Member
Author
There was a problem hiding this comment.
For the record: I spent a couple of hours trying to come up with a reproducer for tests, but I was not able to find one (while I am able to reproduce the issue reported in #20679 on the command line).
haampie
approved these changes
Jan 5, 2021
Member
haampie
left a comment
There was a problem hiding this comment.
Can confirm this solves my issue
tgamblin
approved these changes
Jan 6, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fixes #20679
In this refactor we have a single cardinality rule on the provider, which triggers a rule transforming a dependency on a virtual package into a dependency on the provider of the virtual.