- score file path fix
authorJakub Bogusz <qboosh@pld-linux.org>
Mon, 12 May 2003 14:51:48 +0000 (14:51 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    geki5-KXL-scorepath.patch -> 1.1

geki5-KXL-scorepath.patch [new file with mode: 0644]

diff --git a/geki5-KXL-scorepath.patch b/geki5-KXL-scorepath.patch
new file mode 100644 (file)
index 0000000..8463e7e
--- /dev/null
@@ -0,0 +1,55 @@
+diff -Nur geki5-KXL-0.3.0.orig/configure.in geki5-KXL-0.3.0/configure.in
+--- geki5-KXL-0.3.0.orig/configure.in  Mon Sep  3 16:28:48 2001
++++ geki5-KXL-0.3.0/configure.in       Mon May 12 14:44:52 2003
+@@ -29,11 +29,18 @@
+         BMP_PATH=$prefix/share/geki5/bmp
+         WAV_PATH=$prefix/share/geki5/wav
+ fi
++if test "x$localstatedir" = "xNONE"; then
++      SCORE_PATH=/var/games
++else
++      SCORE_PATH=$localstatedir/games
++fi
+ AC_DEFINE_UNQUOTED(DATA_PATH,"$DATA_PATH")
++AC_DEFINE_UNQUOTED(SCORE_PATH,"$SCORE_PATH")
+ AC_DEFINE_UNQUOTED(BMP_PATH,"$BMP_PATH")
+ AC_DEFINE_UNQUOTED(WAV_PATH,"$WAV_PATH")
+ AC_DEFINE_UNQUOTED(TITLE,"$PACKAGE $VERSION")
+ AC_SUBST(DATA_PATH)
++AC_SUBST(SCORE_PATH)
+ AC_SUBST(BMP_PATH)
+ AC_SUBST(WAV_PATH)
+diff -Nur geki5-KXL-0.3.0.orig/data/Makefile.am geki5-KXL-0.3.0/data/Makefile.am
+--- geki5-KXL-0.3.0.orig/data/Makefile.am      Mon Sep  3 17:06:34 2001
++++ geki5-KXL-0.3.0/data/Makefile.am   Mon May 12 14:45:29 2003
+@@ -4,5 +4,6 @@
+ EXTRA_DIST = stage1.dat stage2.dat stage3.dat stage4.dat stage5.dat\
+            stage6.dat stage7.dat stage8.dat .score
+-install:
+-      $(INSTALL) -c -m 666 ./.score $(DESTDIR)$(DATA_PATH)
++install-data-local:
++      $(INSTALL) -d -m 755 $(DESTDIR)$(SCORE_PATH)
++      $(INSTALL) -c -m 666 ./.score $(DESTDIR)$(SCORE_PATH)/geki5.score
+diff -Nur geki5-KXL-0.3.0.orig/src/ranking.c geki5-KXL-0.3.0/src/ranking.c
+--- geki5-KXL-0.3.0.orig/src/ranking.c Mon Sep  3 15:20:55 2001
++++ geki5-KXL-0.3.0/src/ranking.c      Mon May 12 14:45:50 2003
+@@ -36,7 +36,7 @@
+   FILE *fp;\r
+   Uint16 i;\r
\r
+-  if ((fp = fopen(DATA_PATH "/.score", "r"))) {\r
++  if ((fp = fopen(SCORE_PATH "/geki5.score", "r"))) {\r
+     fscanf(fp, "%d", &(Root->HiScore));\r
+     for (i = 0; i < 5; i ++)\r
+       fscanf(fp, "%d %d %s",\r
+@@ -65,7 +65,7 @@
+   FILE *fp;\r
+   Uint16 i;\r
\r
+-  if ((fp = fopen(DATA_PATH "/.score", "w"))) {\r
++  if ((fp = fopen(SCORE_PATH "/geki5.score", "w"))) {\r
+     fprintf(fp, "%d\n", Root->HiScore);\r
+     for (i = 0; i < 5; i ++)\r
+       fprintf(fp, "%d %d %s\n",\r
This page took 0.06686 seconds and 4 git commands to generate.