841d9c7fc1
GitOrigin-RevId: 3a8d7958a610cd3fec3a6f424480f91a1b259185
35 lines
914 B
Nix
35 lines
914 B
Nix
{ buildPackages, callPackage }:
|
|
|
|
{ rustc, cargo, ... }:
|
|
|
|
rec {
|
|
rust = {
|
|
inherit rustc cargo;
|
|
};
|
|
|
|
fetchCargoTarball = buildPackages.callPackage ../../../build-support/rust/fetchCargoTarball.nix {
|
|
git = buildPackages.gitMinimal;
|
|
inherit cargo;
|
|
};
|
|
|
|
buildRustPackage = callPackage ../../../build-support/rust {
|
|
git = buildPackages.gitMinimal;
|
|
inherit cargoBuildHook cargoCheckHook cargoInstallHook cargoSetupHook
|
|
fetchCargoTarball importCargoLock rustc;
|
|
};
|
|
|
|
importCargoLock = buildPackages.callPackage ../../../build-support/rust/import-cargo-lock.nix {};
|
|
|
|
rustcSrc = callPackage ./rust-src.nix {
|
|
inherit rustc;
|
|
};
|
|
|
|
rustLibSrc = callPackage ./rust-lib-src.nix {
|
|
inherit rustc;
|
|
};
|
|
|
|
# Hooks
|
|
inherit (callPackage ../../../build-support/rust/hooks {
|
|
inherit cargo rustc;
|
|
}) cargoBuildHook cargoCheckHook cargoInstallHook cargoSetupHook maturinBuildHook;
|
|
}
|