Merge pull request #82787 from Mic92/cross-build-go-module

buildGoModule: enable strictDeps
This commit is contained in:
Jörg Thalheim 2020-03-18 13:16:37 +00:00 committed by GitHub
commit 8590ddd427
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 17 additions and 14 deletions

View file

@ -33,7 +33,9 @@ in buildGoPackage rec {
goPackagePath = "github.com/openshift/origin";
buildInputs = [ which rsync go-bindata kerberos clang ];
buildInputs = [ kerberos ];
nativeBuildInputs = [ which rsync go-bindata clang ];
patchPhase = ''
patchShebangs ./hack

View file

@ -17,10 +17,8 @@ in buildGoModule rec {
modSha256 = "127xrah6xxrvc224g5dxn432sagrssx8v7phzapcsdajsnmagq6x";
nativeBuildInputs = [
go
scdoc
python3.pkgs.wrapPython
notmuch
];
patches = [
@ -31,7 +29,7 @@ in buildGoModule rec {
python3.pkgs.colorama
];
buildInputs = [ python3 perl ];
buildInputs = [ python3 notmuch ];
GOFLAGS="-tags=notmuch";

View file

@ -13,7 +13,7 @@ buildGoModule rec {
modSha256 = "1h9fij8mxlxfw7kxix00n10fkhkvmf8529fxbk1n30cxc1bs2szf";
buildInputs = [ go-bindata ];
nativeBuildInputs = [ go-bindata ];
buildPhase = ''
make magneticow magneticod
'';

View file

@ -1,4 +1,4 @@
{ lib, fetchFromGitHub, buildGoModule, go-bindata }:
{ lib, fetchFromGitHub, buildGoModule }:
buildGoModule rec {
name = "gvisor-containerd-shim-${version}";

View file

@ -208,6 +208,8 @@ let
find $out/bin -type f -exec ${removeExpr removeReferences} '{}' + || true
'';
strictDeps = true;
disallowedReferences = lib.optional (!allowGoReference) go;
passthru = passthru // { inherit go go-modules modSha256; };

View file

@ -13,7 +13,7 @@ buildGoModule rec {
modSha256 = "1z0v7n8klaxcqv7mvzf3jzgrp78zb4yiibx899ppk6i5qnj4xiv0";
buildInputs = [ go-bindata-assetfs go-bindata ];
nativeBuildInputs = [ go-bindata go-bindata-assetfs ];
subPackages = [ "edition/community.go" ];

View file

@ -13,11 +13,9 @@ buildGoModule rec {
modSha256 = "0kgd8lwcdns3skvd4bj4z85mq6hkk79mb0zzwky0wqxni8f73s6w";
buildInputs = [
gobject-introspection
pkg-config
vips
];
nativeBuildInputs = [ pkg-config ];
buildInputs = [ gobject-introspection vips ];
preBuild = ''
export CGO_LDFLAGS_ALLOW='-(s|w)'

View file

@ -14,8 +14,11 @@ buildGoPackage rec {
};
goPackagePath = "github.com/gravitational/teleport";
subPackages = [ "tool/tctl" "tool/teleport" "tool/tsh" ];
buildInputs = [ zip ];
nativeBuildInputs = [ zip ];
postBuild = ''
pushd .
cd $NIX_BUILD_TOP/go/src/github.com/gravitational/teleport
@ -27,7 +30,7 @@ buildGoPackage rec {
cd $NIX_BUILD_TOP/go/bin
zip -q -A teleport
popd
'';
'';
dontStrip = true;