1 |
commit: d9b9e95eabfbc5ad096c5e78311db6333d62ce8c |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Sep 9 05:00:36 2021 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Sep 9 05:02:03 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d9b9e95e |
7 |
|
8 |
app-emulation/podman: Bump to version 3.3.1 |
9 |
|
10 |
Package-Manager: Portage-3.0.20, Repoman-3.0.3 |
11 |
Signed-off-by: Zac Medico <zmedico <AT> gentoo.org> |
12 |
|
13 |
app-emulation/podman/Manifest | 1 + |
14 |
app-emulation/podman/podman-3.3.1.ebuild | 164 +++++++++++++++++++++++++++++++ |
15 |
2 files changed, 165 insertions(+) |
16 |
|
17 |
diff --git a/app-emulation/podman/Manifest b/app-emulation/podman/Manifest |
18 |
index 232a6f84918..49d6dd8ba29 100644 |
19 |
--- a/app-emulation/podman/Manifest |
20 |
+++ b/app-emulation/podman/Manifest |
21 |
@@ -1,2 +1,3 @@ |
22 |
DIST podman-3.1.2.tar.gz 10488539 BLAKE2B 8536f6856e436467541f7714e75d5055545e1514604d6541671894117e752609a9e791355c162ef8fcdbc0cbd992823ecab8a3ab760bab3a469d9768b6b008e4 SHA512 fdc26368f3cce6a11fe9adeae34a2f04396a554bb5f245e07fc98d1ce21dff66faba5549e9e0b94793d67768ff03fea2990e7a2759dd41ed2b72778431f5dd9d |
23 |
DIST podman-3.2.1.tar.gz 10754823 BLAKE2B 6c4e7292ba30969ef8632ad514a87650131a05baafab65d49fe182bddaa1b106de5766ec6677b73d0a2e5166c56f1439de6c800ca7de8ac59e026de1286bf2d4 SHA512 8fa4e2a72d1e655c600fa4dc7ad2366975314a154ff9fa7496622da6042e54c6fe93aca0344e6615e2ce3d400c1bc5de7d8462df45f950a119c3303b3ae520e4 |
24 |
+DIST podman-3.3.1.tar.gz 10917305 BLAKE2B fe7856c2ad8893e40ec42fb242a088794ea18910388d5e8089885013cab45c98e03bef99a5e911749f95ce469518e6fa5b6d30400f52696645c9ba8c140ba445 SHA512 19003f63c17c1c5788f34d0d6426a366035fc76aa2312e6355464d204d6536e5f78652abaf01643d4be7c2ee5224c25717b41760a4be4f6de8031cca9b06efaa |
25 |
|
26 |
diff --git a/app-emulation/podman/podman-3.3.1.ebuild b/app-emulation/podman/podman-3.3.1.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..090d5367af6 |
29 |
--- /dev/null |
30 |
+++ b/app-emulation/podman/podman-3.3.1.ebuild |
31 |
@@ -0,0 +1,164 @@ |
32 |
+# Copyright 1999-2021 Gentoo Authors |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=7 |
36 |
+EGIT_COMMIT="152952fe6b18581615c3efd1fafef2d8142738e8" |
37 |
+ |
38 |
+inherit bash-completion-r1 flag-o-matic go-module tmpfiles |
39 |
+ |
40 |
+DESCRIPTION="Library and podman tool for running OCI-based containers in Pods" |
41 |
+HOMEPAGE="https://github.com/containers/podman/" |
42 |
+MY_PN=podman |
43 |
+MY_P=${MY_PN}-${PV} |
44 |
+SRC_URI="https://github.com/containers/podman/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz" |
45 |
+LICENSE="Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT MPL-2.0" |
46 |
+SLOT="0" |
47 |
+ |
48 |
+KEYWORDS="~amd64 ~arm64 ~ppc64" |
49 |
+IUSE="apparmor btrfs +fuse +rootless selinux" |
50 |
+RESTRICT="test" |
51 |
+ |
52 |
+COMMON_DEPEND=" |
53 |
+ app-crypt/gpgme:= |
54 |
+ >=app-emulation/conmon-2.0.0 |
55 |
+ || ( >=app-emulation/runc-1.0.0_rc6 app-emulation/crun ) |
56 |
+ dev-libs/libassuan:= |
57 |
+ dev-libs/libgpg-error:= |
58 |
+ >=net-misc/cni-plugins-0.8.6 |
59 |
+ sys-fs/lvm2 |
60 |
+ sys-libs/libseccomp:= |
61 |
+ |
62 |
+ apparmor? ( sys-libs/libapparmor ) |
63 |
+ btrfs? ( sys-fs/btrfs-progs ) |
64 |
+ rootless? ( app-emulation/slirp4netns ) |
65 |
+ selinux? ( sys-libs/libselinux:= ) |
66 |
+" |
67 |
+DEPEND=" |
68 |
+ ${COMMON_DEPEND} |
69 |
+ dev-go/go-md2man" |
70 |
+RDEPEND="${COMMON_DEPEND} |
71 |
+ fuse? ( sys-fs/fuse-overlayfs )" |
72 |
+ |
73 |
+S=${WORKDIR}/${MY_P} |
74 |
+ |
75 |
+src_prepare() { |
76 |
+ default |
77 |
+ |
78 |
+ # Disable installation of python modules here, since those are |
79 |
+ # installed by separate ebuilds. |
80 |
+ local makefile_sed_args=( |
81 |
+ -e '/^GIT_.*/d' |
82 |
+ -e 's/$(GO) build/$(GO) build -v -work -x/' |
83 |
+ -e 's/^\(install:.*\) install\.python$/\1/' |
84 |
+ -e 's|^pkg/varlink/iopodman.go: .gopathok pkg/varlink/io.podman.varlink$|pkg/varlink/iopodman.go: pkg/varlink/io.podman.varlink|' |
85 |
+ ) |
86 |
+ |
87 |
+ has_version -b '>=dev-lang/go-1.13.9' || makefile_sed_args+=(-e 's:GO111MODULE=off:GO111MODULE=on:') |
88 |
+ |
89 |
+ sed "${makefile_sed_args[@]}" -i Makefile || die |
90 |
+ |
91 |
+ sed -e 's|OUTPUT="${CIRRUS_TAG:.*|OUTPUT='v${PV}'|' \ |
92 |
+ -i hack/get_release_info.sh || die |
93 |
+} |
94 |
+ |
95 |
+src_compile() { |
96 |
+ local git_commiT=${EGIT_COMMIT} |
97 |
+ |
98 |
+ # Filter unsupported linker flags |
99 |
+ filter-flags '-Wl,*' |
100 |
+ |
101 |
+ [[ -f hack/apparmor_tag.sh ]] || die |
102 |
+ if use apparmor; then |
103 |
+ echo -e "#!/bin/sh\necho apparmor" > hack/apparmor_tag.sh || die |
104 |
+ else |
105 |
+ echo -e "#!/bin/sh\ntrue" > hack/apparmor_tag.sh || die |
106 |
+ fi |
107 |
+ |
108 |
+ [[ -f hack/btrfs_installed_tag.sh ]] || die |
109 |
+ if use btrfs; then |
110 |
+ echo -e "#!/bin/sh\ntrue" > hack/btrfs_installed_tag.sh || die |
111 |
+ else |
112 |
+ echo -e "#!/bin/sh\necho exclude_graphdriver_btrfs" > \ |
113 |
+ hack/btrfs_installed_tag.sh || die |
114 |
+ fi |
115 |
+ |
116 |
+ [[ -f hack/selinux_tag.sh ]] || die |
117 |
+ if use selinux; then |
118 |
+ echo -e "#!/bin/sh\necho selinux" > hack/selinux_tag.sh || die |
119 |
+ else |
120 |
+ echo -e "#!/bin/sh\ntrue" > hack/selinux_tag.sh || die |
121 |
+ fi |
122 |
+ |
123 |
+ # Avoid this error when generating pkg/varlink/iopodman.go: |
124 |
+ # cannot find package "github.com/varlink/go/varlink/idl" |
125 |
+ mkdir -p _output || die |
126 |
+ ln -snf ../vendor _output/src || die |
127 |
+ GO111MODULE=off GOPATH=${PWD}/_output go generate ./pkg/varlink/... || die |
128 |
+ rm _output/src || die |
129 |
+ |
130 |
+ export -n GOCACHE GOPATH XDG_CACHE_HOME |
131 |
+ GOBIN="${S}/bin" \ |
132 |
+ emake all \ |
133 |
+ GIT_BRANCH=master \ |
134 |
+ GIT_BRANCH_CLEAN=master \ |
135 |
+ COMMIT_NO="${git_commit}" \ |
136 |
+ GIT_COMMIT="${git_commit}" |
137 |
+} |
138 |
+ |
139 |
+src_install() { |
140 |
+ emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install |
141 |
+ |
142 |
+ insinto /etc/containers |
143 |
+ newins test/registries.conf registries.conf.example |
144 |
+ newins test/policy.json policy.json.example |
145 |
+ |
146 |
+ insinto /usr/share/containers |
147 |
+ doins vendor/github.com/containers/common/pkg/seccomp/seccomp.json |
148 |
+ |
149 |
+ newconfd "${FILESDIR}"/podman.confd podman |
150 |
+ newinitd "${FILESDIR}"/podman.initd podman |
151 |
+ |
152 |
+ insinto /etc/logrotate.d |
153 |
+ newins "${FILESDIR}/podman.logrotated" podman |
154 |
+ |
155 |
+ dobashcomp completions/bash/* |
156 |
+ |
157 |
+ insinto /usr/share/zsh/site-functions |
158 |
+ doins completions/zsh/* |
159 |
+ |
160 |
+ insinto /usr/share/fish/vendor_completions.d |
161 |
+ doins completions/fish/* |
162 |
+ |
163 |
+ keepdir /var/lib/containers |
164 |
+} |
165 |
+ |
166 |
+pkg_preinst() { |
167 |
+ PODMAN_ROOTLESS_UPGRADE=false |
168 |
+ if use rootless; then |
169 |
+ has_version 'app-emulation/podman[rootless]' || PODMAN_ROOTLESS_UPGRADE=true |
170 |
+ fi |
171 |
+} |
172 |
+ |
173 |
+pkg_postinst() { |
174 |
+ tmpfiles_process podman.conf |
175 |
+ |
176 |
+ local want_newline=false |
177 |
+ if [[ ! ( -e ${EROOT%/*}/etc/containers/policy.json && -e ${EROOT%/*}/etc/containers/registries.conf ) ]]; then |
178 |
+ elog "You need to create the following config files:" |
179 |
+ elog "/etc/containers/registries.conf" |
180 |
+ elog "/etc/containers/policy.json" |
181 |
+ elog "To copy over default examples, use:" |
182 |
+ elog "cp /etc/containers/registries.conf{.example,}" |
183 |
+ elog "cp /etc/containers/policy.json{.example,}" |
184 |
+ want_newline=true |
185 |
+ fi |
186 |
+ if [[ ${PODMAN_ROOTLESS_UPGRADE} == true ]] ; then |
187 |
+ ${want_newline} && elog "" |
188 |
+ elog "For rootless operation, you need to configure subuid/subgid" |
189 |
+ elog "for user running podman. In case subuid/subgid has only been" |
190 |
+ elog "configured for root, run:" |
191 |
+ elog "usermod --add-subuids 1065536-1131071 <user>" |
192 |
+ elog "usermod --add-subgids 1065536-1131071 <user>" |
193 |
+ want_newline=true |
194 |
+ fi |
195 |
+} |