dev-build/bazel-buildtools: bump to 8.2.0

Signed-off-by: Maciej Barć <xgqt@gentoo.org>
This commit is contained in:
Maciej Barć
2025-05-03 14:46:21 +02:00
parent d9b14ae0ee
commit e298ef6bd1
2 changed files with 71 additions and 0 deletions

View File

@@ -1,2 +1,4 @@
DIST bazel-buildtools-8.0.0-deps.tar.xz 3587652 BLAKE2B d33d6136591c1e1835cb2de4b707e324a53034284fa54ff4beaddad90f2cc23b2f6d6a1cca9c856d0de38b32efd03a34affafaf7c1e4f97c6c6e23b44febab28 SHA512 d2ab670cd16667e4034ae3342aec00b1916739debaa9280f8efb4d7c8c482366014c7055201e96b4cb1a327b9d8141613ecb13bf44d5ed73f9002433b784febe
DIST bazel-buildtools-8.0.3.gh.tar.gz 337647 BLAKE2B 67826fc7ed1b21ff2148acdb96c64b000291af0ce69b5c2750920299b47ccd1b978628828895e875663d2ed6f7392a71f11c71b39f1b274c8022f534e642bef6 SHA512 1d28c409090b2be4de3f02735cf00673fb59e64cfb492e30af79a52a048ae43f3ace56df041bf4402e967e2bef8e71fde897ac8e1dbeeaed30f63a359924647c
DIST bazel-buildtools-8.2.0-deps.tar.xz 3588700 BLAKE2B 82fe1d797e440645547a4ae318bc0b0072dd5047d0072a80510378c5f874e0219c20c082519eb55c6d3e8cbf28e3ce78505fc84ff2893de9cac481ecd8637522 SHA512 8fb81400bbc8a2333c18942799882491057e385b19c4227e8873628d83f909c86d4a6aeb551c064282d8d57bc1323bf1d3a837a8d00026682b0dc3c353ad9c9e
DIST bazel-buildtools-8.2.0.gh.tar.gz 337672 BLAKE2B e7ad07e9d9f4170cb82e274c91a7206016756ba37c51de6e39a08cd51c6696b3f0f51b66af9e87a85ac7c064a6fc16816851cc48cea0105327a07014a20236a4 SHA512 19d58df3b1a794e04eb25afcc4310be92dfc021643b23056adb89e66c2ef93c11475f6ef4c16347abaf66e79ef70655ca3ffaff5f701d6dd1eb9c88cba6cae10

View File

@@ -0,0 +1,69 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
REAL_PN="buildtools"
inherit go-module
DESCRIPTION="Tools for working with Google's Bazel BUILD files."
HOMEPAGE="https://github.com/bazelbuild/buildtools/"
if [[ "${PV}" == *9999* ]] ; then
inherit git-r3
EGIT_REPO_URI="https://github.com/bazelbuild/${REAL_PN}"
else
SRC_URI="https://github.com/bazelbuild/${REAL_PN}/archive/refs/tags/v${PV}.tar.gz
-> ${P}.gh.tar.gz"
S="${WORKDIR}/${REAL_PN}-${PV}"
KEYWORDS="~amd64 ~arm64 ~x86"
fi
SRC_URI+="
https://dev.gentoo.org/~xgqt/distfiles/deps/${PN}-8.2.0-deps.tar.xz
"
LICENSE="Apache-2.0"
SLOT="0"
DOCS=( README.md WARNINGS.md )
src_prepare() {
default
rm ./warn/docs/docs.go || die
}
src_compile() {
local go_ldopts="
-X main.buildScmRevision=v${PV}
-X main.buildVersion=${PV}
"
local -a go_buildopts=(
-ldflags "${go_ldopts}"
-o ./bin/
)
ego build "${go_buildopts[@]}" ./...
}
src_install() {
exeinto /usr/bin
doexe ./bin/{buildifier,buildozer}
newexe ./bin/generatetables bazel-generatetables
newexe ./bin/unused_deps bazel-unused_deps
local app=""
for app in buildifier buildozer unused_deps ; do
newdoc "${S}/${app}/README.md" "${app}.md"
done
einstalldocs
}
pkg_postinst() {
einfo 'The "generatetables" binary is installed as "bazel-generatetables"'
einfo 'and the "unused_deps" binary is installed as "bazel-unused_deps"'.
}