aports/testing/cloud-hypervisor/APKBUILD
2025-02-05 21:32:35 +00:00

37 lines
1.2 KiB
Text

maintainer="Hoang Nguyen <folliekazetani@protonmail.com>"
pkgname=cloud-hypervisor
pkgver=44.0
pkgrel=0
pkgdesc="Virtual machine monitor for modern cloud workloads"
url="https://www.cloudhypervisor.org/"
# Only x86_64 and aarch64 are officially supported
arch="x86_64 aarch64"
license="Apache-2.0 AND BSD-3-Clause"
makedepends="cargo libcap-utils cargo-auditable"
source="https://github.com/cloud-hypervisor/cloud-hypervisor/releases/download/v$pkgver/cloud-hypervisor-v$pkgver.tar.xz"
builddir="$srcdir/$pkgname-v$pkgver"
# tests require CAP_NET_ADMIN capability
# setcap cap_net_admin
options="!check setcap"
prepare() {
default_prepare
cargo fetch --target="$CTARGET" --locked
}
build() {
cargo auditable build --release --frozen --features dbus_api
}
package() {
install -Dm755 -t "$pkgdir"/usr/bin/ \
target/release/cloud-hypervisor \
target/release/ch-remote
# Needs NET_ADMIN capabilities to set TAP interfaces up on the host
setcap cap_net_admin=+ep "$pkgdir"/usr/bin/cloud-hypervisor
}
sha512sums="
5f33b0646cc848fd9a9c5a0d3a383e4ecffd14b02c9c467984465cdffbdfbf339ac63552241398c3625311fe1b713158cd3ede4e0aa6fbf63c845be2987a072c cloud-hypervisor-v44.0.tar.xz
"