Comment out buildPackageIncremental

This commit is contained in:
Nicolas Mattia 2019-07-02 13:06:30 +02:00
parent 0068df8a99
commit 6b41d97903

View file

@ -38,27 +38,28 @@ with rec
};
import ./build.nix src (defaultAttrs // attrs);
buildPackageIncremental = cargolock: name: version: src: attrs:
with rec
{ buildDependency = depName: depVersion:
# Really this should be 'buildPackageIncremental' but that makes
# Nix segfault
buildPackage (libb.dummySrc depName depVersion)
{ cargoBuild = "cargo build --release -p ${depName}:${depVersion} -j $NIX_BUILD_CORES";
inherit (attrs) cargo;
cargotomlPath = libb.writeTOML (libb.cargotomlFor depName depVersion);
cargolockPath = libb.writeTOML (
libb.cargolockFor cargolock depName depVersion
);
doCheck = false;
};
};
buildPackage src (attrs //
{
builtDependencies = map (x: buildDependency x.name x.version)
(libb.directDependencies cargolock name version) ;
}
);
# XXX: not quite working yet
# buildPackageIncremental = cargolock: name: version: src: attrs:
# with rec
# { buildDependency = depName: depVersion:
# # Really this should be 'buildPackageIncremental' but that makes
# # Nix segfault
# buildPackage (libb.dummySrc depName depVersion)
# { cargoBuild = "cargo build --release -p ${depName}:${depVersion} -j $NIX_BUILD_CORES";
# inherit (attrs) cargo;
# cargotomlPath = libb.writeTOML (libb.cargotomlFor depName depVersion);
# cargolockPath = libb.writeTOML (
# libb.cargolockFor cargolock depName depVersion
# );
# doCheck = false;
# };
# };
# buildPackage src (attrs //
# {
# builtDependencies = map (x: buildDependency x.name x.version)
# (libb.directDependencies cargolock name version) ;
# }
# );
};