summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Kohler <bkohler@gentoo.org>2024-06-03 10:27:18 -0500
committerBen Kohler <bkohler@gentoo.org>2024-06-03 10:27:41 -0500
commit182b76a54b267df1ee45f39883302414886d5765 (patch)
treef39dbdfc881bcb8cc6da38350df2c174a1745052 /app-portage
parentapp-portage/elicense: enable py3.12 (diff)
downloadgentoo-182b76a54b267df1ee45f39883302414886d5765.tar.gz
gentoo-182b76a54b267df1ee45f39883302414886d5765.tar.bz2
gentoo-182b76a54b267df1ee45f39883302414886d5765.zip
app-portage/elicense: update EAPI 7 -> 8
Signed-off-by: Ben Kohler <bkohler@gentoo.org>
Diffstat (limited to 'app-portage')
-rw-r--r--app-portage/elicense/elicense-1.0.2-r1.ebuild36
1 files changed, 36 insertions, 0 deletions
diff --git a/app-portage/elicense/elicense-1.0.2-r1.ebuild b/app-portage/elicense/elicense-1.0.2-r1.ebuild
new file mode 100644
index 000000000000..382fdb97889f
--- /dev/null
+++ b/app-portage/elicense/elicense-1.0.2-r1.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( pypy3 python3_{9..12} )
+inherit distutils-r1
+
+if [[ ${PV} == "9999" ]]; then
+ EGIT_REPO_URI="https://github.com/Whissi/elicense.git"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/Whissi/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86"
+fi
+
+DESCRIPTION="Tool to find installed packages in Gentoo with non-accepted license(s)"
+HOMEPAGE="https://github.com/Whissi/elicense"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE=""
+
+RDEPEND=">=sys-apps/portage-2.3.62[${PYTHON_USEDEP}]"
+
+src_prepare() {
+ default
+
+ local MY_PV=${PV}
+ if [[ ${PV} == "9999" ]]; then
+ local last_commit=$(git rev-parse HEAD)
+ MY_PV="${last_commit:0:7}-git"
+ fi
+
+ sed -i -e "s/^MY_PV =.*$/MY_PV = \"${MY_PV}\"/" \
+ elicense || die "Failed to sed in version."
+}