crater icon indicating copy to clipboard operation
crater copied to clipboard

Support customising the build for packages

Open Nemo157 opened this issue 6 years ago • 0 comments

For async-compression the majority of the API provided by the crate is disabled by default to reduce build time for dependencies. Given that, at the moment when this is built in Crater it is only really capable of checking the syntax of lib.rs, everything else is #[cfg]ed out.

It seems like there could be a package.metadata.crater section added similar to what docs.rs uses to configure necessary feature flags:

[package.metadata.crater]
features = [ "feature1", "feature2" ]
all-features = true
no-default-features = true
rustc-args = [ "--example-rustc-arg" ]
rustdoc-args = [ "--example-rustdoc-arg" ]

(I'm not sure if rustdoc-args could affect the doc-test build in some way, rustc-args could be useful in cases where a crate uses a non-feature cfg flag to enable some form of test support).

(related to #235)

Nemo157 avatar Dec 05 '19 13:12 Nemo157