public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: games-puzzle/xbomb/files/, games-puzzle/xbomb/
@ 2021-04-04  6:33 Sam James
  0 siblings, 0 replies; only message in thread
From: Sam James @ 2021-04-04  6:33 UTC (permalink / raw
  To: gentoo-commits

commit:     c851c49041fb730f64eeaf699110f0795a8a3b85
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sun Apr  4 00:10:09 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Apr  4 06:32:31 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c851c490

games-puzzle/xbomb: port to EAPI 7, games.eclass--

Signed-off-by: Sam James <sam <AT> gentoo.org>

 games-puzzle/xbomb/files/xbomb-2.2b-DESTDIR.patch  | 61 ++++++++++------------
 games-puzzle/xbomb/files/xbomb-2.2b-ldflags.patch  |  4 +-
 .../{xbomb-2.2b.ebuild => xbomb-2.2b-r1.ebuild}    | 41 ++++++++++-----
 3 files changed, 57 insertions(+), 49 deletions(-)

diff --git a/games-puzzle/xbomb/files/xbomb-2.2b-DESTDIR.patch b/games-puzzle/xbomb/files/xbomb-2.2b-DESTDIR.patch
index 2ee8edd4ec9..6f45b4c82fa 100644
--- a/games-puzzle/xbomb/files/xbomb-2.2b-DESTDIR.patch
+++ b/games-puzzle/xbomb/files/xbomb-2.2b-DESTDIR.patch
@@ -1,34 +1,27 @@
-*** xbomb-2.1/Makefile	1996-01-20 16:02:46.000000000 -0500
---- xbomb-2.1.new/Makefile
-***************
-*** 27,34 ****
-  
-  OBJ=xbomb.o xwindow.o hiscore.o
-  
-- INSTDIR=/usr/local
-- 
-  ########
-  
-  xbomb : $(OBJ)
---- 27,32 ----
-***************
-*** 52,60 ****
-  
-  install :
-  	strip xbomb
-! 	install -d $(INSTDIR)/bin
-! 	install -d $(INSTDIR)/man/man6
-! 	install -d $(INSTDIR)/lib/app-defaults
-! 	install -m 755 xbomb $(INSTDIR)/bin
-! 	install -m 644 xbomb.6 $(INSTDIR)/man/man6
-! 	install -m 644 xbomb.ad $(INSTDIR)/lib/app-defaults/XBomb
---- 50,58 ----
-  
-  install :
-  	strip xbomb
-! 	install -d $(DESTDIR)/usr/bin
-! 	install -d $(DESTDIR)/usr/share/man/man6
-! 	install -d $(DESTDIR)/etc/X11/app-defaults
-! 	install -m 755 xbomb $(DESTDIR)/usr/bin
-! 	install -m 644 xbomb.6 $(DESTDIR)/usr/share/man/man6
-! 	install -m 644 xbomb.ad $(DESTDIR)/etc/X11/app-defaults/XBomb
+--- a/Makefile
++++ b/Makefile
+@@ -27,8 +27,6 @@
+ 
+ OBJ=xbomb.o xwindow.o hiscore.o
+ 
+-INSTDIR=/usr/local
+-
+ ########
+ 
+ xbomb : $(OBJ)
+@@ -52,9 +50,9 @@
+ 
+ install :
+ 	strip xbomb
+-	install -d $(INSTDIR)/bin
+-	install -d $(INSTDIR)/man/man6
+-	install -d $(INSTDIR)/lib/app-defaults
+-	install -m 755 xbomb $(INSTDIR)/bin
+-	install -m 644 xbomb.6 $(INSTDIR)/man/man6
+-	install -m 644 xbomb.ad $(INSTDIR)/lib/app-defaults/XBomb
++	install -d $(DESTDIR)/usr/bin
++	install -d $(DESTDIR)/usr/share/man/man6
++	install -d $(DESTDIR)/etc/X11/app-defaults
++	install -m 755 xbomb $(DESTDIR)/usr/bin
++	install -m 644 xbomb.6 $(DESTDIR)/usr/share/man/man6
++	install -m 644 xbomb.ad $(DESTDIR)/etc/X11/app-defaults/XBomb

diff --git a/games-puzzle/xbomb/files/xbomb-2.2b-ldflags.patch b/games-puzzle/xbomb/files/xbomb-2.2b-ldflags.patch
index a320b0900c5..9f1f524b33c 100644
--- a/games-puzzle/xbomb/files/xbomb-2.2b-ldflags.patch
+++ b/games-puzzle/xbomb/files/xbomb-2.2b-ldflags.patch
@@ -1,5 +1,5 @@
---- Makefile.old
-+++ Makefile
+--- a/Makefile
++++ b/Makefile
 @@ -30,7 +30,7 @@
  ########
  

diff --git a/games-puzzle/xbomb/xbomb-2.2b.ebuild b/games-puzzle/xbomb/xbomb-2.2b-r1.ebuild
similarity index 53%
rename from games-puzzle/xbomb/xbomb-2.2b.ebuild
rename to games-puzzle/xbomb/xbomb-2.2b-r1.ebuild
index 488c4de4bd5..d717dc1dcef 100644
--- a/games-puzzle/xbomb/xbomb-2.2b.ebuild
+++ b/games-puzzle/xbomb/xbomb-2.2b-r1.ebuild
@@ -1,8 +1,9 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=5
-inherit eutils games
+EAPI=7
+
+inherit desktop toolchain-funcs
 
 DESCRIPTION="Minesweeper clone with hexagonal, rectangular and triangular grid"
 HOMEPAGE="http://www.gedanken.org.uk/software/xbomb/"
@@ -11,30 +12,44 @@ SRC_URI="http://www.gedanken.org.uk/software/xbomb/download/${P}.tgz"
 LICENSE="GPL-2+"
 SLOT="0"
 KEYWORDS="~amd64 ~ppc64 ~x86"
-IUSE=""
 
 DEPEND="x11-libs/libXaw"
-RDEPEND=${DEPEND}
+RDEPEND="
+	${DEPEND}
+	acct-group/gamestat
+"
+
+PATCHES=(
+	"${FILESDIR}"/${P}-DESTDIR.patch
+	"${FILESDIR}"/${P}-ldflags.patch
+)
 
 src_prepare() {
-	epatch "${FILESDIR}"/${P}-DESTDIR.patch \
-		"${FILESDIR}"/${P}-ldflags.patch
+	default
+
 	sed -i \
 		-e '/strip/d' \
 		-e '/^CC=/d' \
 		-e "/^CFLAGS/ { s:=.*:=${CFLAGS}: }" \
-		-e "s:/usr/bin:${GAMES_BINDIR}:" \
 		Makefile || die
 	sed -i \
-		-e "s:/var/tmp:${GAMES_STATEDIR}/${PN}:g" \
+		-e "s:/var/tmp:/var/lib/${PN}:g" \
 		hiscore.c || die
 }
 
+src_configure() {
+	tc-export CC
+}
+
 src_install() {
 	default
-	dodir "${GAMES_STATEDIR}"/${PN}
-	touch "${D}/${GAMES_STATEDIR}"/${PN}/${PN}{3,4,6}.hi || die "touch failed"
-	fperms 660 "${GAMES_STATEDIR}"/${PN}/${PN}{3,4,6}.hi
+
+	dodir /var/lib/${PN}
+	touch "${ED}"/var/lib/${PN}/${PN}{3,4,6}.hi || die "touch failed"
+	fperms 660 /var/lib/${PN}/${PN}{3,4,6}.hi
+
+	fowners root:gamestat /var/lib/${PN}
+	fperms g+s /usr/bin/${PN}
+
 	make_desktop_entry xbomb XBomb
-	prepgamesdirs
 }


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-04  6:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-04  6:33 [gentoo-commits] repo/gentoo:master commit in: games-puzzle/xbomb/files/, games-puzzle/xbomb/ Sam James

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox