depot/third_party/nixpkgs/pkgs/development/compilers/dotnet/dotnet.nix
Default email ae2dc6aea6 Project import generated by Copybara.
GitOrigin-RevId: 4c2fcb090b1f3e5b47eaa7bd33913b574a11e0a0
2024-10-11 07:15:48 +02:00

65 lines
1.2 KiB
Nix

{
stdenvNoCC,
callPackage,
lib,
fetchurl,
releaseManifestFile,
releaseInfoFile,
bootstrapSdkFile,
allowPrerelease ? false,
depsFile,
pkgsBuildHost,
buildDotnetSdk,
}:
let
inherit (lib.importJSON releaseInfoFile)
tarballHash
artifactsUrl
artifactsHash
bootstrapSdk
;
pkgs = callPackage ./stage1.nix {
inherit
releaseManifestFile
tarballHash
depsFile
;
bootstrapSdk = (buildDotnetSdk bootstrapSdkFile).sdk.overrideAttrs (old: {
passthru = old.passthru or { } // {
artifacts = stdenvNoCC.mkDerivation rec {
name = lib.nameFromURL artifactsUrl ".tar.gz";
src = fetchurl {
url = artifactsUrl;
hash = artifactsHash;
};
sourceRoot = ".";
installPhase = ''
mkdir -p $out
cp -r * $out/
'';
};
};
});
};
in
pkgs
// {
vmr = pkgs.vmr.overrideAttrs (old: {
passthru = old.passthru // {
updateScript = pkgsBuildHost.callPackage ./update.nix {
inherit
releaseManifestFile
releaseInfoFile
bootstrapSdkFile
allowPrerelease
;
};
};
});
}