62 lines
1.8 KiB
Bash
62 lines
1.8 KiB
Bash
|
# Template file for 'cri-o'
|
||
|
pkgname=cri-o
|
||
|
version=1.12.1
|
||
|
revision=1
|
||
|
build_style=go
|
||
|
go_import_path="github.com/kubernetes-sigs/cri-o"
|
||
|
go_package="${go_import_path}/cmd/crio ${go_import_path}/cmd/crio-config"
|
||
|
go_build_tags="apparmor seccomp exclude_graphdriver_btrfs btrfs_noversion
|
||
|
containers_image_ostree_stub"
|
||
|
conf_files="/etc/crictl.yaml /etc/crio/crio.conf /etc/crio/seccomp.json"
|
||
|
hostmakedepends="pkg-config go-md2man"
|
||
|
makedepends="gpgme-devel libglib-devel libseccomp-devel libapparmor-devel
|
||
|
device-mapper-devel"
|
||
|
short_desc="OCI-based implementation of Kubernetes Container Runtime Interface"
|
||
|
maintainer="Cameron Nemo <camerontnorman@gmail.com>"
|
||
|
license="Apache-2.0"
|
||
|
homepage="https://github.com/kubernetes-sigs/cri-o"
|
||
|
distfiles="https://github.com/kubernetes-sigs/cri-o/archive/v${version}.tar.gz"
|
||
|
checksum=81158b0ab14ea70c29365184e5b0b75e4b169d99852d61905f104ae776973a79
|
||
|
|
||
|
if [ "$CROSS_BUILD" ]; then
|
||
|
hostmakedepends+=" cri-o-devel"
|
||
|
fi
|
||
|
|
||
|
post_build() {
|
||
|
cd conmon
|
||
|
if [ "$CROSS_BUILD" ]; then
|
||
|
crio-config
|
||
|
else
|
||
|
"${GOPATH}"/bin/crio-config
|
||
|
fi
|
||
|
cd ..
|
||
|
CFLAGS+=' -fPIC' make -C conmon
|
||
|
make -C pause
|
||
|
if [ "$CROSS_BUILD" ]; then
|
||
|
crio --config="" config --default > crio.conf
|
||
|
else
|
||
|
"${GOPATH}"/bin/crio --config="" config --default > crio.conf
|
||
|
fi
|
||
|
make docs
|
||
|
}
|
||
|
|
||
|
post_install() {
|
||
|
vinstall bin/conmon 755 usr/libexec/crio
|
||
|
vinstall bin/pause 755 usr/libexec/crio
|
||
|
make install.man PREFIX="${DESTDIR}/usr"
|
||
|
vinstall crio.conf 644 etc/crio
|
||
|
vinstall seccomp.json 644 etc/crio
|
||
|
vinstall crictl.yaml 644 etc
|
||
|
vinstall crio-umount.conf 644 usr/share/oci-umount/oci-umount.d
|
||
|
vmkdir usr/share/examples/"${pkgname}"
|
||
|
vcopy contrib/cni usr/share/examples/"${pkgname}"
|
||
|
}
|
||
|
|
||
|
cri-o-devel_package() {
|
||
|
short_desc+=" - development tools"
|
||
|
depends="${sourcepkg}>=${version}_${revision}"
|
||
|
pkg_install() {
|
||
|
vmove usr/bin/crio-config
|
||
|
}
|
||
|
}
|