1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-19 12:11:28 +00:00

buildRustCrate: reflow the way extraRustcOpts is constructed

This should make it more obvious that we have three parts to it and not
just one long gibberish string that makes up all of it.
This commit is contained in:
Andreas Rammhold 2019-12-11 23:27:58 +01:00
parent d37f001164
commit 5ad83267ed
No known key found for this signature in database
GPG key ID: E432E410B5E48C86

View file

@ -126,7 +126,10 @@ stdenv.mkDerivation (rec {
colors = lib.attrByPath [ "colors" ] "always" crate;
extraLinkFlags = lib.concatStringsSep " " (crate.extraLinkFlags or []);
edition = crate.edition or null;
extraRustcOpts = lib.optionals (crate ? extraRustcOpts) crate.extraRustcOpts ++ extraRustcOpts_ ++ (lib.optional (edition != null) "--edition ${edition}");
extraRustcOpts =
lib.optionals (crate ? extraRustcOpts) crate.extraRustcOpts
++ extraRustcOpts_
++ (lib.optional (edition != null) "--edition ${edition}");
configurePhase = configureCrate {
inherit crateName buildDependencies completeDeps completeBuildDeps crateDescription