summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgy Yakovlev <gyakovlev@gentoo.org>2021-07-19 19:04:57 -0700
committerGeorgy Yakovlev <gyakovlev@gentoo.org>2021-07-19 19:43:53 -0700
commit71495d17b60621fe86d64ab649085e6f51fc597b (patch)
treedec6ef1ebf2386f280a07521f70e03c528d8992c /app-emulation
parentnet-im/telegram-desktop: Bump to 2.8.11 (diff)
downloadgentoo-71495d17b60621fe86d64ab649085e6f51fc597b.tar.gz
gentoo-71495d17b60621fe86d64ab649085e6f51fc597b.tar.bz2
gentoo-71495d17b60621fe86d64ab649085e6f51fc597b.zip
app-emulation/runc: add 1.0.0
Bug: https://bugs.gentoo.org/802948 Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'app-emulation')
-rw-r--r--app-emulation/runc/Manifest1
-rw-r--r--app-emulation/runc/runc-1.0.0.ebuild78
2 files changed, 79 insertions, 0 deletions
diff --git a/app-emulation/runc/Manifest b/app-emulation/runc/Manifest
index cf7cc93b5e34..dec811716bc3 100644
--- a/app-emulation/runc/Manifest
+++ b/app-emulation/runc/Manifest
@@ -1 +1,2 @@
+DIST runc-1.0.0.tar.gz 2366170 BLAKE2B 1b6455cd45bc51b92c12b3293037446da62957d441124e9b76fd44ce92329e0eb2fde2ef71c6519fc4d58bcbd4ef580f64d71753a6fc06f3f6e347de170bd9c3 SHA512 8ddad1e031237c07b6cab5cfe5bdb7b11bf98d5d1064ec06845f36da073fe65a0facc6a28ba5daff71cdcb50cfd5d1cd25e97385b4eddb35b287113c2771365c
DIST runc-1.0.0_rc95.tar.gz 2309875 BLAKE2B 8038a2d5311463f1e83665d513ac8b6336ccaa88fab64a3218b261aa03b2750d342f95bdae965c593d4fa89fc89b1e1a6371498c205160d9d09a5c4920ffa841 SHA512 c802a6e5f16cc0321642fc7adffe33819867c1779420f76b2cabd532edb5ac8c852beadcbcf6a3e895fe274f111c5623be5dcc822fef96e7e5259bf532174ba1
diff --git a/app-emulation/runc/runc-1.0.0.ebuild b/app-emulation/runc/runc-1.0.0.ebuild
new file mode 100644
index 000000000000..73b4f6935686
--- /dev/null
+++ b/app-emulation/runc/runc-1.0.0.ebuild
@@ -0,0 +1,78 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit go-module linux-info
+
+# update on bump, look for https://github.com/docker\
+# docker-ce/blob/<docker ver OR branch>/components/engine/hack/dockerfile/install/runc.installer
+RUNC_COMMIT=84113eef6fc27af1b01b3181f31bbaf708715301
+CONFIG_CHECK="~USER_NS"
+
+DESCRIPTION="runc container cli tools"
+HOMEPAGE="http://runc.io"
+MY_PV="${PV/_/-}"
+SRC_URI="https://github.com/opencontainers/${PN}/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0 BSD-2 BSD MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
+IUSE="apparmor hardened +kmem +seccomp test"
+
+DEPEND="seccomp? ( sys-libs/libseccomp )"
+
+RDEPEND="
+ ${DEPEND}
+ !app-emulation/docker-runc
+ apparmor? ( sys-libs/libapparmor )
+"
+
+BDEPEND="
+ dev-go/go-md2man
+ test? ( "${RDEPEND}" )
+"
+
+# tests need busybox binary, and portage namespace
+# sandboxing disabled: mount-sandbox pid-sandbox ipc-sandbox
+# majority of tests pass
+RESTRICT+=" test"
+
+S="${WORKDIR}/${PN}-${MY_PV}"
+
+src_compile() {
+ # Taken from app-emulation/docker-1.7.0-r1
+ export CGO_CFLAGS="-I${ESYSROOT}/usr/include"
+ export CGO_LDFLAGS="$(usex hardened '-fno-PIC ' '')
+ -L${ESYSROOT}/usr/$(get_libdir)"
+
+ # build up optional flags
+ local options=(
+ $(usev apparmor)
+ $(usev seccomp)
+ $(usex kmem '' 'nokmem')
+ )
+
+ myemakeargs=(
+ BUILDTAGS="${options[*]}"
+ COMMIT="${RUNC_COMMIT}"
+ )
+
+ emake "${myemakeargs[@]}" runc man
+}
+
+src_install() {
+ myemakeargs+=(
+ PREFIX="${ED}/usr"
+ BINDIR="${ED}/usr/bin"
+ MANDIR="${ED}/usr/share/man"
+ )
+ emake "${myemakeargs[@]}" install install-man install-bash
+
+ local DOCS=( README.md PRINCIPLES.md docs/. )
+ einstalldocs
+}
+
+src_test() {
+ emake "${myemakeargs[@]}" localunittest
+}