-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: Initial work to add modifiers to Cargo.toml and env variable options #117
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution.
I have no objection adding such feature but would like a bit more context as I never used those kinds of modifiers.
Adding @xclaesse and @nirbheek in case they know more about modifiers and have some input.
Once we agree on the API we'll need it properly documented in the general documentation at the top of lib.rs
.
|
||
[package.metadata.system-deps] | ||
testdata = "4" | ||
teststaticlib = { version = "1", feature = "test-feature", modifiers = "+whole-archive"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not familiar with +whole-archive
and modifiers in general. If they are used only during static linking maybe they should be called static_modifiers
instead?
What other modifiers could be used there for example?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for taking a look so quickly and for pulling in some more people, I wouldn't consider myself a deep expert either!
In rustc documentation the three specified are [+|-]
whole-archive
, verbatim
, and bundle
. This is where I wouldn't consider myself a deep expert and I'm not sure if more are supported and these 3 are just the documented ones because they have defaults.
The terminology I used here matches rustc
and build script documentation. However, I am happy to rename if that's the consensus.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it makes sense to use the same terminology as rustc
then. We should also link this page in our documentation of this feature.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #117 +/- ##
==========================================
+ Coverage 90.91% 91.30% +0.38%
==========================================
Files 3 3
Lines 2257 2403 +146
==========================================
+ Hits 2052 2194 +142
- Misses 205 209 +4 ☔ View full report in Codecov by Sentry. |
This PR adds the ability to use modifiers in
Cargo.toml
and Environment variable overrides.resolves: #118