containerd: 1.5.1 -> 1.5.2, use buildGoModule

(cherry picked from commit daed0cc14f83ecde8190feba3e80246d5a2b88a3)
This commit is contained in:
Jonathan Ringer 2021-05-19 15:47:00 -07:00 committed by github-actions[bot]
parent c41fdc54ac
commit 5a7a7e2b30
1 changed files with 8 additions and 9 deletions

View File

@ -1,6 +1,6 @@
{ lib { lib
, fetchFromGitHub , fetchFromGitHub
, buildGoPackage , buildGoModule
, btrfs-progs , btrfs-progs
, go-md2man , go-md2man
, installShellFiles , installShellFiles
@ -8,19 +8,20 @@
, nixosTests , nixosTests
}: }:
buildGoPackage rec { buildGoModule rec {
pname = "containerd"; pname = "containerd";
version = "1.5.1"; version = "1.5.2";
outputs = [ "out" "man" ];
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "containerd"; owner = "containerd";
repo = "containerd"; repo = "containerd";
rev = "v${version}"; rev = "v${version}";
sha256 = "sha256-jVyg+fyMuDnV/TM0Z2t+Cr17a6XBv11aWijhsqMnA5s="; sha256 = "sha256-RDLAmPBjDHCx9al+gstUTrvKc/L0vAm8IEd/mvX5Als=";
}; };
goPackagePath = "github.com/containerd/containerd"; vendorSha256 = null;
outputs = [ "out" "man" ];
nativeBuildInputs = [ go-md2man installShellFiles util-linux ]; nativeBuildInputs = [ go-md2man installShellFiles util-linux ];
@ -28,11 +29,9 @@ buildGoPackage rec {
buildFlags = [ "VERSION=v${version}" "REVISION=${src.rev}" ]; buildFlags = [ "VERSION=v${version}" "REVISION=${src.rev}" ];
BUILDTAGS = [ ] BUILDTAGS = lib.optionals (btrfs-progs == null) [ "no_btrfs" ];
++ lib.optional (btrfs-progs == null) "no_btrfs";
buildPhase = '' buildPhase = ''
cd go/src/${goPackagePath}
patchShebangs . patchShebangs .
make binaries man $buildFlags make binaries man $buildFlags
''; '';