go-modules: Update files to use vendorSha256

This commit is contained in:
Colin L Rice
2020-05-14 07:22:21 +01:00
committed by Jörg Thalheim
parent a0ddea1d6a
commit d6162dab50
215 changed files with 3251 additions and 423 deletions
+20 -4
View File
@@ -1,4 +1,4 @@
{ buildGoModule, fetchFromGitHub, lib, enableStatic ? false }:
{ rsync, buildGoModule, fetchFromGitHub, lib, runCommand, enableStatic ? false }:
buildGoModule rec {
pname = "gobetween";
@@ -10,14 +10,30 @@ buildGoModule rec {
rev = version;
sha256 = "f01593509ccece063acd47002c4fc52261fbbbcdbf14b088d813b7d8e38fcca8";
};
patches = [ ./gomod.patch ];
modSha256 =
"dd91838d20c99c73447590e43edd13c87755276f17ef3e53f24c5df3d0908f78";
deleteVendor = true;
buildPhase = ''
make build${lib.optionalString enableStatic "-static"}
make -e build${lib.optionalString enableStatic "-static"}
'';
lxd = fetchFromGitHub {
owner = "lxc";
repo = "lxd";
rev = "41efd98813f3b42f1752ff6c2c7569a054924623";
sha256 = "02vnvjjkzl7b0i2cn03f1lb3jgj5rd3wdkii4pqi9bvmhzszg0l2";
};
overrideModAttrs = (_: {
postBuild = ''
rm -r vendor/github.com/lxc/lxd
cp -r --reflink=auto ${lxd} vendor/github.com/lxc/lxd
'';
});
vendorSha256 = "1pd0zrjwpw6yv2s86a818yy2ma2fkazd3sb2h6zfp9mvyixgxgri";
installPhase = ''
mkdir -p $out/bin
cp bin/gobetween $out/bin