Gentoo Archives: gentoo-commits

From: Conrad Kostecki <conikost@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lua/luacheck/
Date: Sun, 29 Nov 2020 01:33:07
Message-Id: 1606613545.46f4a77e32acc68fd335083575ce2124024afc27.conikost@gentoo
1 commit: 46f4a77e32acc68fd335083575ce2124024afc27
2 Author: Conrad Kostecki <conikost <AT> gentoo <DOT> org>
3 AuthorDate: Sun Nov 29 01:27:18 2020 +0000
4 Commit: Conrad Kostecki <conikost <AT> gentoo <DOT> org>
5 CommitDate: Sun Nov 29 01:32:25 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=46f4a77e
7
8 dev-lua/luacheck: add keywords and update deps
9
10 Also fixed tests.
11
12 Closes: https://bugs.gentoo.org/729794
13 Closes: https://bugs.gentoo.org/723156
14 Package-Manager: Portage-3.0.9, Repoman-3.0.2
15 Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>
16
17 dev-lua/luacheck/luacheck-0.23.0-r1.ebuild | 56 ++++++++++++++++++++++++++++++
18 1 file changed, 56 insertions(+)
19
20 diff --git a/dev-lua/luacheck/luacheck-0.23.0-r1.ebuild b/dev-lua/luacheck/luacheck-0.23.0-r1.ebuild
21 new file mode 100644
22 index 00000000000..47d0aed6d00
23 --- /dev/null
24 +++ b/dev-lua/luacheck/luacheck-0.23.0-r1.ebuild
25 @@ -0,0 +1,56 @@
26 +# Copyright 1999-2020 Gentoo Authors
27 +# Distributed under the terms of the GNU General Public License v2
28 +
29 +EAPI=7
30 +inherit toolchain-funcs
31 +
32 +DESCRIPTION="A tool for linting and static analysis of Lua code"
33 +HOMEPAGE="https://github.com/mpeterv/luacheck"
34 +SRC_URI="https://github.com/mpeterv/luacheck/archive/${PV}.tar.gz -> ${P}.tar.gz"
35 +
36 +LICENSE="MIT"
37 +SLOT="0"
38 +KEYWORDS="~amd64 ~arm ~ppc64"
39 +IUSE="doc luajit test"
40 +RESTRICT="!test? ( test )"
41 +
42 +RDEPEND="
43 + dev-lua/lua-argparse[luajit(-)=]
44 + dev-lua/luafilesystem[luajit(-)=]
45 + dev-lua/lua-utf8[luajit(-)=]
46 + !luajit? ( >=dev-lang/lua-5.1:= )
47 + luajit? ( dev-lang/luajit:2 )"
48 +BDEPEND="
49 + virtual/pkgconfig
50 + doc? ( dev-python/sphinx )
51 + test? (
52 + ${RDEPEND}
53 + dev-lua/busted
54 + )"
55 +DEPEND="${RDEPEND}"
56 +
57 +PATCHES=( "${FILESDIR}/${PN}-0.23.0-disable-measuring-performance-test.patch" )
58 +
59 +src_compile() {
60 + if use doc; then
61 + sphinx-build docsrc html || die
62 + fi
63 +}
64 +
65 +src_test() {
66 + busted -o gtest || die
67 +}
68 +
69 +src_install() {
70 + local instdir
71 + instdir="$($(tc-getPKG_CONFIG) --variable INSTALL_LMOD $(usex luajit 'luajit' 'lua'))"
72 + insinto "${instdir#${EPREFIX}}"
73 + doins -r src/luacheck
74 +
75 + newbin bin/luacheck.lua luacheck
76 +
77 + use doc && local HTML_DOCS=( html/. )
78 +
79 + local -a DOCS=( CHANGELOG.md LICENSE README.md )
80 + einstalldocs
81 +}