pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/games/xnibbles Patch this to not need -fwritable-strin...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/983cb455eb48
branches:  trunk
changeset: 547577:983cb455eb48
user:      dholland <dholland%pkgsrc.org@localhost>
date:      Sun Sep 21 08:17:40 2008 +0000

description:
Patch this to not need -fwritable-strings, which is no longer
supported in gcc4. While here, fix a glitch in the man page and add
destdir support. PKGREVISION++.

diffstat:

 games/xnibbles/Makefile         |    6 +-
 games/xnibbles/distinfo         |    8 +-
 games/xnibbles/patches/patch-aa |   30 ++--
 games/xnibbles/patches/patch-ac |   19 +++
 games/xnibbles/patches/patch-ad |  216 ++++++++++++++++++++++++++++++++++++++++
 games/xnibbles/patches/patch-ae |   21 +++
 games/xnibbles/patches/patch-af |   17 +++
 7 files changed, 299 insertions(+), 18 deletions(-)

diffs (truncated from 388 to 300 lines):

diff -r ed156efb0072 -r 983cb455eb48 games/xnibbles/Makefile
--- a/games/xnibbles/Makefile   Sun Sep 21 02:39:28 2008 +0000
+++ b/games/xnibbles/Makefile   Sun Sep 21 08:17:40 2008 +0000
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.20 2008/01/19 09:16:23 wiz Exp $
+# $NetBSD: Makefile,v 1.21 2008/09/21 08:17:40 dholland Exp $
 #
 
 DISTNAME=              xnibbles-1.0BETA4
 PKGNAME=               xnibbles-1.0b4
-PKGREVISION=           2
+PKGREVISION=           3
 CATEGORIES=            games x11
 MASTER_SITES=          http://www.tjhsst.edu/xnibbles/
 
@@ -12,6 +12,8 @@
 # not maintained since 1999, rewritten into gnibbles
 COMMENT=               Winding snakes game for X11
 
+PKG_DESTDIR_SUPPORT=   user-destdir
+
 WRKSRC=                        ${WRKDIR}/xnibbles
 USE_TOOLS+=            gmake
 USE_LANGUAGES=         c c++
diff -r ed156efb0072 -r 983cb455eb48 games/xnibbles/distinfo
--- a/games/xnibbles/distinfo   Sun Sep 21 02:39:28 2008 +0000
+++ b/games/xnibbles/distinfo   Sun Sep 21 08:17:40 2008 +0000
@@ -1,7 +1,11 @@
-$NetBSD: distinfo,v 1.9 2007/07/28 00:52:06 joerg Exp $
+$NetBSD: distinfo,v 1.10 2008/09/21 08:17:40 dholland Exp $
 
 SHA1 (xnibbles-1.0BETA4.tar.gz) = 2f0ed0ea1184cb3e81fa56a430d3c53e96618452
 RMD160 (xnibbles-1.0BETA4.tar.gz) = a07ae907d72a5b4aac093cfe5a3cf7d02a4024e9
 Size (xnibbles-1.0BETA4.tar.gz) = 134982 bytes
-SHA1 (patch-aa) = 42db457084a9a573b8b823f1dfcd1941a634ce9d
+SHA1 (patch-aa) = 2917223959062c339df0ffb9666d4420e511c602
 SHA1 (patch-ab) = 46a8b1970eb3aa088e523aa3d45dd82e3dd4c583
+SHA1 (patch-ac) = ce907c27ea5211a46b7f3a3eaa5f13ca22ee4da5
+SHA1 (patch-ad) = beb17a68983e9312b0874ff6deea351dba27fc32
+SHA1 (patch-ae) = 637b213b92ab2dcd12690606d96dc3c11002b9bf
+SHA1 (patch-af) = 5a51b3effd218e77bc1ed47b3e0311df1c5eb3e6
diff -r ed156efb0072 -r 983cb455eb48 games/xnibbles/patches/patch-aa
--- a/games/xnibbles/patches/patch-aa   Sun Sep 21 02:39:28 2008 +0000
+++ b/games/xnibbles/patches/patch-aa   Sun Sep 21 08:17:40 2008 +0000
@@ -1,7 +1,7 @@
-$NetBSD: patch-aa,v 1.5 2006/08/29 20:03:24 rillig Exp $
+$NetBSD: patch-aa,v 1.6 2008/09/21 08:17:40 dholland Exp $
 
---- Makefile.orig      1998-03-05 14:06:19.000000000 -0800
-+++ Makefile   2004-03-09 15:02:02.000000000 -0800
+--- Makefile.orig      1998-03-05 17:06:19.000000000 -0500
++++ Makefile   2008-09-21 02:02:55.000000000 -0400
 @@ -21,14 +21,15 @@
  ### GENERAL OPTIONS ###
  
