games-puzzle/monsterz: Stop using games.eclass
authorPacho Ramos <pacho@gentoo.org>
Tue, 1 May 2018 12:56:37 +0000 (14:56 +0200)
committerPacho Ramos <pacho@gentoo.org>
Tue, 1 May 2018 19:33:37 +0000 (21:33 +0200)
Package-Manager: Portage-2.3.31, Repoman-2.3.9

games-puzzle/monsterz/files/monsterz-0.7.1-blit.patch
games-puzzle/monsterz/files/monsterz-0.7.1-gentoo.patch
games-puzzle/monsterz/monsterz-0.7.1-r4.ebuild [new file with mode: 0644]

index 8e55b23a327c0e98fcec73f090919292054e50a6..d0847d6c2c101834f6ab73d9330f8f58c21476df 100644 (file)
@@ -1,5 +1,5 @@
---- monsterz.py
-+++ monsterz.py
+--- a/monsterz.py
++++ b/monsterz.py
 @@ -829,10 +829,10 @@
              pass
          else:
index 652450bf190bf77c407dfb9592c359e40876ee1e..6920e0e36971e50c02b34ec68d815b5d093522f5 100644 (file)
@@ -1,5 +1,5 @@
---- monsterz.py.orig   2006-05-12 18:55:51.000000000 -0400
-+++ monsterz.py        2006-05-12 18:57:44.000000000 -0400
+--- a/monsterz.py.orig 2006-05-12 18:55:51.000000000 -0400
++++ b/monsterz.py      2006-05-12 18:57:44.000000000 -0400
 @@ -1907,7 +1906,7 @@
      print '          (C) Mike Kershaw <dragorn@kismetwireless.net>'
  
diff --git a/games-puzzle/monsterz/monsterz-0.7.1-r4.ebuild b/games-puzzle/monsterz/monsterz-0.7.1-r4.ebuild
new file mode 100644 (file)
index 0000000..4cff31b
--- /dev/null
@@ -0,0 +1,47 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 )
+
+inherit desktop python-r1
+
+DESCRIPTION="A little puzzle game, similar to the famous Bejeweled or Zookeeper"
+HOMEPAGE="http://sam.zoy.org/projects/monsterz/"
+SRC_URI="http://sam.zoy.org/projects/monsterz/${P}.tar.gz"
+
+LICENSE="GPL-1+ LGPL-2+ WTFPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~x86"
+
+IUSE=""
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RDEPEND="${PYTHON_DEPS}
+       dev-python/pygame[${PYTHON_USEDEP}]
+       media-libs/sdl-image[png]
+       media-libs/sdl-mixer[mod]
+"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+       default
+       eapply \
+               "${FILESDIR}"/${P}-gentoo.patch \
+               "${FILESDIR}"/${P}-64bit.patch \
+               "${FILESDIR}"/${P}-blit.patch
+       sed -i \
+               -e "s:GENTOO_DATADIR:/usr/share/${PN}:" \
+               monsterz.py || die "sed failed"
+       rm Makefile || die
+}
+
+src_install() {
+       insinto /usr/share/${PN}
+       doins -r graphics sound
+       newbin monsterz.py ${PN}
+       newicon graphics/icon.png ${PN}.png
+       make_desktop_entry ${PN} Monsterz
+       einstalldocs
+       python_replicate_script "${ED%/}"/usr/bin/monsterz
+}