tags 461626 patch
thanks

The attached patch should solve this.  It will create the score file in
postinst instead.  The old score file should be preserved durig upgrade.

It also updates the Debian Standards version to 3.7.3.

Regards,
Ansgar

-- 
PGP: 1024D/595FAD19  739E 2D09 0969 BEA9 9797  B055 DDB0 2FF7 595F AD19

Index: debian/control
===================================================================
--- debian/control	(revision 5507)
+++ debian/control	(working copy)
@@ -4,10 +4,10 @@
 Maintainer: Debian Games Team <[email protected]>
 Uploaders: Nacho Barrientos Arias <[EMAIL PROTECTED]>
 Build-Depends: debhelper (>= 5), libncurses5-dev | libncurses-dev, quilt (>= 0.40)
-Standards-Version: 3.7.2
+Standards-Version: 3.7.3
 Homepage: http://fph.altervista.org/prog/bastet.shtml
-XS-Vcs-Svn: svn://svn.debian.org/svn/pkg-games/packages/trunk/bastet/
-XS-Vcs-Browser: http://svn.debian.org/wsvn/pkg-games/packages/trunk/bastet/?op=log
+Vcs-Svn: svn://svn.debian.org/svn/pkg-games/packages/trunk/bastet/
+Vcs-Browser: http://svn.debian.org/wsvn/pkg-games/packages/trunk/bastet/?op=log
 
 Package: bastet
 Architecture: any
@@ -19,5 +19,3 @@
  gives you the worst, the most bastard it can find. Playing bastet can be 
  a painful experience, especially if you usually make "canyons" and wait for 
  the long I-shaped block.
- .
-  Homepage: http://fph.altervista.org/prog/bastet.shtml
Index: debian/postinst
===================================================================
--- debian/postinst	(revision 0)
+++ debian/postinst	(revision 0)
@@ -0,0 +1,23 @@
+#! /bin/sh
+# postrm script for bastet
+
+set -e
+
+scores=/var/games/bastet.scores
+
+# old version of bastet (<= 0.41-5) will remove high score file
+# on upgrade, so rescue it
+if [ -e "$scores.tmp" ] ; then
+  mv "$scores.tmp" "$scores"
+fi
+if [ ! -e "$scores" ] ; then
+
+  touch "$scores"
+  chgrp games "$scores"
+  chmod 664 "$scores"
+fi
+
+#DEBHELPER#
+
+exit 0
+
Index: debian/preinst
===================================================================
--- debian/preinst	(revision 0)
+++ debian/preinst	(revision 0)
@@ -0,0 +1,21 @@
+#! /bin/sh
+# preinst script for bastet
+
+set -e
+
+scores=/var/games/bastet.scores
+
+case "$1" in
+  install|upgrade)
+    # old version of bastet (<= 0.41-5) will remove high score file
+    # on upgrade, so rescue it
+    if [ -e "$scores" ] ; then
+      cp "$scores" "$scores.tmp"
+    fi
+  ;;
+esac
+
+#DEBHELPER#
+
+exit 0
+
Index: debian/postrm
===================================================================
--- debian/postrm	(revision 0)
+++ debian/postrm	(revision 0)
@@ -0,0 +1,13 @@
+#! /bin/sh
+# postrm script for bastet
+
+set -e
+
+if [ "$1" = purge ] ; then
+  rm -f /var/games/bastet.scores
+fi
+
+#DEBHELPER#
+
+exit 0
+
Index: debian/changelog
===================================================================
--- debian/changelog	(revision 5507)
+++ debian/changelog	(working copy)
@@ -11,8 +11,13 @@
   * Add watch file
   * Add Homepage field in control section
 
- -- Nacho Barrientos Arias <[EMAIL PROTECTED]>  Mon, 11 Jul 2007 11:25:12 +0300
+  [ Ansgar Burchardt ]
+  * Don't distribute score file, create in postinst instead (Closes: #461626).
+  * Update Debian Stanards version to 3.7.3
+  * Rename XS-Vcs-Svn and XS-Vcs-Browser fields to Vcs-Svn and Vcs-Browser
 
+ -- Ansgar Burchardt <[EMAIL PROTECTED]>  Sun, 27 Jan 2008 17:24:40 +0100
+
 bastet (0.41-5) unstable; urgency=low
 
   * debian/control
Index: debian/patches/01_Makefile.patch
===================================================================
--- debian/patches/01_Makefile.patch	(revision 5507)
+++ debian/patches/01_Makefile.patch	(working copy)
@@ -7,8 +7,8 @@
 
 Index: bastet-0.41/Makefile
 ===================================================================
---- bastet-0.41.orig/Makefile	2007-07-09 21:11:47.000000000 +0200
-+++ bastet-0.41/Makefile	2007-07-09 21:39:23.000000000 +0200
+--- bastet-0.41.orig/Makefile	2004-10-19 19:54:58.000000000 +0200
++++ bastet-0.41/Makefile	2008-01-27 15:55:35.000000000 +0100
 @@ -1,8 +1,8 @@
  #makefile for bastet (c) 2004 Federico Poloni
  
@@ -29,12 +29,12 @@
  LDFLAGS=-lncurses
  SOURCES=main.c game.c highscore.c bast.c
  EXNAME=bastet
-@@ -39,8 +39,4 @@
+@@ -39,8 +39,3 @@
  
  install: $(EXNAME)
  	cp $(EXNAME) $(BIN_PREFIX)
 -	chown $(GAME_USER) $(BIN_PREFIX)$(EXNAME)
 -	chmod u+s $(BIN_PREFIX)$(EXNAME)
- 	touch $(DATA_PREFIX)$(HISCORE)
+-	touch $(DATA_PREFIX)$(HISCORE)
 -	chown $(GAME_USER) $(DATA_PREFIX)$(HISCORE)
 -	chmod 644 $(DATA_PREFIX)$(HISCORE)
Index: debian/rules
===================================================================
--- debian/rules	(revision 5507)
+++ debian/rules	(working copy)
@@ -47,15 +47,14 @@
 	dh_installchangelogs 
 	dh_installdocs
 	dh_installdirs
-	chown root.games debian/bastet/var/games/bastet.scores debian/bastet/usr/games/bastet
-	chmod g+w debian/bastet/var/games/bastet.scores
+	chown root.games debian/bastet/usr/games/bastet
 	chmod 2755 debian/bastet/usr/games/bastet
 	dh_install
 	dh_installman debian/manpages/bastet.6
 	dh_installmenu
 	dh_strip
 	dh_compress
-	dh_fixperms -Xvar/games/bastet.scores -Xusr/games/bastet
+	dh_fixperms -Xusr/games/bastet
 	dh_installdeb
 	dh_shlibdeps
 	dh_gencontrol
_______________________________________________
Pkg-games-devel mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/pkg-games-devel

Reply via email to