Gentoo Archives: gentoo-commits

From: Georgy Yakovlev <gyakovlev@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/containerd/
Date: Tue, 20 Jul 2021 02:44:12
Message-Id: 1626749034.3844230e77f39931083e7dfa33452666d6fd7452.gyakovlev@gentoo
1 commit: 3844230e77f39931083e7dfa33452666d6fd7452
2 Author: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org>
3 AuthorDate: Tue Jul 20 02:41:18 2021 +0000
4 Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org>
5 CommitDate: Tue Jul 20 02:43:54 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3844230e
7
8 app-emulation/containerd: add 1.5.4
9
10 Bug: https://bugs.gentoo.org/802948
11 Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org>
12
13 app-emulation/containerd/Manifest | 1 +
14 app-emulation/containerd/containerd-1.5.4.ebuild | 84 ++++++++++++++++++++++++
15 2 files changed, 85 insertions(+)
16
17 diff --git a/app-emulation/containerd/Manifest b/app-emulation/containerd/Manifest
18 index 5e37778447d..99e74a98cf1 100644
19 --- a/app-emulation/containerd/Manifest
20 +++ b/app-emulation/containerd/Manifest
21 @@ -1,4 +1,5 @@
22 DIST containerd-1.4.6.tar.gz 6266709 BLAKE2B 3187ff003da7c1d6023ff9516c7aa510de49ad1188750b9cb782feae638ef1c4c74834f62344324eec8983feb6e881013b56ceb112e91ca0995878b08f20d69f SHA512 4693e67d17a21fe9413add39173981f484c461c7e228b05a8a886052bc445617116808db6321a134bcfdf853f382a6f228e979669588a375b434d1425853b143
23 DIST containerd-1.4.8.tar.gz 6400374 BLAKE2B def2d6e47d550d641888289943fee5c860a5523b1b4e347efafbf43a8dbf9d86bbcef0f4286efdf2591a42faf75aa2dc0acad11f2cfcdd99c7e3e89fcd13fa22 SHA512 3c4c52a7a1b3fb76f7837ef7260024e25df14e86ccaea351a0811dd9b7335eddc94019e3fb7e6acb4a41a3dee9c18387d0b44ea406c3534c64e8a4b3dee6a45b
24 DIST containerd-1.5.2.tar.gz 7667262 BLAKE2B 52f61a7d5a423e1e0fbada6084dacf1df49e3e16af034bd35914b35bed4d27f334f0b07e87681d1353eb7da05a301625326adc841be7a2900aea0640a0441f26 SHA512 e4f03e77f2d8f823680629efc8cf41db70a656edf46807dca69652e6500dc51b0ceb0fd174768a8a5069c8af3e78853c20d214d135e36d4f3559399894e2cdf1
25 +DIST containerd-1.5.4.tar.gz 7675134 BLAKE2B b50061655b0b78a9f4c8bf7355213d02517c5a15e3ff2a623e59ffcde8e7f59ef39aafaf9790f7d977b285eac4d38338505920cdd032d975c50d42605e7157a5 SHA512 91d2fce2dc218070078f0e9e8141d091eca9f23c0b1ff244180260f214a46cdd66ba5c89472b40c0875cbd25580e19765bb030abf2ad749cfd4eea712dacadc1
26 DIST containerd-man-1.5.2.tar.xz 7424 BLAKE2B 647e61a88c81ebb3087026adb0201b4a71c4e0fe763a37b8d146b3964d9d59aa47ea96d5c5069b7637251fe1fbe5ecc63d72a802673b526b5496d02b2ff5842c SHA512 32ac9e9a91bbea24bbdb63220efc6082bb5dd1db956b558942f5b3b9aa758b9c1c5e8a5eb5e3d950be6de25bc03b20d420a566ecdaa859a8e72e3e2564a9ab84
27
28 diff --git a/app-emulation/containerd/containerd-1.5.4.ebuild b/app-emulation/containerd/containerd-1.5.4.ebuild
29 new file mode 100644
30 index 00000000000..88783770efe
31 --- /dev/null
32 +++ b/app-emulation/containerd/containerd-1.5.4.ebuild
33 @@ -0,0 +1,84 @@
34 +# Copyright 2021 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=7
38 +inherit go-module systemd toolchain-funcs
39 +
40 +DESCRIPTION="A daemon to control runC"
41 +HOMEPAGE="https://containerd.io/"
42 +SRC_URI="https://github.com/containerd/containerd/archive/v${PV}.tar.gz -> ${P}.tar.gz"
43 +
44 +LICENSE="Apache-2.0"
45 +SLOT="0"
46 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
47 +IUSE="apparmor btrfs device-mapper +cri hardened +seccomp selinux test"
48 +
49 +DEPEND="
50 + btrfs? ( sys-fs/btrfs-progs )
51 + seccomp? ( sys-libs/libseccomp )
52 +"
53 +
54 +# recommended version of runc is found in script/setup/runc-version
55 +RDEPEND="
56 + ${DEPEND}
57 + ~app-emulation/runc-1.0.0
58 +"
59 +
60 +BDEPEND="
61 + dev-go/go-md2man
62 + virtual/pkgconfig
63 +"
64 +
65 +# tests require root or docker
66 +# upstream does not recommend stripping binary
67 +RESTRICT+=" strip test"
68 +
69 +src_prepare() {
70 + default
71 + sed -i \
72 + -e "s/-s -w//" \
73 + Makefile || die
74 + sed -i \
75 + -e "s:/usr/local:/usr:" \
76 + containerd.service || die
77 +}
78 +
79 +src_compile() {
80 + local options=(
81 + $(usev apparmor)
82 + $(usex btrfs "" "no_btrfs")
83 + $(usex cri "" "no_cri")
84 + $(usex device-mapper "" "no_devmapper")
85 + $(usev seccomp)
86 + $(usev selinux)
87 + )
88 +
89 + myemakeargs=(
90 + BUILDTAGS="${options[*]}"
91 + GO_BUILD_FLAGS="-mod vendor"
92 + LDFLAGS="$(usex hardened '-extldflags -fno-PIC' '')"
93 + REVISION=69107e47a62e1d690afa2b9b1d43f8ece3ff4483
94 + VERSION=v${PV}
95 + )
96 +
97 + # race condition in man target https://bugs.gentoo.org/765100
98 + # we need to explicitly specify GOFLAGS for "go run" to use vendor source
99 + GOFLAGS="-v -x -mod=vendor" emake "${myemakeargs[@]}" man -j1 #nowarn
100 + emake "${myemakeargs[@]}" all
101 +
102 +}
103 +
104 +src_install() {
105 + dobin bin/*
106 + doman man/*
107 + newinitd "${FILESDIR}"/${PN}.initd "${PN}"
108 + systemd_dounit containerd.service
109 + keepdir /var/lib/containerd
110 +
111 + # we already installed manpages, remove markdown source
112 + # before installing docs directory
113 + rm -r docs/man || die
114 +
115 + local DOCS=( ADOPTERS.md README.md RELEASES.md ROADMAP.md SCOPE.md docs/. )
116 + einstalldocs
117 +}