commit: 5c8bb383ef467c12f0f80969ab15dfb16a96d5ca Author: James Le Cuirot <chewi <AT> gentoo <DOT> org> AuthorDate: Thu May 8 13:21:51 2025 +0000 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> CommitDate: Thu May 8 23:45:10 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5c8bb383
app-containers/cri-tools: Don't try to build completions when cross-compiling This will generally not work. There is no way around it, short of building crictl for the build host, but go-env.eclass isn't designed for that, so it doesn't seem worth it. Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org> From: https://github.com/gentoo/gentoo/pull/41994 Signed-off-by: Zac Medico <zmedico <AT> gentoo.org> app-containers/cri-tools/cri-tools-1.33.0.ebuild | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/app-containers/cri-tools/cri-tools-1.33.0.ebuild b/app-containers/cri-tools/cri-tools-1.33.0.ebuild index 305a9474b453..36951e2741c7 100644 --- a/app-containers/cri-tools/cri-tools-1.33.0.ebuild +++ b/app-containers/cri-tools/cri-tools-1.33.0.ebuild @@ -3,7 +3,7 @@ EAPI=8 -inherit bash-completion-r1 go-env go-module +inherit bash-completion-r1 go-env go-module toolchain-funcs DESCRIPTION="CLI and validation tools for Kubelet Container Runtime (CRI)" HOMEPAGE="https://github.com/kubernetes-sigs/cri-tools" @@ -21,15 +21,19 @@ src_compile() { CRICTL="build/bin/${GOOS}/${GOARCH}/crictl" emake VERSION="${PV}" - "${CRICTL}" completion bash > crictl.bash || die - "${CRICTL}" completion zsh > crictl.zsh || die + if ! tc-is-cross-compiler; then + "${CRICTL}" completion bash > crictl.bash || die + "${CRICTL}" completion zsh > crictl.zsh || die + fi } src_install() { einstalldocs - dobin "${CRICTL}" - newbashcomp crictl.bash crictl - insinto /usr/share/zsh/site-functions - newins crictl.zsh _crictl + + if ! tc-is-cross-compiler; then + newbashcomp crictl.bash crictl + insinto /usr/share/zsh/site-functions + newins crictl.zsh _crictl + fi }
