mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
dev-util/promu: update to 0.17.0
* significantly reduce deps tarball size 11 MiB -> 218 KiB * misc code refactoring Signed-off-by: Rahil Bhimjiani <me@rahil.rocks> Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
This commit is contained in:
committed by
Arthur Zamarin
parent
0b0bf14356
commit
25c38ea044
@@ -1,2 +1,4 @@
|
||||
DIST promu-0.15.0-deps.tar.xz 11022948 BLAKE2B e8f1a65dca92147c1f617dbfb7279c1eb45efcdc93a019c7a4fb9e9ff2895e71283e1368751e37732972554d7dce20ed08553f9e3111efa2b48eb0c86e191a06 SHA512 f4d1456969ea5454990ccebf81d49e857e3a6311b81dfcdb2538e82e8b7842d1020fd489567a10534759d44c69f6adb1e70f9de4b36c24286908c5758b8fd05d
|
||||
DIST promu-0.15.0.tar.gz 33465 BLAKE2B 83fae1e8cf663fe9aaedbdf66d86f3d4d7db0b14572cec9f0e9b25a205712cf19b137f6cafa3adcc0cbdd9177078a1bc696b9333ae830cf38de83e4837829abf SHA512 7e1de86c67b7a6d469e49b63431c9be1f93295f79225bfe409deef426c11c2f5273e185ef3b53ff5fd5fd41ddf7d9ddc79c2629e34a7ae2ec55adebdf8ff3b44
|
||||
DIST promu-0.17.0-deps.tar.xz 223468 BLAKE2B a6a77d265ae8ac158bfd96ff1f1ecf81b3481b31238a3edb5f8d4228508e334e5c6d8de03a42bf282dfd4832e1b717e5e9f442acfd9e01a4aa50495cfce27b91 SHA512 5bcfb24931f94f8ddf695ca7450d34987428ed090c1cf51025870a673d702adf07d29bd66c9e7118f615b480adcb3c35baa4d09b2e4089cc53447c6cbb54e455
|
||||
DIST promu-0.17.0.tar.gz 32994 BLAKE2B d7741d5d461af328ed60513a1ceefa827f42cadda7f51356840669ecd04563b9756cde8d29019b87531c11bd48bbc121f241d47fb9b1ee61823b0bb40fc4abb2 SHA512 8265fd0e9f37624dc1e6abdef87475b5116a7e7af260fc83bc3cda98409af78d4db9d409cd404e251cbf81c124e6a6cd5ab70eef6845ec33048da4937eac01dd
|
||||
|
||||
54
dev-util/promu/promu-0.17.0.ebuild
Normal file
54
dev-util/promu/promu-0.17.0.ebuild
Normal file
@@ -0,0 +1,54 @@
|
||||
# Copyright 1999-2024 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
inherit go-module
|
||||
|
||||
DESCRIPTION="Prometheus Utility Tool"
|
||||
HOMEPAGE="https://github.com/prometheus/promu"
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/prometheus/promu.git"
|
||||
else
|
||||
SRC_URI="
|
||||
https://github.com/prometheus/promu/archive/v${PV}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/rahilarious/gentoo-distfiles/releases/download/${P}/deps.tar.xz -> ${P}-deps.tar.xz
|
||||
"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~riscv ~x86"
|
||||
fi
|
||||
LICENSE="Apache-2.0"
|
||||
LICENSE+=" BSD BSD-2 MIT"
|
||||
SLOT="0"
|
||||
|
||||
RESTRICT+=" test"
|
||||
DOCS=(
|
||||
"doc/examples"
|
||||
"README.md"
|
||||
)
|
||||
|
||||
src_unpack() {
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
git-r3_src_unpack
|
||||
go-module_live_vendor
|
||||
else
|
||||
default
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
[[ ${PV} != 9999* ]] && { ln -sv ../vendor ./ || die ; }
|
||||
if use x86; then
|
||||
#917577 pie breaks build on x86
|
||||
GOFLAGS=${GOFLAGS//-buildmode=pie}
|
||||
fi
|
||||
emake build
|
||||
}
|
||||
|
||||
src_install() {
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
dobin "${PN}"
|
||||
else
|
||||
newbin "${P}" "${PN}"
|
||||
fi
|
||||
einstalldocs
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 1999-2023 Gentoo Authors
|
||||
# Copyright 1999-2024 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
@@ -6,12 +6,14 @@ inherit go-module
|
||||
|
||||
DESCRIPTION="Prometheus Utility Tool"
|
||||
HOMEPAGE="https://github.com/prometheus/promu"
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/prometheus/promu.git"
|
||||
else
|
||||
SRC_URI="https://github.com/prometheus/promu/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
SRC_URI+=" https://github.com/rahilarious/gentoo-distfiles/releases/download/${P}/deps.tar.xz -> ${P}-deps.tar.xz"
|
||||
SRC_URI="
|
||||
https://github.com/prometheus/promu/archive/v${PV}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/rahilarious/gentoo-distfiles/releases/download/${P}/deps.tar.xz -> ${P}-deps.tar.xz
|
||||
"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~loong ~riscv ~x86"
|
||||
fi
|
||||
LICENSE="Apache-2.0"
|
||||
@@ -25,15 +27,16 @@ DOCS=(
|
||||
)
|
||||
|
||||
src_unpack() {
|
||||
if [[ ${PV} == *9999* ]]; then
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
git-r3_src_unpack
|
||||
go-module_live_vendor
|
||||
else
|
||||
go-module_src_unpack
|
||||
default
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
[[ ${PV} != 9999* ]] && { ln -sv ../vendor ./ || die ; }
|
||||
if use x86; then
|
||||
#917577 pie breaks build on x86
|
||||
GOFLAGS=${GOFLAGS//-buildmode=pie}
|
||||
@@ -42,7 +45,7 @@ src_compile() {
|
||||
}
|
||||
|
||||
src_install() {
|
||||
if [[ ${PV} == *9999 ]]; then
|
||||
if [[ ${PV} == 9999* ]]; then
|
||||
dobin "${PN}"
|
||||
else
|
||||
newbin "${P}" "${PN}"
|
||||
|
||||
Reference in New Issue
Block a user