1 # Copyright 1999-2018 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
5 inherit gnome2-utils xdg-utils
7 if [[ ${PV} == 9999* ]]; then
9 EHG_REPO_URI="https://bitbucket.org/rude/${PN}"
13 SRC_URI="https://www.bitbucket.org/rude/${PN}/downloads/${P}-linux-src.tar.gz"
14 KEYWORDS="~amd64 ~arm ~x86"
17 DESCRIPTION="A framework for 2D games in Lua"
18 HOMEPAGE="http://love2d.org/"
24 RDEPEND="sys-libs/zlib
26 !luajit? ( dev-lang/lua:0[deprecated] )
27 luajit? ( dev-lang/luajit:2 )
30 media-libs/libsdl2[joystick,opengl]
39 DOCS=( "readme.md" "changes.txt" )
43 if [[ ${PV} == 9999* ]]; then
44 ./platform/unix/automagic || die
49 econf --with-lua=$(usex luajit luajit lua)
55 find "${D}" -name '*.la' -delete || die
58 mv "${ED}/usr/bin/${PN}" "${ED}/usr/bin/${PN}-${SLOT}" || die
59 mv "${ED}"/usr/share/applications/love{,"-$SLOT"}.desktop || die
60 sed -i -e "/^Name=/s/$/ ($SLOT)/" -e "s|/usr/bin/love|/usr/bin/love-$SLOT|" "${ED}/usr/share/applications/love-$SLOT.desktop" || die
61 rm -r "${ED}"/usr/{lib64/liblove.so,share/{mime/,pixmaps/,icons/,man/}} || die
66 gnome2_icon_cache_update
67 xdg_desktop_database_update
68 xdg_mimeinfo_database_update
72 gnome2_icon_cache_update
73 xdg_desktop_database_update
74 xdg_mimeinfo_database_update