go: fix cross-compilation
Because: * `go-bootstrap` is a native build input of go, so it needs to have an offset of -1. Otherwise, e.g. when building a go cross-compiler, it will try to make go-bootstrap a cross-compiler too. * have to specify `buildPackages` for the `stdenv` override, otherwise `buildPackages.stdenv` will be the same as `pkgs.gcc8Stdenv`.
This commit is contained in:
@@ -13,7 +13,7 @@ let
|
||||
|
||||
version = "1.14.15";
|
||||
|
||||
go_bootstrap = callPackage ./bootstrap.nix { };
|
||||
go_bootstrap = buildPackages.callPackage ./bootstrap.nix { };
|
||||
|
||||
goBootstrap = runCommand "go-bootstrap" {} ''
|
||||
mkdir $out
|
||||
|
||||
@@ -13,7 +13,7 @@ let
|
||||
|
||||
version = "1.15.8";
|
||||
|
||||
go_bootstrap = callPackage ./bootstrap.nix { };
|
||||
go_bootstrap = buildPackages.callPackage ./bootstrap.nix { };
|
||||
|
||||
goBootstrap = runCommand "go-bootstrap" {} ''
|
||||
mkdir $out
|
||||
|
||||
@@ -13,7 +13,7 @@ let
|
||||
|
||||
version = "1.16";
|
||||
|
||||
go_bootstrap = callPackage ./bootstrap.nix { };
|
||||
go_bootstrap = buildPackages.callPackage ./bootstrap.nix { };
|
||||
|
||||
goBootstrap = runCommand "go-bootstrap" {} ''
|
||||
mkdir $out
|
||||
|
||||
@@ -11,7 +11,7 @@ let
|
||||
|
||||
inherit (lib) optionals optionalString;
|
||||
|
||||
go_bootstrap = callPackage ./bootstrap.nix { };
|
||||
go_bootstrap = buildPackages.callPackage ./bootstrap.nix { };
|
||||
|
||||
goBootstrap = runCommand "go-bootstrap" {} ''
|
||||
mkdir $out
|
||||
|
||||
Reference in New Issue
Block a user