anchor.diff:      ];
     };
   
  -  unitTests = pkgs.stdenv.mkDerivation {
  -    # TODO
  -    # name = "rethinkdb-unit-test-results-${src.version}.html";
  -    name = "rethinkdb-unit-test-results.html";
  +  fastTests = pkgs.stdenv.mkDerivation {
  +    name = "rethinkdb-unit-test-results-${src.version}";
       src = sourceTarball;
       buildInputs = with pkgs; [
         protobuf
  
positive.code:       cp -r $src rethinkdb
        chmod -R u+w rethinkdb
        cd rethinkdb
        # TODO: use original shebangs in tarball
        patchShebangs configure
        patchShebangs drivers/convert_protofile
        patchShebangs scripts/gen-version.sh
        patchShebangs mk/support/pkg/pkg.sh
        ./configure --fetch jemalloc
        make dist -j $NIX_BUILD_CORES
        cp build/packages/rethinkdb-*.tgz $out
      '';
      __noChroot = true;
      src = <rethinkdb>;
  
negative.code:   };
  
    sourceTarball = pkgs.stdenv.mkDerivation rec {
      name = "rethinkdb-${version}.tgz";
      version = builtins.unsafeDiscardStringContext (builtins.readFile versionFile);
      builder = builtins.toFile "builder.sh" ''
        source $stdenv/setup
        # TODO: https://github.com/NixOS/nixpkgs/issues/13744
  