commit:     d381ac05a62802104385f955708720a588a0054c
Author:     Haelwenn (lanodan) Monnier <contact <AT> hacktivis <DOT> me>
AuthorDate: Tue Nov  3 16:14:53 2020 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu Dec  3 07:59:20 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d381ac05

app-editors/vis: Add lua support

Mostly based on prior work comitted into ::lua repository

Closes: https://bugs.gentoo.org/752540
Signed-off-by: Haelwenn (lanodan) Monnier <contact <AT> hacktivis.me>
Closes: https://github.com/gentoo/gentoo/pull/18120
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 app-editors/vis/vis-0.6.ebuild  | 10 +++++++---
 app-editors/vis/vis-9999.ebuild | 11 +++++++----
 profiles/base/package.use.mask  |  4 ++++
 3 files changed, 18 insertions(+), 7 deletions(-)

diff --git a/app-editors/vis/vis-0.6.ebuild b/app-editors/vis/vis-0.6.ebuild
index 7a2ce6eaaa6..b624dd79c35 100644
--- a/app-editors/vis/vis-0.6.ebuild
+++ b/app-editors/vis/vis-0.6.ebuild
@@ -4,6 +4,9 @@
 EAPI=7
 
 MY_PTV=0.4
+LUA_COMPAT=( lua5-2 lua5-3 )
+
+inherit lua-single eutils
 
 DESCRIPTION="modern, legacy free, simple yet efficient vim-like editor"
 HOMEPAGE="https://github.com/martanne/vis";
@@ -12,14 +15,13 @@ 
SRC_URI="https://github.com/martanne/vis/releases/download/v${PV}/${P}.tar.gz
 LICENSE="ISC"
 SLOT="0"
 KEYWORDS="~amd64 ~arm ~x86"
-IUSE="+ncurses selinux test tre"
+IUSE="+ncurses +lua selinux test tre"
 RESTRICT="!test? ( test )"
 
 # - Known to also work with NetBSD curses
-# - ::lua package done for using >=dev-lang/lua-5.2
-# which is needed for syntax highlighting and settings but masked in ::gentoo
 DEPEND="dev-libs/libtermkey
        ncurses? ( sys-libs/ncurses:0= )
+       lua? ( ${LUA_DEPS} )
        tre? ( dev-libs/tre:= )"
 RDEPEND="${DEPEND}
        app-eselect/eselect-vi"
@@ -44,6 +46,7 @@ src_configure() {
        ./configure \
                --prefix="${EPREFIX}"/usr \
                --docdir="${EPREFIX}"/usr/share/doc/${PF} \
+               $(use_enable lua) \
                $(use_enable ncurses curses) \
                $(use_enable selinux) \
                $(use_enable tre) || die
@@ -60,4 +63,5 @@ pkg_postrm() {
 
 pkg_postinst() {
        update_symlinks
+       optfeature "syntax highlighting support" dev-lua/lpeg
 }

diff --git a/app-editors/vis/vis-9999.ebuild b/app-editors/vis/vis-9999.ebuild
index 600b5efb057..7af054d1607 100644
--- a/app-editors/vis/vis-9999.ebuild
+++ b/app-editors/vis/vis-9999.ebuild
@@ -2,7 +2,9 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
-inherit git-r3
+LUA_COMPAT=( lua5-2 lua5-3 )
+
+inherit lua-single git-r3 eutils
 
 DESCRIPTION="modern, legacy free, simple yet efficient vim-like editor"
 HOMEPAGE="https://github.com/martanne/vis";
@@ -10,14 +12,13 @@ EGIT_REPO_URI="https://github.com/martanne/vis.git";
 LICENSE="ISC"
 SLOT="0"
 KEYWORDS=""
-IUSE="+ncurses selinux test tre"
+IUSE="+ncurses +lua selinux test tre"
 RESTRICT="!test? ( test )"
 
 # - Known to also work with NetBSD curses
-# - ::lua package done for using >=dev-lang/lua-5.2
-# which is needed for syntax highlighting and settings but masked in ::gentoo
 DEPEND="dev-libs/libtermkey
        ncurses? ( sys-libs/ncurses:0= )
+       lua? ( ${LUA_DEPS} )
        tre? ( dev-libs/tre:= )"
 RDEPEND="${DEPEND}
        app-eselect/eselect-vi"
@@ -34,6 +35,7 @@ src_configure() {
        ./configure \
                --prefix="${EPREFIX}"/usr \
                --docdir="${EPREFIX}"/usr/share/doc/${PF} \
+               $(use_enable lua) \
                $(use_enable ncurses curses) \
                $(use_enable selinux) \
                $(use_enable tre) || die
@@ -50,4 +52,5 @@ pkg_postrm() {
 
 pkg_postinst() {
        update_symlinks
+       optfeature "syntax highlighting support" dev-lua/lpeg
 }

diff --git a/profiles/base/package.use.mask b/profiles/base/package.use.mask
index 6c2057de852..1a6df6d45e4 100644
--- a/profiles/base/package.use.mask
+++ b/profiles/base/package.use.mask
@@ -35,6 +35,10 @@ kde-apps/kipi-plugins vkontakte
 # waiting for lua to be slotted
 media-gfx/exact-image lua
 
+# Haelwenn (lanodan) Monnier <cont...@hacktivis.me> (2020-11-03)
+# Requires >=dev-lang/lua-5.2, which is still masked.
+app-editors/vis lua
+
 # Marek Szuba <mare...@gentoo.org> (2020-10-12)
 # Requires slotted Lua, which is still masked.
 media-gfx/darktable system-lua

Reply via email to