summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Hubbs <williamh@gentoo.org>2021-03-06 13:10:11 -0600
committerWilliam Hubbs <williamh@gentoo.org>2021-03-06 14:11:01 -0600
commita06bf471ae5392f243e4f28f64c154bb828b68c5 (patch)
treeba29bc0e3c728982174d8d25c0c431c40a9e3305 /app-emulation/docker-cli
parentapp-emulation/docker: 20.10.4 bump (diff)
downloadgentoo-a06bf471ae5392f243e4f28f64c154bb828b68c5.tar.gz
gentoo-a06bf471ae5392f243e4f28f64c154bb828b68c5.tar.bz2
gentoo-a06bf471ae5392f243e4f28f64c154bb828b68c5.zip
app-emulation/docker-cli: 20.10.4 bump
Signed-off-by: William Hubbs <williamh@gentoo.org>
Diffstat (limited to 'app-emulation/docker-cli')
-rw-r--r--app-emulation/docker-cli/Manifest1
-rw-r--r--app-emulation/docker-cli/docker-cli-20.10.4.ebuild64
2 files changed, 65 insertions, 0 deletions
diff --git a/app-emulation/docker-cli/Manifest b/app-emulation/docker-cli/Manifest
index 078e65cf8769..1802076d74ad 100644
--- a/app-emulation/docker-cli/Manifest
+++ b/app-emulation/docker-cli/Manifest
@@ -1,2 +1,3 @@
DIST docker-cli-20.10.2.tar.gz 7706210 BLAKE2B c8d537be8344dbd2113232c85a52f001231fdf653819710cf4492c86d58662e5f0d74f6fb00593d1034b5d481f15524cec89e2b3463900705a545b2051ab38d2 SHA512 907c846bf4043dcce4dd4e95e6335554b50e954464a83f75a44b1c0fcf9f2625c490a12758d18653c0d031768878a3f6fc91cb7fc6e1d3235d5e8f21ecd93caf
DIST docker-cli-20.10.3.tar.gz 7733821 BLAKE2B ab71e6817e7fe0d7c5f8c776cb25ae7bc49b5a224c835fe833988b67dfdf562207cd0afed4710d33e8a31156bd16bdc70df13f1194e862314add069c320c4e6e SHA512 769bed3e5409f6be570ab3672bef1bea4d16d5bfaeb81af8c4b3b7cfb56732c108c5404464731c001cf94fefd77c40a142bed80c85f1b058041e187453a6b88e
+DIST docker-cli-20.10.4.tar.gz 7735373 BLAKE2B 7bbdbaec4e97498c9d6aa66f9e6168afd7dc510f7746f94eff275a00bff23548562e8b879bc70c5018e0b75ebf609e0e68173bc244a441c739687d01eb8b9a3c SHA512 861f69657ac3eede228983b7d845ce98c81f4b0aa601aab37024d3f21cf1ca73a182d33bdde8fb9ad89e4954c3903dc4ec2b81fcf7364941a7c38a80ea410e34
diff --git a/app-emulation/docker-cli/docker-cli-20.10.4.ebuild b/app-emulation/docker-cli/docker-cli-20.10.4.ebuild
new file mode 100644
index 000000000000..2675134a9e69
--- /dev/null
+++ b/app-emulation/docker-cli/docker-cli-20.10.4.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+GIT_COMMIT=48d30b5b32
+EGO_PN="github.com/docker/cli"
+inherit bash-completion-r1 golang-vcs-snapshot
+
+DESCRIPTION="the command line binary for docker"
+HOMEPAGE="https://www.docker.com/"
+MY_PV=${PV/_/-}
+SRC_URI="https://github.com/docker/cli/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
+IUSE="hardened"
+
+RDEPEND="!<app-emulation/docker-20.10.1"
+BDEPEND="dev-go/go-md2man"
+
+RESTRICT="installsources strip"
+
+S="${WORKDIR}/${P}/src/${EGO_PN}"
+
+src_prepare() {
+ default
+ sed -i 's@dockerd\?\.exe@@g' contrib/completion/bash/docker || die
+ sed -i 's@md2man@go-md2man@' man/md2man-all.sh || die
+}
+
+src_compile() {
+ export DISABLE_WARN_OUTSIDE_CONTAINER=1
+ export GOPATH="${WORKDIR}/${P}"
+ # setup CFLAGS and LDFLAGS for separate build target
+ # see https://github.com/tianon/docker-overlay/pull/10
+ export CGO_CFLAGS="-I${ROOT}/usr/include"
+ export CGO_LDFLAGS="-L${ROOT}/usr/$(get_libdir)"
+ emake \
+ LDFLAGS="$(usex hardened '-extldflags -fno-PIC' '')" \
+ VERSION="$(cat VERSION)" \
+ GITCOMMIT="${GIT_COMMIT}" \
+ dynbinary
+
+ # build man pages
+ # see "cli/scripts/docs/generate-man.sh" (which also does "go get" for go-md2man)
+ go build -o "${T}"/gen-manpages ./man ||
+ die 'build gen-manpages failed'
+ "${T}"/gen-manpages --root "$(pwd)" --target "$(pwd)"/man/man1 ||
+ die 'gen-manpages failed'
+ ./man/md2man-all.sh -q ||
+ die 'md2man-all.sh failed'
+}
+
+src_install() {
+ dobin build/docker
+ doman man/man*/*
+ dobashcomp contrib/completion/bash/*
+ bashcomp_alias docker dockerd
+ insinto /usr/share/fish/vendor_completions.d/
+ doins contrib/completion/fish/docker.fish
+ insinto /usr/share/zsh/site-functions
+ doins contrib/completion/zsh/_*
+}