@@ -14,7 +14,7 @@
 -  DATADIR = /usr/local/games/xnibbles
 +  DATADIR=$(PREFIX)/share/xnibbles
 +  CPPFLAGS+=-DDATADIR=\"$(DATADIR)\" $(SDEV)
-+  CFLAGS+=-fwritable-strings
++  #CFLAGS+=-fwritable-strings
  
    # Prefix to find bin and man directories for installation
 -  PREFIX  = /usr/local
@@ -43,7 +43,7 @@
  
  xnleditor: xnleditor/level.o xnleditor/newWalls.o xnleditor/sideBar.o xnleditor/walls.o xnleditor/xnleditor.o xnleditor/xpms.o xnleditor/numericDisplay.o
        $(CC) $(CFLAGS) $(LDFLAGS) \
-@@ -115,19 +116,14 @@ tar: pristine
+@@ -115,20 +116,15 @@ tar: pristine
        (cd ..; tar -cvzf xnibbles.tgz xnibbles/ ; chmod 644 xnibbles.tgz)
  
  install:
@@ -60,14 +60,16 @@
 -      $(INSTALL) -g $(GROUP) -m 755 -o $(USER) xnibbles $(PREFIX)/bin
 -      $(INSTALL) -g $(GROUP) -m 755 -o $(USER) xnleditor/xnleditor $(PREFIX)/bin
 -      $(INSTALL) -g $(GROUP) -m 644 -o $(USER) xnibbles.6 $(PREFIX)/man/man6
