Gentoo Archives: gentoo-commits

From: Conrad Kostecki <conikost@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: profiles/, dev-lua/lua-argparse/
Date: Sun, 29 Nov 2020 01:33:06
Message-Id: 1606613542.675f7bbe8591f55534e6ff5a5d88e16f59751193.conikost@gentoo
1 commit: 675f7bbe8591f55534e6ff5a5d88e16f59751193
2 Author: Conrad Kostecki <conikost <AT> gentoo <DOT> org>
3 AuthorDate: Sun Nov 29 00:21:27 2020 +0000
4 Commit: Conrad Kostecki <conikost <AT> gentoo <DOT> org>
5 CommitDate: Sun Nov 29 01:32:22 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=675f7bbe
7
8 dev-lua/lua-argparse: migrate to lua eclass
9
10 Closes: https://bugs.gentoo.org/752924
11 Package-Manager: Portage-3.0.9, Repoman-3.0.2
12 Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>
13
14 .../lua-argparse/lua-argparse-0.6.0-r100.ebuild | 60 ++++++++++++++++++++++
15 dev-lua/lua-argparse/metadata.xml | 4 ++
16 profiles/package.mask | 1 +
17 3 files changed, 65 insertions(+)
18
19 diff --git a/dev-lua/lua-argparse/lua-argparse-0.6.0-r100.ebuild b/dev-lua/lua-argparse/lua-argparse-0.6.0-r100.ebuild
20 new file mode 100644
21 index 00000000000..ea350b4d10e
22 --- /dev/null
23 +++ b/dev-lua/lua-argparse/lua-argparse-0.6.0-r100.ebuild
24 @@ -0,0 +1,60 @@
25 +# Copyright 1999-2020 Gentoo Authors
26 +# Distributed under the terms of the GNU General Public License v2
27 +
28 +EAPI=7
29 +
30 +LUA_COMPAT=( lua5-{1..3} luajit )
31 +
32 +inherit lua toolchain-funcs
33 +
34 +DESCRIPTION="Command line argument parser for the Lua Programming Language"
35 +HOMEPAGE="https://github.com/mpeterv/argparse"
36 +SRC_URI="https://github.com/mpeterv/${PN/lua-/}/archive/${PV}.tar.gz -> ${P}.tar.gz"
37 +S="${WORKDIR}/${PN//lua-/}-${PV}"
38 +
39 +LICENSE="MIT"
40 +SLOT="0"
41 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
42 +IUSE="doc test"
43 +
44 +RESTRICT="!test? ( test )"
45 +
46 +RDEPEND="${LUA_DEPS}"
47 +DEPEND="${RDEPEND}"
48 +BDEPEND="
49 + virtual/pkgconfig
50 + doc? ( dev-python/sphinx )
51 + test? (
52 + >=dev-lua/busted-2.0.0-r100[${LUA_USEDEP}]
53 + ${RDEPEND}
54 + )
55 +"
56 +
57 +src_compile() {
58 + if use doc; then
59 + sphinx-build docsrc html || die
60 + rm -rf "${S}"/html/{.doctrees,_sources} || die
61 + fi
62 +}
63 +
64 +lua_src_test() {
65 + busted --exclude-tags="unsafe" --lua=${ELUA} || die
66 +}
67 +
68 +src_test() {
69 + lua_foreach_impl lua_src_test
70 +}
71 +
72 +lua_src_install() {
73 + insinto "$(lua_get_lmod_dir)"
74 + doins src/argparse.lua
75 +}
76 +
77 +src_install() {
78 + default
79 +
80 + use doc && local -a HTML_DOCS=( "html/." )
81 + einstalldocs
82 +
83 + lua_foreach_impl lua_src_install
84 +}
85
86 diff --git a/dev-lua/lua-argparse/metadata.xml b/dev-lua/lua-argparse/metadata.xml
87 index 3af62013677..5ec193fa4b3 100644
88 --- a/dev-lua/lua-argparse/metadata.xml
89 +++ b/dev-lua/lua-argparse/metadata.xml
90 @@ -1,6 +1,10 @@
91 <?xml version="1.0" encoding="UTF-8"?>
92 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
93 <pkgmetadata>
94 + <maintainer type="person">
95 + <email>conikost@×××××.com</email>
96 + <name>Conrad Kostecki</name>
97 + </maintainer>
98 <maintainer type="person">
99 <email>vpayno+gentoo@×××××.com</email>
100 <name>Victor Payno</name>
101
102 diff --git a/profiles/package.mask b/profiles/package.mask
103 index 23342c0de62..2eaf9456d62 100644
104 --- a/profiles/package.mask
105 +++ b/profiles/package.mask
106 @@ -513,6 +513,7 @@ dev-lua/luacrypto
107 >=dev-lua/dkjson-2.5-r100
108 >=dev-lua/ldoc-1.4.6-r100
109 >=dev-lua/lpeg-1.0.2-r100
110 +>=dev-lua/lua-argparse-0.6.0-r100
111 >=dev-lua/lua-bit32-5.3.5-r100
112 >=dev-lua/lua-utf8-0.1.3-r100
113 >=dev-lua/lua-zlib-1.2-r100