commit:     f3fdffac9209a6a66dd37d666109d1be57da8c9b
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 30 18:27:50 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Nov 30 18:32:07 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f3fdffac

games-puzzle/fish-fillets: migrate to lua-single.eclass

Uses pkgconfig to find unversioned Lua so works perfectly with the wrapper
provided by the eclass. As for LUA_COMPAT, let's stick with 5.1 - the code
itself appears to have been written for 5.0 and there are so many runtime
scripts that evaluating their compatibility with newer Lua versions would
be too much work.

Closes: https://bugs.gentoo.org/752690
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 .../fish-fillets/fish-fillets-1.0.1-r100.ebuild    | 61 ++++++++++++++++++++++
 profiles/package.mask                              |  1 +
 2 files changed, 62 insertions(+)

diff --git a/games-puzzle/fish-fillets/fish-fillets-1.0.1-r100.ebuild 
b/games-puzzle/fish-fillets/fish-fillets-1.0.1-r100.ebuild
new file mode 100644
index 00000000000..196ab712fb4
--- /dev/null
+++ b/games-puzzle/fish-fillets/fish-fillets-1.0.1-r100.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+LUA_COMPAT=( lua5-1 )
+
+inherit autotools desktop lua-single
+
+DATA_PV="1.0.0"
+DESCRIPTION="Underwater puzzle game - find a safe way out"
+HOMEPAGE="http://fillets.sourceforge.net/";
+SRC_URI="mirror://sourceforge/fillets/fillets-ng-${PV}.tar.gz
+       mirror://sourceforge/fillets/fillets-ng-data-${DATA_PV}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+REQUIRED_USE="${LUA_REQUIRED_USE}"
+
+RDEPEND="${LUA_DEPS}
+       >=media-libs/libsdl-1.2[sound,video]
+       >=media-libs/sdl-mixer-1.2.5[vorbis]
+       >=media-libs/sdl-image-1.2.2[png]
+       media-libs/smpeg
+       x11-libs/libX11
+       media-libs/sdl-ttf
+       dev-libs/fribidi
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+S="${WORKDIR}/fillets-ng-${PV}"
+
+src_prepare() {
+       default
+       #.mod was renamed to .fmod in lua 5.1.3 - bug #223271
+       sed -i \
+               -e 's/\.mod(/.fmod(/' \
+               $(grep -rl "\.mod\>" "${WORKDIR}"/fillets-ng-data-${DATA_PV}) \
+               || die "sed failed"
+       rm -f missing
+       mv configure.in configure.ac || die
+       eautoreconf
+}
+
+src_configure() {
+       econf --datadir="/usr/share/${PN}"
+}
+
+src_install() {
+       default
+       insinto "/usr/share/${PN}"
+       cd "${WORKDIR}"/fillets-ng-data-${DATA_PV} || die
+       rm -f COPYING
+       einstalldocs
+       doins -r *
+       newicon images/icon.png ${PN}.png
+       make_desktop_entry fillets "Fish Fillets NG"
+}

diff --git a/profiles/package.mask b/profiles/package.mask
index 8aa2d3de29b..4117f527e87 100644
--- a/profiles/package.mask
+++ b/profiles/package.mask
@@ -562,6 +562,7 @@ dev-lua/luacrypto
 >=games-engines/love-0.8.0-r100:0.8
 >=games-engines/love-11.3-r100:0
 >=games-engines/solarus-1.3.1-r100
+>=games-puzzle/fish-fillets-1.0.1-r100
 >=games-roguelike/stone-soup-0.25.1-r100
 >=mail-filter/imapfilter-2.6.16-r100
 >=media-gfx/geeqie-1.5.1-r1

Reply via email to