commit:     e928dc38e4025e99b371ee2875dfae3e92892461
Author:     Sebastian Hamann <code <AT> ares-macrotechnology <DOT> com>
AuthorDate: Mon May  1 06:21:22 2023 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu May 18 07:44:43 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e928dc38

app-emulation/firecracker-bin: add 1.3.2

Signed-off-by: Sebastian Hamann <code <AT> ares-macrotechnology.com>
Closes: https://github.com/gentoo/gentoo/pull/30819
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 app-emulation/firecracker-bin/Manifest             |  2 +
 .../firecracker-bin/firecracker-bin-1.3.2.ebuild   | 82 ++++++++++++++++++++++
 2 files changed, 84 insertions(+)

diff --git a/app-emulation/firecracker-bin/Manifest 
b/app-emulation/firecracker-bin/Manifest
index e2d68d45746d..af7fbaa01855 100644
--- a/app-emulation/firecracker-bin/Manifest
+++ b/app-emulation/firecracker-bin/Manifest
@@ -2,3 +2,5 @@ DIST firecracker-v1.2.0-aarch64.tgz 4060245 BLAKE2B 
28434aa623eb473b1886e5a6da2a
 DIST firecracker-v1.2.0-x86_64.tgz 3932475 BLAKE2B 
3db4b5f0746db48e8cd6e00735ba859e16b1bec94a23854cdc3af65d032773c596e8b52cf0a0cd40e363de1a5c67817176a5287af9c692167e8f4681a6b07e9a
 SHA512 
67fcd8b898ebc3207de8f93a466430261c923d27bce97bb32636bd243957cb757da1fc72ebec2751c14205e111d2ffb80c94cfa033aecf715962e59b813fbe5f
 DIST firecracker-v1.3.1-aarch64.tgz 4178577 BLAKE2B 
80636ee5878acce741f12647c7107b111430ee4a6f1da9e09af44d30bce16ac8e69d11ebc59b6220cbf145882876b38f4ee0e0a7c0050830ee93b6c925c0bd7e
 SHA512 
f82ab276bac1d8187d33b4b0b07e871122170199025ca693d2eaf3a02d93e03dcbfe50af87584a69ac2c00868e0c02a8a7350f5e1b1e9cb196dc52d7c677f539
 DIST firecracker-v1.3.1-x86_64.tgz 4105205 BLAKE2B 
ab40e91c641c34b621542a991c642be61404aaa77d861341827d0555e5128773f7407277355a342fdc7c4c26d6a604e357901672175ef0a6578b25c9207c2e45
 SHA512 
272f3579f2943ee32663590e99658ee52cf7b8693b402d2f342e1de8a55fa4c05db5fb4b6a0495c88dfb51f0830640c3e6ef9e1569264f6c2eb9ab99c84bc2b5
+DIST firecracker-v1.3.2-aarch64.tgz 4192631 BLAKE2B 
b1a44c7fb0458f8e9298eddebc047cb4582ca4164926b29b23961a3c9decba26278bd70117365b89e29c414561aed1e79f4e2c248d362ea3e389d58bc5a60235
 SHA512 
9e88396270da04f8b0ee92c0b15f4abb8e05674c97b2dc9233ea181e9ce5a9c96400d2cc870279d9dd3fd5763cbefc3e74db01cb0ecacd1d84c966eb9c7d39d9
+DIST firecracker-v1.3.2-x86_64.tgz 4152061 BLAKE2B 
f9025e827b53b482bd0f44918533ad0834eaa2ca4e4d13bedda5899ba3790e9bd0bf31793d2d6e53b7791b988a2fe0b5c69b5c08eba94d865660ee4e6c2ce282
 SHA512 
ff5c8ed9c7a200c87436ea5f952ecf584476030a2153eaa6d753624a324fa980687249a2a3351cb120f984b86c13395c611dbb44029072f2a961d79c54dbe731

