2020-05-15 21:57:56 +00:00
|
|
|
{ stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, btrfs-progs
|
2020-05-15 21:57:56 +00:00
|
|
|
, buildGoModule
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, glibc
|
|
|
|
, gpgme
|
2020-05-15 21:57:56 +00:00
|
|
|
, installShellFiles
|
2020-04-24 23:36:52 +00:00
|
|
|
, libapparmor
|
|
|
|
, libseccomp
|
|
|
|
, libselinux
|
|
|
|
, lvm2
|
2020-05-15 21:57:56 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
buildGoModule rec {
|
|
|
|
pname = "cri-o";
|
2020-08-20 17:08:02 +00:00
|
|
|
version = "1.18.3";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "cri-o";
|
|
|
|
repo = "cri-o";
|
|
|
|
rev = "v${version}";
|
2020-08-20 17:08:02 +00:00
|
|
|
sha256 = "1csdbyypqwxkfc061pdv7nj52a52b9xxzb6qgxcznd82w7wgfb3g";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
2020-05-15 21:57:56 +00:00
|
|
|
vendorSha256 = null;
|
2020-08-20 17:08:02 +00:00
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
outputs = [ "out" "man" ];
|
|
|
|
nativeBuildInputs = [ installShellFiles pkg-config ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
buildInputs = [
|
|
|
|
btrfs-progs
|
|
|
|
gpgme
|
|
|
|
libapparmor
|
|
|
|
libseccomp
|
|
|
|
libselinux
|
|
|
|
lvm2
|
|
|
|
] ++ stdenv.lib.optionals (glibc != null) [ glibc glibc.static ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
BUILDTAGS = "apparmor seccomp selinux containers_image_openpgp containers_image_ostree_stub";
|
2020-04-24 23:36:52 +00:00
|
|
|
buildPhase = ''
|
2020-05-15 21:57:56 +00:00
|
|
|
patchShebangs .
|
|
|
|
|
|
|
|
sed -i '/version.buildDate/d' Makefile
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-15 21:57:56 +00:00
|
|
|
make binaries docs BUILDTAGS="$BUILDTAGS"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
2020-05-15 21:57:56 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
installPhase = ''
|
2020-05-15 21:57:56 +00:00
|
|
|
install -Dm755 bin/* -t $out/bin
|
|
|
|
|
|
|
|
for shell in bash fish zsh; do
|
|
|
|
installShellCompletion --$shell completions/$shell/*
|
|
|
|
done
|
|
|
|
|
|
|
|
installManPage docs/*.[1-9]
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = "https://cri-o.io";
|
2020-05-15 21:57:56 +00:00
|
|
|
description = ''
|
|
|
|
Open Container Initiative-based implementation of the
|
|
|
|
Kubernetes Container Runtime Interface
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ ] ++ teams.podman.members;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|