summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'games-arcade/tomatoes')
-rw-r--r--games-arcade/tomatoes/files/tomatoes-1.55-c_str.patch4
-rw-r--r--games-arcade/tomatoes/files/tomatoes-1.55-gcc43.patch4
-rw-r--r--games-arcade/tomatoes/files/tomatoes-1.55-underlink.patch4
-rw-r--r--games-arcade/tomatoes/tomatoes-1.55-r2.ebuild62
-rw-r--r--games-arcade/tomatoes/tomatoes-1.55-r3.ebuild75
5 files changed, 81 insertions, 68 deletions
diff --git a/games-arcade/tomatoes/files/tomatoes-1.55-c_str.patch b/games-arcade/tomatoes/files/tomatoes-1.55-c_str.patch
index dd6927e54153..f001179a837f 100644
--- a/games-arcade/tomatoes/files/tomatoes-1.55-c_str.patch
+++ b/games-arcade/tomatoes/files/tomatoes-1.55-c_str.patch
@@ -1,5 +1,5 @@
---- src/config.cpp.orig 2004-09-27 11:35:48.000000000 +0200
-+++ src/config.cpp 2006-02-13 00:00:01.000000000 +0100
+--- a/src/config.cpp
++++ b/src/config.cpp
@@ -78,6 +78,7 @@
// makefile.
char *get_config_location(bool write) {
diff --git a/games-arcade/tomatoes/files/tomatoes-1.55-gcc43.patch b/games-arcade/tomatoes/files/tomatoes-1.55-gcc43.patch
index cd85e31e5936..95bf7ba6eddb 100644
--- a/games-arcade/tomatoes/files/tomatoes-1.55-gcc43.patch
+++ b/games-arcade/tomatoes/files/tomatoes-1.55-gcc43.patch
@@ -1,5 +1,5 @@
---- src/config.cpp
-+++ src/config.cpp
+--- a/src/config.cpp
++++ b/src/config.cpp
@@ -27,8 +27,9 @@
*************************************************************************/
diff --git a/games-arcade/tomatoes/files/tomatoes-1.55-underlink.patch b/games-arcade/tomatoes/files/tomatoes-1.55-underlink.patch
index c028c79ba4a7..bc7763bf492e 100644
--- a/games-arcade/tomatoes/files/tomatoes-1.55-underlink.patch
+++ b/games-arcade/tomatoes/files/tomatoes-1.55-underlink.patch
@@ -1,5 +1,5 @@
---- makefile.old 2011-06-18 17:35:38.947020335 +0200
-+++ makefile 2011-06-18 17:37:42.337811088 +0200
+--- a/makefile
++++ b/makefile
@@ -48,7 +47,7 @@
LDFLAGS = `sdl-config --libs` -lSDL_image -lSDL_mixer -lGL -lGLU -pg
else
diff --git a/games-arcade/tomatoes/tomatoes-1.55-r2.ebuild b/games-arcade/tomatoes/tomatoes-1.55-r2.ebuild
deleted file mode 100644
index dd5658f861bf..000000000000
--- a/games-arcade/tomatoes/tomatoes-1.55-r2.ebuild
+++ /dev/null
@@ -1,62 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-inherit eutils games
-
-DATA_PV=1.5
-DESCRIPTION="How many tomatoes can you smash in ten short minutes?"
-HOMEPAGE="http://tomatoes.sourceforge.net/about.html"
-SRC_URI="mirror://sourceforge/tomatoes/tomatoes-linux-src-${PV}.tar.bz2
- mirror://sourceforge/tomatoes/tomatoes-linux-${DATA_PV}.tar.bz2"
-
-LICENSE="ZLIB"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc64 ~x86"
-IUSE=""
-
-DEPEND="virtual/opengl
- virtual/glu
- media-libs/libsdl[sound,video]
- media-libs/sdl-image[jpeg,png]
- media-libs/sdl-mixer[mod]"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- mv ../tomatoes-1.5/* . || die "mv failed"
- mv icon.png ${PN}.png
-
- epatch \
- "${FILESDIR}"/${P}-c_str.patch \
- "${FILESDIR}"/${P}-underlink.patch \
- "${FILESDIR}"/${P}-gcc43.patch
-
- sed -i \
- -e "/^MPKDIR = /s:./:${GAMES_DATADIR}/${PN}/:" \
- -e "/^MUSICDIR = /s:./music/:${GAMES_DATADIR}/${PN}/music/:" \
- -e "/^HISCOREDIR = /s:./:${GAMES_STATEDIR}/${PN}/:" \
- -e "/^CONFIGDIR = /s:./:${GAMES_SYSCONFDIR}/${PN}/:" \
- -e "/^OVERRIDEDIR = /s:./data/:${GAMES_DATADIR}/${PN}/data/:" \
- makefile \
- || die "sed failed"
-}
-
-src_install() {
- dogamesbin tomatoes
- dodoc README README-src
-
- insinto "${GAMES_DATADIR}"/${PN}
- doins -r tomatoes.mpk music
-
- doicon ${PN}.png
- make_desktop_entry tomatoes "I Have No Tomatoes"
-
- dodir "${GAMES_STATEDIR}"/${PN}
- touch "${D}${GAMES_STATEDIR}"/${PN}/hiscore.lst || die "touch failed"
- fperms 660 "${GAMES_STATEDIR}"/${PN}/hiscore.lst
-
- insinto "${GAMES_SYSCONFDIR}"/${PN}
- doins config.cfg
-
- prepgamesdirs
-}
diff --git a/games-arcade/tomatoes/tomatoes-1.55-r3.ebuild b/games-arcade/tomatoes/tomatoes-1.55-r3.ebuild
new file mode 100644
index 000000000000..088f0a4563b1
--- /dev/null
+++ b/games-arcade/tomatoes/tomatoes-1.55-r3.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit desktop toolchain-funcs
+
+DATA_PV=1.5
+DESCRIPTION="How many tomatoes can you smash in ten short minutes?"
+HOMEPAGE="http://tomatoes.sourceforge.net/about.html"
+SRC_URI="mirror://sourceforge/tomatoes/tomatoes-linux-src-${PV}.tar.bz2
+ mirror://sourceforge/tomatoes/tomatoes-linux-${DATA_PV}.tar.bz2"
+
+LICENSE="ZLIB"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64 ~x86"
+
+DEPEND="
+ media-libs/libsdl[sound,video]
+ media-libs/sdl-image[jpeg,png]
+ media-libs/sdl-mixer[mod]
+ virtual/opengl
+ virtual/glu
+"
+RDEPEND="
+ ${DEPEND}
+ acct-group/gamestat
+"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-c_str.patch
+ "${FILESDIR}"/${P}-underlink.patch
+ "${FILESDIR}"/${P}-gcc43.patch
+)
+
+src_prepare() {
+ default
+
+ mv ../tomatoes-1.5/* . || die "mv failed"
+ mv icon.png ${PN}.png || die
+
+ sed -i \
+ -e "/^MPKDIR = /s:./:/usr/share/${PN}/:" \
+ -e "/^MUSICDIR = /s:./music/:/usr/share/${PN}/music/:" \
+ -e "/^HISCOREDIR = /s:./:/var/games/${PN}/:" \
+ -e "/^CONFIGDIR = /s:./:/etc/${PN}/:" \
+ -e "/^OVERRIDEDIR = /s:./data/:/usr/share/${PN}/data/:" \
+ makefile \
+ || die "sed failed"
+}
+
+src_configure() {
+ tc-export CXX
+}
+
+src_install() {
+ dobin tomatoes
+ dodoc README README-src
+
+ insinto /usr/share/${PN}
+ doins -r tomatoes.mpk music
+
+ doicon ${PN}.png
+ make_desktop_entry tomatoes "I Have No Tomatoes"
+
+ dodir /var/games/${PN}
+ touch "${ED}"/var/games/${PN}/hiscore.lst || die "touch failed"
+
+ fperms 660 /var/games/${PN}/hiscore.lst
+ fowners -R root:gamestat /var/games/${PN}
+ fperms g+s /usr/bin/${PN}
+
+ insinto /etc/${PN}
+ doins config.cfg
+}