Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
base: 2ff742e970de
Choose a base ref
...
head repository: NixOS/nixpkgs
compare: 9f03cb856264
Choose a head ref
  • 10 commits
  • 6 files changed
  • 1 contributor

Commits on Dec 11, 2019

  1. buildRustCrate: builtins -> lib where possible

    We can just use `lib` instead of `builtins` in all cases but the
    `hashString` case. Also changed a few lines to make use of some optional
    helpers from lib.
    andir committed Dec 11, 2019
    Copy the full SHA
    0aac0e8 View commit details
    Browse the repository at this point in the history
  2. buildRustCrate: move the color loggign & remove some runtime checks

    The expression is already long and confusing enough without the color
    stuff sprinkled in. Moving it to a dedicated file makes sense.
    
    I switched a bit of the color support code to pure Nix since there
    wasn't much point in doing that in bash while we can just do it in Nix.
    andir committed Dec 11, 2019
    Copy the full SHA
    50b2ef2 View commit details
    Browse the repository at this point in the history
  3. buildRustCrate: use tr instead of sed (it reads a bit nicer)

    I already have a few changes in here that will trigger rebuilds so I
    might as well do that substitution now.
    andir committed Dec 11, 2019
    Copy the full SHA
    db55d1f View commit details
    Browse the repository at this point in the history
  4. buildRustCrate: document and cleanup the symbol seeding

    That code had been in the derivation for a while but no explanation was
    given why that is needed. It might be helpful to our future selfs to
    document why things are done the way they are.
    andir committed Dec 11, 2019
    Copy the full SHA
    f4aeabd View commit details
    Browse the repository at this point in the history
  5. buildRustCrate: rename makeDeps function to mkRustcDepArgs

    This should carry the function better then `makeDeps` as it isn't
    producing deps but the rustc arguments required to link against those.
    andir committed Dec 11, 2019
    Copy the full SHA
    d37f001 View commit details
    Browse the repository at this point in the history
  6. 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.
    andir committed Dec 11, 2019
    Copy the full SHA
    5ad8326 View commit details
    Browse the repository at this point in the history

Commits on Dec 12, 2019

  1. buildRustCrate: use less bash for the build script

    We can get rid of a bunch of workarounds that were in the build script
    before by just passing on the `crateBin` attribute.
    
    Before we converted the list of attributes to a string only to convert
    it back in bash during the build phase. We can do the entire looping
    through builds in Nix and thus need no conversion and parsing of
    attributes over and over again.
    
    The big part that still remains bash is the heuristic that cargo
    introduced and that we can't do at eval time.
    andir committed Dec 12, 2019
    Copy the full SHA
    6ad22f5 View commit details
    Browse the repository at this point in the history
  2. buildRustCrate: deduplicate dependency override code

    The previous lines were only different in the kind of dependencies but
    otherwise exactly the same. It makes the entire thing a bit more
    readable by moving this into a function that takes care of this.
    andir committed Dec 12, 2019
    Copy the full SHA
    3f49d7a View commit details
    Browse the repository at this point in the history
  3. buildRustCrate: move common build functions to a dedicated file

    This means we aren't rebuilding hat file for each crate we are building
    and the buildPhase expression is a lot easier to comprehent.
    andir committed Dec 12, 2019
    Copy the full SHA
    2eaaf7a View commit details
    Browse the repository at this point in the history

Commits on Jan 2, 2020

  1. Merge pull request #75563 from andir/cleanup-buildRustCrate

    Cleanup buildRustCrate expression
    andir committed Jan 2, 2020
    Copy the full SHA
    9f03cb8 View commit details
    Browse the repository at this point in the history