nixpkgs/pkgs/build-support/rust/build-rust-crate
Andreas Rammhold be5597fc9d
buildRustCrate: remove superfluous dependency overrides
By overriding each dependency on every level of the dependency tree we
are creating a lot of unnecessary instances of the same derivation

Looking at the output size of `nix-instantiate --trace-function-calls
-vvvv …` and the execution time I got about a 10x improvement after
applying this change.

It was probably good intentions that lead to these overrides but in
practice no tooling (that I know of) really needs this. `carnix` and
`crate2nix` are fine without those overrides. Furthermore I believe that
it is the job of the tooling around `buildRustCrate` to provide a
coherent set of overrides. By not enforcing all of the overrides, debug
flags, verbosity, … to be the same throughout the closure we also allow
consumers to override specific aspects of the crates. Some (older?)
crates might need different `crateOverrides` then newer crates with the
same name. Currently such situations can not (easily) be implemented
with the override in-place.
2020-02-11 11:48:45 +01:00
..
test buildRustCrateTests: add regression test for #74071 2020-01-28 14:07:58 +01:00
build-crate.nix buildRustCrate: remove one of the odd library filename cases 2020-01-16 13:24:13 +01:00
configure-crate.nix buildRustCrate: fix #78412 2020-01-28 14:07:58 +01:00
default.nix buildRustCrate: remove superfluous dependency overrides 2020-02-11 11:48:45 +01:00
helpers.nix buildRustCrate: fixup usage of builtins.filterSource 2020-01-07 00:49:48 +01:00
install-crate.nix buildRustCrate: add buildTests flag to tell rustc to build tests instead of binaries 2020-01-07 11:57:34 +01:00
lib.sh buildRustCrate: add buildTests flag to tell rustc to build tests instead of binaries 2020-01-07 11:57:34 +01:00
log.nix buildRustCrate: move the color loggign & remove some runtime checks 2019-12-11 22:35:44 +01:00