From b771cc73d4f25c88e9e2c91c2af0acb713935de2 Mon Sep 17 00:00:00 2001 From: Sascha Grunert Date: Mon, 10 Feb 2020 09:10:11 +0100 Subject: [PATCH] cri-o: v1.16.1 -> v1.17.0 Signed-off-by: Sascha Grunert --- .../virtualization/cri-o/default.nix | 30 +++++++------------ 1 file changed, 10 insertions(+), 20 deletions(-) diff --git a/pkgs/applications/virtualization/cri-o/default.nix b/pkgs/applications/virtualization/cri-o/default.nix index f6e78f364c2c..f39e22cc64ab 100644 --- a/pkgs/applications/virtualization/cri-o/default.nix +++ b/pkgs/applications/virtualization/cri-o/default.nix @@ -4,6 +4,7 @@ , btrfs-progs , buildGoPackage , fetchFromGitHub +, git , glibc , gpgme , libapparmor @@ -13,13 +14,14 @@ , libselinux , lvm2 , pkgconfig +, which }: let buildTags = "apparmor seccomp selinux containers_image_ostree_stub"; in buildGoPackage rec { project = "cri-o"; - version = "1.16.1"; + version = "1.17.0"; name = "${project}-${version}${flavor}"; goPackagePath = "github.com/${project}/${project}"; @@ -28,11 +30,11 @@ in buildGoPackage rec { owner = "cri-o"; repo = "cri-o"; rev = "v${version}"; - sha256 = "0w690zhc55gdqzc31jc34nrzwd253pfb3rq23z51q22nqwmlsh9p"; + sha256 = "0xjmylf0ww23qqcg7kw008px6608r4qq6q57pfqis0661kp6f24j"; }; outputs = [ "bin" "out" ]; - nativeBuildInputs = [ pkgconfig ]; + nativeBuildInputs = [ git pkgconfig which ]; buildInputs = [ btrfs-progs gpgme libapparmor libassuan libgpgerror libseccomp libselinux lvm2 ] ++ stdenv.lib.optionals (glibc != null) [ glibc glibc.static ]; @@ -40,27 +42,15 @@ in buildGoPackage rec { buildPhase = '' pushd go/src/${goPackagePath} - # Build pause - make -C pause - - # Build the crio binaries - function build() { - go build \ - -tags "${buildTags}" \ - -o bin/"$1" \ - -buildmode=pie \ - -ldflags '-s -w ${ldflags}' \ - ${goPackagePath}/cmd/"$1" - } - build crio - build crio-status + make BUILDTAGS='${buildTags}' \ + bin/crio \ + bin/crio-status \ + bin/pinns ''; installPhase = '' install -Dm755 bin/crio $bin/bin/crio${flavor} install -Dm755 bin/crio-status $bin/bin/crio-status${flavor} - - mkdir -p $bin/libexec/crio - install -Dm755 bin/pause $bin/libexec/crio/pause${flavor} + install -Dm755 bin/pinns $bin/bin/pinns${flavor} ''; meta = with stdenv.lib; {