-+      $(BSD_INSTALL_DATA_DIR) $(DATADIR)/levels
-+      $(BSD_INSTALL_DATA_DIR) $(DATADIR)/sounds
-+      $(BSD_INSTALL_DATA) levels/*.xnl $(DATADIR)/levels
-+      $(BSD_INSTALL_DATA) levels/README $(DATADIR)/levels
-+      $(BSD_INSTALL_DATA) sounds/*.ub $(DATADIR)/sounds
-+      $(BSD_INSTALL_PROGRAM) xnibbles $(PREFIX)/bin
-+      $(BSD_INSTALL_PROGRAM) xnleditor/xnleditor $(PREFIX)/bin
-+      $(BSD_INSTALL_MAN) xnibbles.6 $(PREFIX)/$(PKGMANDIR)/man6
-       ./make-LEVELS $(DATADIR) OOGA
+-      ./make-LEVELS $(DATADIR) OOGA
++      $(BSD_INSTALL_DATA_DIR) $(DESTDIR)$(DATADIR)/levels
++      $(BSD_INSTALL_DATA_DIR) $(DESTDIR)$(DATADIR)/sounds
++      $(BSD_INSTALL_DATA) levels/*.xnl $(DESTDIR)$(DATADIR)/levels
++      $(BSD_INSTALL_DATA) levels/README $(DESTDIR)$(DATADIR)/levels
++      $(BSD_INSTALL_DATA) sounds/*.ub $(DESTDIR)$(DATADIR)/sounds
++      $(BSD_INSTALL_PROGRAM) xnibbles $(DESTDIR)$(PREFIX)/bin
++      $(BSD_INSTALL_PROGRAM) xnleditor/xnleditor $(DESTDIR)$(PREFIX)/bin
++      $(BSD_INSTALL_MAN) xnibbles.6 $(DESTDIR)$(PREFIX)/$(PKGMANDIR)/man6
++      ./make-LEVELS $(DESTDIR)$(DATADIR) $(DATADIR) OOGA
  
  bodyPart.o:   common.h bodyPart.h
+ boni.o:       common.h boni.h
diff -r ed156efb0072 -r 983cb455eb48 games/xnibbles/patches/patch-ac
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/xnibbles/patches/patch-ac   Sun Sep 21 08:17:40 2008 +0000
@@ -0,0 +1,19 @@
+$NetBSD: patch-ac,v 1.1 2008/09/21 08:17:40 dholland Exp $
+
+--- make-LEVELS~       1998-02-23 13:37:57.000000000 -0500
++++ make-LEVELS        2008-09-21 02:04:01.000000000 -0400
+@@ -1,6 +1,6 @@
+ #!/bin/sh
+ 
+-if [ $2"X" != "OOGAX" ]; then
++if [ $3"X" != "OOGAX" ]; then
+   echo "You shouldn't run this script yourself!  Let the Makefile do it!"
+   exit 1
+ fi
+@@ -9,5 +9,5 @@ cd levels
+ rm -f $1"/levels/LEVELS"
+ touch $1"/levels/LEVELS"
+ for i in level???.xnl ; do
+-  echo $1"/levels/"$i >> $1"/levels/LEVELS"
++  echo $2"/levels/"$i >> $1"/levels/LEVELS"
+ done
diff -r ed156efb0072 -r 983cb455eb48 games/xnibbles/patches/patch-ad
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/games/xnibbles/patches/patch-ad   Sun Sep 21 08:17:40 2008 +0000
@@ -0,0 +1,216 @@
+$NetBSD: patch-ad,v 1.1 2008/09/21 08:17:40 dholland Exp $
+
+--- statusBar.c.orig   1998-03-02 13:22:25.000000000 -0500
++++ statusBar.c        2008-09-21 02:17:18.000000000 -0400
+@@ -52,159 +52,159 @@ statusBar::statusBar(char theName[], int
+     theName[foo]=tolower(theName[foo]);
+     switch (theName[foo]) {
+       case 'a':
+-        strcpy (a_xpm[2],colors[6*which+2]);
++        a_xpm[2] = strdup(colors[6*which+2]);
+         a_xpm[2][0]='a';
+-        strcpy (a_xpm[3],colors[6*which+5]);
++        a_xpm[3] = colors[6*which+5];
+         makePixmap(a_xpm, &letters[foo]);
+         break;
+       case 'b':
+-        strcpy (b_xpm[2],colors[6*which+2]);
++        b_xpm[2] = strdup(colors[6*which+2]);
+         b_xpm[2][0]='a';
+-        strcpy (b_xpm[3],colors[6*which+5]);
++        b_xpm[3] = colors[6*which+5];
+         makePixmap(b_xpm, &letters[foo]);
+         break;
+       case 'c':
+-        strcpy (c_xpm[2],colors[6*which+2]);
++        c_xpm[2] = strdup(colors[6*which+2]);
+         c_xpm[2][0]='a';
+-        strcpy (c_xpm[3],colors[6*which+5]);
++        c_xpm[3] = colors[6*which+5];
+         makePixmap(c_xpm, &letters[foo]);
+         break;
+       case 'd':
+-        strcpy (d_xpm[2],colors[6*which+2]);
++        d_xpm[2] = strdup(colors[6*which+2]);
+         d_xpm[2][0]='a';
+-        strcpy (d_xpm[3],colors[6*which+5]);
++        d_xpm[3] = colors[6*which+5];
+         makePixmap(d_xpm, &letters[foo]);
+         break;
+       case 'e':
+-        strcpy (e_xpm[2],colors[6*which+2]);
++        e_xpm[2] = strdup(colors[6*which+2]);
+         e_xpm[2][0]='a';
+-        strcpy (e_xpm[3],colors[6*which+5]);
++        e_xpm[3] = colors[6*which+5];
+         makePixmap(e_xpm, &letters[foo]);
+         break;
+       case 'f':
+-        strcpy (f_xpm[2],colors[6*which+2]);
++        f_xpm[2] = strdup(colors[6*which+2]);
+         f_xpm[2][0]='a';
+-        strcpy (f_xpm[3],colors[6*which+5]);
++        f_xpm[3] = colors[6*which+5];
+         makePixmap(f_xpm, &letters[foo]);
+         break;
+       case 'g':
+-        strcpy (g_xpm[2],colors[6*which+2]);
++        g_xpm[2] = strdup(colors[6*which+2]);
+         g_xpm[2][0]='a';
+-        strcpy (g_xpm[3],colors[6*which+5]);
++        g_xpm[3] = colors[6*which+5];
+         makePixmap(g_xpm, &letters[foo]);
+         break;
+       case 'h':
+-        strcpy (h_xpm[2],colors[6*which+2]);
++        h_xpm[2] = strdup(colors[6*which+2]);
+         h_xpm[2][0]='a';
+-        strcpy (h_xpm[3],colors[6*which+5]);
++        h_xpm[3] = colors[6*which+5];
+         makePixmap(h_xpm, &letters[foo]);
+         break;
+       case 'i':
+-        strcpy (i_xpm[2],colors[6*which+2]);
++        i_xpm[2] = strdup(colors[6*which+2]);
+         i_xpm[2][0]='a';
+-        strcpy (i_xpm[3],colors[6*which+5]);
++        i_xpm[3] = colors[6*which+5];
+         makePixmap(i_xpm, &letters[foo]);
+         break;
+       case 'j':
+-        strcpy (j_xpm[2],colors[6*which+2]);
++        j_xpm[2] = strdup(colors[6*which+2]);
+         j_xpm[2][0]='a';
+-        strcpy (j_xpm[3],colors[6*which+5]);
++        j_xpm[3] = colors[6*which+5];
+         makePixmap(j_xpm, &letters[foo]);
+         break;
+       case 'k':
+-        strcpy (k_xpm[2],colors[6*which+2]);
++        k_xpm[2] = strdup(colors[6*which+2]);
+         k_xpm[2][0]='a';
+-        strcpy (k_xpm[3],colors[6*which+5]);
++        k_xpm[3] = colors[6*which+5];
+         makePixmap(k_xpm, &letters[foo]);
+         break;
+       case 'l':
+-        strcpy (l_xpm[2],colors[6*which+2]);
++        l_xpm[2] = strdup(colors[6*which+2]);
+         l_xpm[2][0]='a';
+-        strcpy (l_xpm[3],colors[6*which+5]);
++        l_xpm[3] = colors[6*which+5];
+         makePixmap(l_xpm, &letters[foo]);
+         break;
+       case 'm':
+-        strcpy (m_xpm[2],colors[6*which+2]);
++        m_xpm[2] = strdup(colors[6*which+2]);
+         m_xpm[2][0]='a';
+-        strcpy (m_xpm[3],colors[6*which+5]);
++        m_xpm[3] = colors[6*which+5];
+         makePixmap(m_xpm, &letters[foo]);
+         break;
+       case 'n':
+-        strcpy (n_xpm[2],colors[6*which+2]);
++        n_xpm[2] = strdup(colors[6*which+2]);
+         n_xpm[2][0]='a';
+-        strcpy (n_xpm[3],colors[6*which+5]);
++        n_xpm[3] = colors[6*which+5];
+         makePixmap(n_xpm, &letters[foo]);
+         break;
+       case 'o':
+-        strcpy (o_xpm[2],colors[6*which+2]);
++        o_xpm[2] = strdup(colors[6*which+2]);
+         o_xpm[2][0]='a';
+-        strcpy (o_xpm[3],colors[6*which+5]);
++        o_xpm[3] = colors[6*which+5];
+         makePixmap(o_xpm, &letters[foo]);
+         break;
+       case 'p':
+-        strcpy (p_xpm[2],colors[6*which+2]);
++        p_xpm[2] = strdup(colors[6*which+2]);
+         p_xpm[2][0]='a';
+-        strcpy (p_xpm[3],colors[6*which+5]);
++        p_xpm[3] = colors[6*which+5];
+         makePixmap(p_xpm, &letters[foo]);
+         break;
+       case 'q':
+-        strcpy (q_xpm[2],colors[6*which+2]);
++        q_xpm[2] = strdup(colors[6*which+2]);
+         q_xpm[2][0]='a';
+-        strcpy (q_xpm[3],colors[6*which+5]);
++        q_xpm[3] = colors[6*which+5];
+         makePixmap(q_xpm, &letters[foo]);
+         break;
+       case 'r':
+-        strcpy (r_xpm[2],colors[6*which+2]);
++        r_xpm[2] = strdup(colors[6*which+2]);
+         r_xpm[2][0]='a';
+-        strcpy (r_xpm[3],colors[6*which+5]);
++        r_xpm[3] = colors[6*which+5];
+         makePixmap(r_xpm, &letters[foo]);
+         break;
+       case 's':
+-        strcpy (s_xpm[2],colors[6*which+2]);
++        s_xpm[2] = strdup(colors[6*which+2]);
+         s_xpm[2][0]='a';
+-        strcpy (s_xpm[3],colors[6*which+5]);
++        s_xpm[3] = colors[6*which+5];
+         makePixmap(s_xpm, &letters[foo]);
+         break;
+       case 't':
+-        strcpy (t_xpm[2],colors[6*which+2]);
++        t_xpm[2] = strdup(colors[6*which+2]);
+         t_xpm[2][0]='a';
+-        strcpy (t_xpm[3],colors[6*which+5]);
++        t_xpm[3] = colors[6*which+5];
+         makePixmap(t_xpm, &letters[foo]);
+         break;
+       case 'u':
+-        strcpy (u_xpm[2],colors[6*which+2]);
++        u_xpm[2] = strdup(colors[6*which+2]);
+         u_xpm[2][0]='a';
+-        strcpy (u_xpm[3],colors[6*which+5]);
++        u_xpm[3] = colors[6*which+5];
+         makePixmap(u_xpm, &letters[foo]);



Home | Main Index | Thread Index | Old Index