diff --git a/app-emulation/firecracker-bin/firecracker-bin-1.3.2.ebuild 
b/app-emulation/firecracker-bin/firecracker-bin-1.3.2.ebuild
new file mode 100644
index 000000000000..ec091124b7ad
--- /dev/null
+++ b/app-emulation/firecracker-bin/firecracker-bin-1.3.2.ebuild
@@ -0,0 +1,82 @@
+# Copyright 2021-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit linux-info
+
+DESCRIPTION="Secure and fast microVMs for serverless computing (static build)"
+HOMEPAGE="https://firecracker-microvm.github.io 
https://github.com/firecracker-microvm/firecracker";
+SRC_URI="
+       amd64? (
+               
https://github.com/firecracker-microvm/firecracker/releases/download/v${PV}/firecracker-v${PV}-x86_64.tgz
+       )
+       arm64? (
+               
https://github.com/firecracker-microvm/firecracker/releases/download/v${PV}/firecracker-v${PV}-aarch64.tgz
+       )"
+
+LICENSE="|| ( Apache-2.0 MIT Apache-2.0-with-LLVM-exceptions ) MPL-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64"
+
+RESTRICT="test strip"
+
+RDEPEND="acct-group/kvm"
+
+QA_PREBUILT="usr/bin/firecracker
+       usr/bin/jailer
+       usr/bin/rebase-snap
+       usr/bin/seccompiler-bin"
+
+S="${WORKDIR}"
+
+pkg_pretend() {
+       if use kernel_linux && kernel_is lt 4 14; then
+               eerror "Firecracker requires a host kernel of 4.14 or higher."
+       elif use kernel_linux; then
+               if ! linux_config_exists; then
+                       eerror "Unable to check your kernel for KVM support"
+               else
+                       CONFIG_CHECK="~KVM ~TUN ~BRIDGE"
+                       ERROR_KVM="You must enable KVM in your kernel to 
continue"
+                       ERROR_KVM_AMD="If you have an AMD CPU, you must enable 
KVM_AMD in"
+                       ERROR_KVM_AMD+=" your kernel configuration."
+                       ERROR_KVM_INTEL="If you have an Intel CPU, you must 
enable"
+                       ERROR_KVM_INTEL+=" KVM_INTEL in your kernel 
configuration."
+                       ERROR_TUN="You will need the Universal TUN/TAP driver 
compiled"
+                       ERROR_TUN+=" into your kernel or loaded as a module to 
use"
+                       ERROR_TUN+=" virtual network devices."
+                       ERROR_BRIDGE="You will also need support for 802.1d"
+                       ERROR_BRIDGE+=" Ethernet Bridging for some network 
configurations."
+
+                       if use amd64 || use amd64-linux; then
+                               if grep -q AuthenticAMD /proc/cpuinfo; then
+                                       CONFIG_CHECK+=" ~KVM_AMD"
+                               elif grep -q GenuineIntel /proc/cpuinfo; then
+                                       CONFIG_CHECK+=" ~KVM_INTEL"
+                               fi
+                       fi
+
+                       # Now do the actual checks setup above
+                       check_extra_config
+               fi
+       fi
+}
+
+src_compile() { :; }
+
+src_install() {
+       if use amd64; then
+               my_arch=x86_64
+       elif use arm64; then
+               my_arch=aarch64
+       fi
+
+       dodoc "release-v${PV}-${my_arch}/firecracker_spec-v${PV}.yaml"
+       dodoc "release-v${PV}-${my_arch}/seccomp-filter-v${PV}-${my_arch}.json"
+
+       newbin "release-v${PV}-${my_arch}/firecracker-v${PV}-${my_arch}" 
firecracker
+       newbin "release-v${PV}-${my_arch}/jailer-v${PV}-${my_arch}" jailer
+       newbin "release-v${PV}-${my_arch}/rebase-snap-v${PV}-${my_arch}" 
rebase-snap
+       newbin "release-v${PV}-${my_arch}/seccompiler-bin-v${PV}-${my_arch}" 
seccompiler-bin
+}

Reply via email to