aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRahil Bhimjiani <me@rahil.rocks>2024-03-11 11:54:05 +0530
committerRahil Bhimjiani <me@rahil.rocks>2024-03-11 13:00:16 +0530
commit0549759e97978de023ca4eea47c27119713c96e0 (patch)
tree4cbbf18e4fdebee90af6fb9404c9530fe38f7762 /app-crypt
parentgames-emulation/conty: fix einfo executable name (diff)
downloadguru-0549759e97978de023ca4eea47c27119713c96e0.tar.gz
guru-0549759e97978de023ca4eea47c27119713c96e0.tar.bz2
guru-0549759e97978de023ca4eea47c27119713c96e0.zip
app-crypt/lego: add 4.16.1
* Only install html files when +doc Hot fix from upstream: 19bbefb fix: don't generate ARI cert ID if ARI is not enable (#2138) Signed-off-by: Rahil Bhimjiani <me@rahil.rocks>
Diffstat (limited to 'app-crypt')
-rw-r--r--app-crypt/lego/Manifest2
-rw-r--r--app-crypt/lego/lego-4.16.1.ebuild86
-rw-r--r--app-crypt/lego/lego-9999.ebuild18
3 files changed, 99 insertions, 7 deletions
diff --git a/app-crypt/lego/Manifest b/app-crypt/lego/Manifest
index 3d4c7d79e..0cc3a5acf 100644
--- a/app-crypt/lego/Manifest
+++ b/app-crypt/lego/Manifest
@@ -7,3 +7,5 @@ DIST lego-4.15.0.tar.gz 683931 BLAKE2B b4bcdca4ea72e7826b690b15c297b37c186567d01
DIST lego-4.16.0-deps.tar.xz 211637812 BLAKE2B ce3089dd2f355a72e6cf81309ae389a01eb65ce832e38065174997636b9b62e742ef7cddb3aa5ab9a8657b2d643b0e190b8f75fc9b767d74fcebb71e0d860146 SHA512 62fd86bef1163c5b0f8a3a3540e7fe94ccee1b097449c42f0d5267894a4e0931a89c0f8e2e2af0f37757c7a4f25fe0d27a305aa51490b7f522ec23b9267b7eb9
DIST lego-4.16.0-docs.tar.gz 3681408 BLAKE2B 3be8f0a8d9aaa13e4ff3bf0bd8b928bc7be0e1bec0dd31cc5e91cd1ae7d19a6952fe81a3db5c89d296642325b897e436acacf1e18975fdf5cbe34d0b1e1e7371 SHA512 80819d4496cd2cabf1d9eb8f254b240edf43e01a01c2de28274799986bee7f9a8698fc8dbba000d8e4e37b2d68e4a9f772214a237321077dedbe3a0657666244
DIST lego-4.16.0.tar.gz 698821 BLAKE2B 9058f856a477c70c12352df4786e18dadf444df60ed462411367a8aa18ce1e98ede4358e6aad8032d5d3230341fd7e544343bda27fd92c46c494e0a5eb683f35 SHA512 ba40fdcd94cb1f12d609104d1af5c8e398f3a3d70e4d2a0b65365b401b6928149749778de9acb138e9548d634ea210641c07d2218135f2e4c903a39947f206e5
+DIST lego-4.16.1-docs.tar.gz 3681606 BLAKE2B 9f80ba3f132eb08b06a960c8a9bdcf372a7925bdc931a078385ff1b6b9f01981d76758c15cc3f8c35f48e461bdc84f5a4d6a7b9a6b1aadbda249ca4d27459bc3 SHA512 1c953edd93b6d56b0b1bd48519b745d7ebfce9df76d6c92cccde88e4aff814de19d9a68e3d949f517530acaf738def97550d1a866e156a8d03e9ff644766df35
+DIST lego-4.16.1.tar.gz 698801 BLAKE2B 005be7bf3462d941de99c46b659776f2b69b9298819a23009060fbf0f7532c62eae3512c10619f034916eaa3c20b9607d78786cf5ec023df139cc6c186b0df20 SHA512 a65c661fc003cc26c13ed6b38719a0ab49a8fe8e2a18c59c84e5c974b918aaf0c55c92015d2794a17b4fe5ac31c3557a4d5e1971527441b8bdf80907fe4b90e9
diff --git a/app-crypt/lego/lego-4.16.1.ebuild b/app-crypt/lego/lego-4.16.1.ebuild
new file mode 100644
index 000000000..c012524d5
--- /dev/null
+++ b/app-crypt/lego/lego-4.16.1.ebuild
@@ -0,0 +1,86 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit go-module
+
+DESCRIPTION="Let's Encrypt/ACME client (like certbot or acme.sh) and library written in Go"
+HOMEPAGE="https://github.com/go-acme/lego/"
+
+DOCUMENTATION_COMMIT=14be9e1e1c33a1e370b7fc76ebe3e6fba938c87d
+
+if [[ ${PV} == 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/go-acme/lego.git"
+else
+ SRC_URI="
+ https://github.com/go-acme/lego/archive/v${PV}.tar.gz -> ${P}.tar.gz
+ https://github.com/rahilarious/gentoo-distfiles/releases/download/${PN}-4.16.0/deps.tar.xz -> ${PN}-4.16.0-deps.tar.xz
+ doc? ( https://github.com/go-acme/lego/archive/${DOCUMENTATION_COMMIT}.tar.gz -> ${P}-docs.tar.gz )
+"
+ KEYWORDS="~amd64 ~arm64"
+fi
+
+# main
+LICENSE="MIT"
+# deps
+LICENSE+=" Apache-2.0 BSD-2 BSD ISC MPL-2.0"
+SLOT="0"
+IUSE="doc"
+
+# some tests require network access otherwise get following error
+# expected: "zoneee: unexpected status code: [status code: 401] body: Unauthorized"
+# actual : "zoneee: could not find zone for domain \"prefix.example.com\" (_acme-challenge.prefix.example.com.): could not find the start of authority for _acme-challenge.prefix.example.com.: read udp 10.0.0.1:54729->10.0.0.1:53: read: connection refused"
+PROPERTIES="test_network"
+RESTRICT="test"
+
+src_unpack() {
+ if [[ ${PV} == 9999* ]]; then
+ git-r3_src_unpack
+ go-module_live_vendor
+ if use doc; then
+ EGIT_BRANCH="gh-pages"
+ EGIT_CHECKOUT_DIR="${WORKDIR}/${PN}-${DOCUMENTATION_COMMIT}"
+ git-r3_src_unpack
+ fi
+ else
+ go-module_src_unpack
+ fi
+}
+
+src_prepare() {
+ default
+ if use doc; then
+ find ../"${PN}"-"${DOCUMENTATION_COMMIT}"/ -type f -not -name '*.html' -delete || die
+ fi
+
+}
+
+src_compile() {
+ export CGO_ENABLED=0
+
+ local VERSION
+ if [[ ${PV} == 9999* ]]; then
+ VERSION="$(git rev-parse HEAD)" || die
+ else
+ VERSION="${PV}"
+ fi
+
+ ego build -trimpath -ldflags "-X main.version=${VERSION}" -o dist/"${PN}" ./cmd/lego/
+}
+
+src_test() {
+ ego test -v -cover ./...
+}
+
+src_install() {
+ # primary program
+ dobin dist/"${PN}"
+
+ # docs
+ einstalldocs
+ if use doc; then
+ dodoc -r ../"${PN}"-"${DOCUMENTATION_COMMIT}"/*
+ fi
+}
diff --git a/app-crypt/lego/lego-9999.ebuild b/app-crypt/lego/lego-9999.ebuild
index 3c984d15f..c4ae98059 100644
--- a/app-crypt/lego/lego-9999.ebuild
+++ b/app-crypt/lego/lego-9999.ebuild
@@ -8,7 +8,7 @@ inherit go-module
DESCRIPTION="Let's Encrypt/ACME client (like certbot or acme.sh) and library written in Go"
HOMEPAGE="https://github.com/go-acme/lego/"
-DOCUMENTATION_COMMIT=1f91ea806ff8f3184b7f4e00fc6e69b1e23a08a2
+DOCUMENTATION_COMMIT=14be9e1e1c33a1e370b7fc76ebe3e6fba938c87d
if [[ ${PV} == 9999* ]]; then
inherit git-r3
@@ -41,7 +41,7 @@ src_unpack() {
go-module_live_vendor
if use doc; then
EGIT_BRANCH="gh-pages"
- EGIT_CHECKOUT_DIR="${WORKDIR}/${P}-doc"
+ EGIT_CHECKOUT_DIR="${WORKDIR}/${PN}-${DOCUMENTATION_COMMIT}"
git-r3_src_unpack
fi
else
@@ -49,6 +49,14 @@ src_unpack() {
fi
}
+src_prepare() {
+ default
+ if use doc; then
+ find ../"${PN}"-"${DOCUMENTATION_COMMIT}"/ -type f -not -name '*.html' -delete || die
+ fi
+
+}
+
src_compile() {
export CGO_ENABLED=0
@@ -73,10 +81,6 @@ src_install() {
# docs
einstalldocs
if use doc; then
- if [[ ${PV} == 9999* ]]; then
- dodoc -r ../"${P}"-doc/*
- else
- dodoc -r ../"${PN}"-"${DOCUMENTATION_COMMIT}"/*
- fi
+ dodoc -r ../"${PN}"-"${DOCUMENTATION_COMMIT}"/*
fi
}