Closed
Conversation
Contributor
|
Port {
"name": "test1",
"version": "1.0.0",
"default-features": ["foo"],
"features":{
"foo": {
"description": "bar"
}
}
}Main {
"name": "root",
"version": "1.0.0",
"depend-defaults": false,
"dependencies": [
{
"name": "test1",
"default-features": true
}
]
}Results in Imho it should install |
Contributor
|
The problem is that the |
Member
|
Can you merge with main? |
Member
|
Are you still working on this? If not I think we should close the PR. |
Contributor
|
I have completed this PR in #538. One thing: The features vector now always contains "core" which seems a little bit unnecessary. |
Member
|
Closing this in favor of #538 |
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.
This manifest property implements two highly requested features:
Sets the default for "default-features" in the current manifest to false, meaning a simple dependency list of strings will not imply dependency upon default features. The vast majority of dependencies should not require defaults, so this avoids the boilerplate of explicitly qualifying every dependency as
"default-features": false.If used in the top level manifest, disables automatic addition of defaults for transitive unnamed dependencies. This enables easier testing of the "minimum set" of dependencies and has been commonly requested by advanced users of vcpkg.
Edit:
During the implementation of this feature, I ran into an issue where the code reuses
Dependencyboth as a context sensitive parse tree as well as a context-free representation of dependence in the version resolver algorithm. I've chosen to resolve this in the simplest way possible for now (inject the context in theSourceControlFileparser), however the more correct long-term approach is to introduce a separate representation for the context-free form (that has anInternalFeatureSet, etc).