summaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorleot <leot>2015-10-06 22:10:02 +0000
committerleot <leot>2015-10-06 22:10:02 +0000
commit00ad30ec181e997f124aaffd1d9121836c77f4e3 (patch)
tree1eac39d372bb9392adf380d1372b493acc82cc6e /games
parentb2927c24a79ebf5d03f6ed4a7147c5eb3478fb25 (diff)
downloadpkgsrc-00ad30ec181e997f124aaffd1d9121836c77f4e3.tar.gz
Update games/xsoldier to xsoldier-1.8.
From Benedek Gergely via pkgsrc-users@ with some minor changes from myself. Changes: 2011-08-13 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.8 * score.c: compare_entry() is now static * configure.ac: added x before with/enable variables in case their values begin with a special character * player.c: removed the "not shooting" bonus debug message because it is too noisy * boss.c: removed debug messages in BossHit1 because they are too noisy 2011-08-10 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.7 * joystick.c, joystick.h: define empty functions instead of commenting them out when the joystick support is disabled to avoid an empty .c file * enemyshot.c: included stdio.h and stdlib.h (for abs()) * Makefile.am: removed -Wcast-qual because the file name for XpmReadFileToPixmap is char *, not const char * 2011-08-09 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.6 * configure.ac: fixed so that --enable options can be disabled correctly * configure.ac: rewrite --with option * configure.ac: added AC_PROG_CPP because AC_CHECK_HEADERS requires it * configure.ac: checks the function atexit because graphic.c uses it * configure.ac: fixed comments * joystick.c, joystick.h: comment out the whole file if JSTK is not defined * Makefile.am: fixed comment so that Makefile doesn't say "process this file with automake" * Makefile.am, configure.ac: use the tar-ustar option of automake instead of AMTAR = ustar in Makefile.am * configure.ac: added the foreign option to AM_INIT_AUTOMAKE * README: says that the joystick support is only on Linux 2009-11-08 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.5 * game.c, xsoldier.h: make sure that an object never acts at the same frame as it is created * game.c: removed unnecessary variable ocheck * version.h: updated UPDATE 2006-09-16 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.4 * Makefile.am: minor cleanup - uses some AM_variables - gcc -g and the overkill warnings are now default - set AMTAR to ustar * Makefile.in: regenerated with automake 1.9 * configure: ./configure accepts --without-sld as well as --with-sdl * INSTALL: fixed high score file instruction * input.c, main.c, manage.c, xsolder.h: the SDL version respects the TERM signal and closing the window 2002-05-26 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.3 * configure.ac: does not stop configuring even if --with-sdl is specified but AC_CHECK_LIB([SDL], [SDL_Init]) fails (this won't do any harm because if there is no SDL then "make" will fail correctly) (I don't know why AC_CHECK_LIB fails on a non-i386 architecture (perhaps because of missing -lpthread?)) * configure.ac: regenerated * image.c, manage.c: s/HAVE_LIBSDL_IMAGE/HAVE_LIBSDL/g * common.c, ending.c, enemyshot.c, game.c, joystick.c, opening.c: added some #include to avoid gcc -Wall warnings * enemyshot.c, graphic.c, manage.c, player.c: use division instead of shift * score.c: fake records no longer have loop 0 * score.c: fake records are more close to the default * image.c: fixed image loading so that xsoldier displays the correct color on a 16-bit-per-pixel display (thanks to Stephen McCamant <smcc@CSUA.Berkeley.EDU> for the patch) * README: fixed typo * image.c: SDL version sets the palette of pixmaps explicitly if the screen is 8 bpp (without this the window is blank) * README, extern.h, graphic.c, image.c, main.c, xsoldier.6: now -c option does nothing because it does not work with raw X on 8 bpp screen * image.h: SDL version uses typedef instead of #define for Image * graphic.c, image.c, star.c: fixed memory leak (I still don't know how to free memory allocated by getpwuid() in manage.c) * README: fixed description (xsoldier is not first-person, "for one player" is the right term) * boss.c: you can't go to the next stage if the game is over 2002-04-24 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.2 * xsoldier is ported to SDL (the Simple DirectMedia Layer library) * extern.h: fixed a typo in comment * callback.c, game.c, graphic.c, image.c, input.c, joystick.c, main.c, manage.c, config.h, extern.h, graphic.h, image.h, key.h: Added libsdl support (use --with-sdl). Note that libsdl support uses a double-standard for coordinates to keep the 10 pixel boundary * enemyshot.c: enemy shots do move * INSTALL, README: added note on SDL * README: added a game tip 2002-04-21 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.1 * now xsolider comes with its own font * graphic.c: no longer use the X font (this is necessary for porting to SDL) * pixmap/font*.xpm: new files, provide the font * boss.c, enemy.c: enemies appear more gracefully * game.c: fixed counter of the number of normal enemies * Makefile.am: "make install" does not overwrite the high score file * INSTALL: added more info on the high score file 2002-04-21 Oohara Yuuma <oohara@libra.interq.or.jp> * version 1.0 * now I am the official developer of xsoldier (I got a mail from the original of xsoldier, Yuusuke HASHIMOTO <hachi@pm.highway.ne.jp>) * player.c: weapon 1 shoots more and damages less * game.c: set boss time to 2000 instead of 3000 if not in final stage * boss.c: teleportation of boss 6 takes less time * enemy.c: power-up items move faster * boss.c: boss has a fixed (independent of loop) hit point * game.c, player.c, player.h: you lose some of power-up items when you are killed * boss.c: reduced the amount of ring shots of the last boss * boss.c: the last boss shoots a 5way shot in loop 1 * enemy.c: enemy 6 may give you an item * player.c: set immutable time to 60 instead of 50 when starting/restarting * xsoldier.h: changed the argument of the srand() macro from s to x because the word "srand" contains the letter "s" * boss.c: homing shot of the last boss is faster * boss.c, enemy.c, enemyshot.c: fixed window edge detection * boss.c: fixed homing shot of boss 2 * main.c: you can enter the high score list even if you use the -wait option as long as the wait is not greater than default * game.c: normal enemies appear more frequently * main.c: made sig_handle() static * common.c, common.h, extern.h: translated all comments into English * graphic.c, graphic.h, input.c, input.h: new files, putting all X related stuff here * ending.c, game.c, opening.c: no more X stuff * boss.c: boss 2 can shoot backward in loop 2 or later * ending.c: added my name and fixed a typo * player.c: power-up item is O(loop), not O(loop^2) * main.c, star.c: free what is malloc()ed --- I always put away what I take * main.c: removed unnecessary headers * xsoldier.h: added #include "image.h" * ending.c: you can skip the ending by pressing space key * ending.c: the staff list scrolls at a fixed (independent of loop) speed * ending.c: added "press space key" message * player.c: change weapon item always makes you a bit powerful * INSTALL: added "required libraries" and fixed a typo * xsoldier.6: fixed typo in synopsis * README: new file, including overview, command line options, key control and explanation of bonus * LICENSE: added note on the files GPL and old-doc/CONDITION 2002-04-12 Oohara Yuuma <oohara@libra.interq.or.jp> * version 0.99 * putting old documents in old-doc/ * translated all comments into English * INSTALL: fixed the FHS way * main.c: fixed -display and -wait option * main.c: improved the error message for bad options * boss.c: the last boss is a bit weaker in loop 2 * game.c, main.c, manage.c, xsoldier.h: added -nopausemessage option * boss.c, enemy.c, game.c, player.c, score.c, star.c s/random()/rand()/g * main.c, xsoldier.h: s/random/rand/g, s/srandom/srand/g * configure.ac: checks rand() instead of random() * xsoldher.h: s/HAVE_RANDOM/HAVE_RAND/ * score.c: almost a complete rewrite * GPL: renamed, old name is COPYING * LICENSE: renamed, old name is CONDITION * LICENSE: added my name * boss.c: made boss 4 larger to prevent backstab * boss.c: made boss 8 smaller for better collision-detection * callback.c, game.c: draws a rectangle in the object's "real" size if debug is enabled * game.c: added do_actions() and collision_detection() * enemy.c: enemy 7 escapes from the upper side of the window (now weapon 2 is not the only way to get the perfect bonus) * game.c: improved shoot down bonus (shoot down bonus should be large enough so that missing a boss is a big loss, but small enough not to trivialize non-shooting bonus) * game.c: added shoot_down_bonus() and perfect_bonus() * enemyshot.c: made homing missiles more stupid * boss.c: boss 7 does escape from the window if the time is over * manage.c: always starts a loop with a fixed level (that is, 10) * game.c: normal enemies appear less frequently * enemy.c: normal eneimes have a fixed hit point (independent of loop) * main.c: set max length of player name * manage.c: added paranoid checks to NewPlayerData() 2002-04-02 Oohara Yuuma <oohara@libra.interq.or.jp> * version 0.98 * uses Makefile.am instead of Imakefile * put all *.c , *.h and the manpage under RCS * boss.c, callback.c, ending.c, enemy.c, game.c, joystick.c, manage.c, opening.c, player.c: hacked to avoid gcc -Wall warnings - added many #include - removed Japanese comments which are encoded to /* - removed unused variables * callback.c, ending.c, game.c, image.c, joystick.c, joystick.h, manage.c, manage.h, opening.c, score.c, sin.c, star.c, star.h: hacked to avoid gcc overkill warnings (see Makefile.am) - added many #include - declared some arguments and variables as const - converted switch statement to if-else because KeySym may not be int - avoid the name of a global variable in prototypes - removed unused arguments from printf * xsoldier.h: now defines WAIT, PIXMAP, SCORE and SCOREFILE * manage.h: added declaration of ClearEnemyShotManage() * player.c: initializes notShootingTime correctly (this fixes a bug which didn't give you the non-shooting bonus unless you shot at least once) * xsoldier.6: renamed, old name is "xsoldier.man" * fix/: dropped because it is not used * version.h: now VERSION is defined in config.h * main.c, xsoldier.6: added -maxlevel option * game.c: removed high score display because you don't need it during the game * main.c: checks invalid options * boss.c, ending.c, game.c, image.c, main.c, opening.c, player.c, score.c: now includes config.h * main.c: removed zero padding from the output of -score * xsoldier.h: replaced SYSV with HAVE_RANDOM because it only affects random() * INSTALL: added * image.c: fixed SplitImage debug message * main.c, manage.c, xsoldier.h: added -loop, -state, -maxpower and -ship options (all for debug only) * game.c, manage.c, xsoldier.h: never show shoot down bonus at the beginning of the game * ending.c: fixed a typo in the ending message * ending.c: the staff list scrolls slow in the loop 3 or later * image.c: fixed "isn't just" debug message * enemy.c: enemy 6 does disappear 2002-03-15 Oohara Yuuma <oohara@libra.interq.or.jp> * version 0.97 * based on the Debian package (version 1:0.96-14) * bug fixes: - boss.c: fixed the size of boss 1 and 4 (you can't backstab them) - boss.c: enables the hitmask when boss 6 reappears - enemyshot.c: added return NoneDel; at the end of EnemyLaserAct() (without this the function sometimes ends without calling return, resulting a suicide of the boss of the stage 4) - game.c: when handling Hit(), call the enemy's Hit first (necessary because Hit() of the weapon 3 changes its Attack and the damage is calculated in Hit() of the enemy) - joystick.c: applied Right and Down fix (fix available at the original author's webpage: http://www.surfline.ne.jp/hachi/xsoldier.html) - main.c: set the maximum number of player's object to 256 (64 seems to be insufficient for the weapon 2) - main.c: modified sig_handle() because sigaction() expects void f(int), not static void f(void) - opening.c: made sure stars moves at the normal speed * game balance tweaks: - ending.c: staff list scrolls faster - game.c: adjusted the interval between enemy's appearances - game.c, opening.c: disabled zero padding of scores - manage.c: max level (internal parameter) is now MaxLevel (which is currently 80), not 85 - player.c, player.h: made the player's weapons much more powerful - player.c: speed change is now 3 points/key-type instead of 5 - player.c: your weapon does not power down even if you are killed - xsoldier.h: extend every 200,000 points instead of 100,000 * new features: - boss.c, enemy.c: act routine improved a lot - boss.c, game.c, manage.c, xsoldier.h: a boss escapes if the time is up (in this case you don't get the shoot down bonus) - callback.c, enemy.c: dealing damage to a enemy gives you a score even if you don't destroy it - callback.c, enemy.c, game.c, manage.c: shows the remaining hit points of a enemy when you shoot it - game.c: shoot down bonus is bigger in second or later loop - game.c: perfect bonus raises the level - game.c: added c (clear enemy shot) key (enabled only when compiled with -DDEBUG) - game.c, manage.c: cleans enemy's shots when you restart - main.c: set max loop to 3 (24 stages total) - manage.c, player.c: gives you a score as long as you don't push the shot key - opening.c: added short help for debug-only commands - player.c: power up item gives you a score and raises the level if you already have enough power up items - player.c: the level will be lowered if you are killed * game.c: set the score limit to 10,000,000 * manage.c: added paranoid initialization of objects * score.c: s/strcpy()/strncpy()/g
Diffstat (limited to 'games')
-rw-r--r--games/xsoldier/Makefile28
-rw-r--r--games/xsoldier/PLIST69
-rw-r--r--games/xsoldier/distinfo13
-rw-r--r--games/xsoldier/patches/patch-aa40
-rw-r--r--games/xsoldier/patches/patch-ab59
-rw-r--r--games/xsoldier/patches/patch-ac12
-rw-r--r--games/xsoldier/patches/patch-ad21
-rw-r--r--games/xsoldier/patches/patch-main.c14
8 files changed, 69 insertions, 187 deletions
diff --git a/games/xsoldier/Makefile b/games/xsoldier/Makefile
index 2083624ace8..7005a853ef7 100644
--- a/games/xsoldier/Makefile
+++ b/games/xsoldier/Makefile
@@ -1,29 +1,25 @@
-# $NetBSD: Makefile,v 1.22 2012/10/06 11:55:03 asau Exp $
-#
+# $NetBSD: Makefile,v 1.23 2015/10/06 22:10:02 leot Exp $
-DISTNAME= xsoldier-0.96
-PKGREVISION= 2
+DISTNAME= xsoldier-1.8
CATEGORIES= games x11
MASTER_SITES= http://www.interq.or.jp/libra/oohara/xsoldier/
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://www.interq.or.jp/libra/oohara/xsoldier/
COMMENT= Updated xgalaga type game with awesome graphics
+LICENSE= gnu-gpl-v2
-SETGIDGAME= yes
-SPECIAL_PERMS+= bin/xsoldier ${SETGID_GAMES_PERMS}
+USE_PKGLOCALEDIR= yes
+USE_GAMESGROUP= yes
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS+= --localstatedir=${VARBASE}
-USE_IMAKE= YES
-NO_INSTALL_MANPAGES= YES
+BUILD_DEFS+= VARBASE
-MAKE_ENV+= BINOWN=${BINOWN:Q}
-
-CONF_FILES_PERMS= ${PREFIX}/share/xsoldier/xsoldier.score.dist \
- /var/games/xsoldier \
- games games 0664
-
-post-patch:
- ${TOUCH} ${WRKSRC}/xsoldier.man
+OWN_DIRS_PERMS+= ${VARBASE}/games/xsoldier ${GAMEDIR_PERMS}
+REQD_FILES_PERMS+= ${WRKSRC}/scorefile.txt \
+ ${VARBASE}/games/xsoldier/xsoldier.scores ${GAMEDATA_PERMS}
+SPECIAL_PERMS+= ${PREFIX}/bin/xsoldier ${SETGID_GAMES_PERMS}
.include "../../x11/libXpm/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/games/xsoldier/PLIST b/games/xsoldier/PLIST
index 8da16e41ed8..e62aa7db8b0 100644
--- a/games/xsoldier/PLIST
+++ b/games/xsoldier/PLIST
@@ -1,32 +1,39 @@
-@comment $NetBSD: PLIST,v 1.2 2009/06/14 17:57:01 joerg Exp $
+@comment $NetBSD: PLIST,v 1.3 2015/10/06 22:10:02 leot Exp $
bin/xsoldier
-share/xsoldier/Boss1.xpm
-share/xsoldier/Boss2.xpm
-share/xsoldier/Boss3.xpm
-share/xsoldier/Boss4.xpm
-share/xsoldier/Boss5.xpm
-share/xsoldier/Boss6.xpm
-share/xsoldier/Boss7.xpm
-share/xsoldier/Enemy1.xpm
-share/xsoldier/Enemy2.xpm
-share/xsoldier/Enemy3.xpm
-share/xsoldier/Enemy4.xpm
-share/xsoldier/Enemy5.xpm
-share/xsoldier/Enemy6.xpm
-share/xsoldier/Enemy7.xpm
-share/xsoldier/EnemyBound.xpm
-share/xsoldier/EnemyLaser.xpm
-share/xsoldier/EnemyMiss.xpm
-share/xsoldier/EnemyRing.xpm
-share/xsoldier/EnemyShot.xpm
-share/xsoldier/ExpLarge.xpm
-share/xsoldier/ExpSmall.xpm
-share/xsoldier/Item.xpm
-share/xsoldier/Player.xpm
-share/xsoldier/PlayerShot1.xpm
-share/xsoldier/PlayerShot2.xpm
-share/xsoldier/PlayerShot3.xpm
-share/xsoldier/Star1.xpm
-share/xsoldier/Star2.xpm
-share/xsoldier/Title.xpm
-share/xsoldier/xsoldier.score.dist
+man/man6/xsoldier.6
+share/games/xsoldier/Boss1.xpm
+share/games/xsoldier/Boss2.xpm
+share/games/xsoldier/Boss3.xpm
+share/games/xsoldier/Boss4.xpm
+share/games/xsoldier/Boss5.xpm
+share/games/xsoldier/Boss6.xpm
+share/games/xsoldier/Boss7.xpm
+share/games/xsoldier/Enemy1.xpm
+share/games/xsoldier/Enemy2.xpm
+share/games/xsoldier/Enemy3.xpm
+share/games/xsoldier/Enemy4.xpm
+share/games/xsoldier/Enemy5.xpm
+share/games/xsoldier/Enemy6.xpm
+share/games/xsoldier/Enemy7.xpm
+share/games/xsoldier/EnemyBound.xpm
+share/games/xsoldier/EnemyLaser.xpm
+share/games/xsoldier/EnemyMiss.xpm
+share/games/xsoldier/EnemyRing.xpm
+share/games/xsoldier/EnemyShot.xpm
+share/games/xsoldier/ExpLarge.xpm
+share/games/xsoldier/ExpSmall.xpm
+share/games/xsoldier/Item.xpm
+share/games/xsoldier/Player.xpm
+share/games/xsoldier/PlayerShot1.xpm
+share/games/xsoldier/PlayerShot2.xpm
+share/games/xsoldier/PlayerShot3.xpm
+share/games/xsoldier/Star1.xpm
+share/games/xsoldier/Star2.xpm
+share/games/xsoldier/Title.xpm
+share/games/xsoldier/font.xpm
+share/games/xsoldier/font1.xpm
+share/games/xsoldier/font2.xpm
+share/games/xsoldier/font3.xpm
+share/games/xsoldier/font4.xpm
+share/games/xsoldier/font5.xpm
+share/games/xsoldier/font6.xpm
diff --git a/games/xsoldier/distinfo b/games/xsoldier/distinfo
index d7321d69d3c..9df8223f0eb 100644
--- a/games/xsoldier/distinfo
+++ b/games/xsoldier/distinfo
@@ -1,9 +1,6 @@
-$NetBSD: distinfo,v 1.6 2010/02/14 22:28:55 joerg Exp $
+$NetBSD: distinfo,v 1.7 2015/10/06 22:10:02 leot Exp $
-SHA1 (xsoldier-0.96.tar.gz) = af16dbe1506cdd519a099ed58e26a5569400bea2
-RMD160 (xsoldier-0.96.tar.gz) = 2bf1d002b5a6e28af55c28f04cbda9fddd7bf1b8
-Size (xsoldier-0.96.tar.gz) = 82413 bytes
-SHA1 (patch-aa) = 570cc200b43deddebe84c5ced90593816f943044
-SHA1 (patch-ab) = 464407fb6e9e0af33b57d7dfc17a58acb1591f0a
-SHA1 (patch-ac) = 3551fd7507aa0ff8faeb9cdc8e2addc03dbc1274
-SHA1 (patch-ad) = 5689b9f211b89aebbc65eeabaac35531ab3ab819
+SHA1 (xsoldier-1.8.tar.gz) = 51ef7a55d0062015c54b5e31263875ba16068e10
+RMD160 (xsoldier-1.8.tar.gz) = 934364a47e77f8ac5fb1f289b933c0252560a2da
+Size (xsoldier-1.8.tar.gz) = 178220 bytes
+SHA1 (patch-main.c) = cc32312f304924859ea6978137d6c0db329c911b
diff --git a/games/xsoldier/patches/patch-aa b/games/xsoldier/patches/patch-aa
deleted file mode 100644
index 066050ac41e..00000000000
--- a/games/xsoldier/patches/patch-aa
+++ /dev/null
@@ -1,40 +0,0 @@
-$NetBSD: patch-aa,v 1.5 2010/02/14 22:28:55 joerg Exp $
---- Imakefile.orig Fri Feb 28 08:48:57 1997
-+++ Imakefile Mon Sep 14 16:52:46 1998
-@@ -11,12 +11,12 @@
-
- /* インストールディレクトリ */
- /* 書き込み権限が無いとインストール出来ません.=> 遊べない.(^^; */
--PIXMAPDIR = /usr/local/games/lib/xsoldier
--SCOREDIR = /usr/local/games/lib/xsoldier
--BINDIR = /usr/local/games
-+PIXMAPDIR = ${DESTDIR}$(PREFIX)/share/xsoldier
-+SCOREDIR = /var/games/
-+BINDIR = ${DESTDIR}$(PREFIX)/bin
-
- /* スコアファイル名.SCOREDIR 以下に置かれます. */
--SCOREFILE = .scorefile
-+SCOREFILE = xsoldier
-
-
- /* ----------------------------------------------------------------------- */
-@@ -93,9 +93,9 @@
- @echo "install update . done"
-
- install.score::
-- @if [ -d $(SCOREDIR) ]; then chmod 755 $(SCOREDIR); \
-- else $(MKDIRHIER) $(SCOREDIR); chmod 755 $(SCOREDIR); fi
-- $(INSTALL) -c -m 600 scorefile.txt $(SCOREDIR)/$(SCOREFILE)
-+ @if [ ! -e $(PIXMAPDIR)/$(SCOREFILE).score.dist ]; then \
-+ $(BSD_INSTALL_DATA) scorefile.txt $(PIXMAPDIR)/$(SCOREFILE).score.dist ; \
-+ fi
- @echo "install score . done"
-
- install.pixmap::
-@@ -109,5 +109,5 @@
- install.bin::
- @if [ -d $(BINDIR) ]; then set +x; \
- else (set -x; $(MKDIRHIER) $(BINDIR)); fi
-- $(INSTALL) -c -m 4755 $(PROGRAM) $(BINDIR)/$(PROGRAM)
-+ $(BSD_INSTALL_PROGRAM) $(PROGRAM) $(BINDIR)/$(PROGRAM)
- @echo "install bin . done"
diff --git a/games/xsoldier/patches/patch-ab b/games/xsoldier/patches/patch-ab
deleted file mode 100644
index 2524b32be03..00000000000
--- a/games/xsoldier/patches/patch-ab
+++ /dev/null
@@ -1,59 +0,0 @@
-$NetBSD: patch-ab,v 1.1 1999/12/23 01:44:03 wiz Exp $
---- main.c.orig Fri Feb 28 16:50:07 1997
-+++ main.c Wed Dec 22 02:32:19 1999
-@@ -49,8 +49,8 @@ static void clean(void);
- static void sig_handle(void);
-
- /*** ふぁいるぐろーばる ***/
--static char command[32];
--static char display[32] = {'\0'};
-+static char *command;
-+static char *display = NULL;
- static int scoreOK = True;
- static int putscore = False;
- static int colormap = True;
-@@ -65,7 +65,7 @@ int main(int argc, char *argv[])
- {
- int i;
- printf(" --- top 10 soldiers ---\n");
-- printf("Name Stage Score\n",command);
-+ printf("Name Stage Score\n");
- for (i=1; i<=10; i++)
- printf("%-20s %02d-%02d %08d\n",
- player->Rec[i].name,
-@@ -122,21 +122,19 @@ int main(int argc, char *argv[])
-
- static void arginit(int argc, char *argv[])
- {
-- char *argv0;
- int i;
-
-- if ((argv0=strrchr(argv[0],'/')) != NULL)
-- argv0++;
-+ if ((command=strrchr(argv[0],'/')) != NULL)
-+ command++;
- else
-- argv0 = argv[0];
-- strcpy(command,argv0); /*** コマンド名取得とコピー ***/
-+ command = argv[0];
-
- for (i=1; i<argc; i++)
- {
- if ((strcmp(argv[i],"-display")==0) || (strcmp(argv[i],"-d")==0))
- {
- if (i < argc-1)
-- strcpy(display,argv[i+1]);
-+ display = argv[i+1];
- }
- else if ((strcmp(argv[i],"-wait")==0) || (strcmp(argv[i],"-w")==0))
- {
-@@ -207,7 +205,8 @@ static void init(void)
- dpy = XOpenDisplay(display);
- if (dpy == NULL)
- {
-- fprintf(stderr,"init: [%s] can't open display.\n",display);
-+ fprintf(stderr,"init: [%s] can't open display.\n",
-+ display?display:getenv("DISPLAY")?getenv("DISPLAY"):":0");
- exit(1);
- }
-
diff --git a/games/xsoldier/patches/patch-ac b/games/xsoldier/patches/patch-ac
deleted file mode 100644
index d8079b51bd1..00000000000
--- a/games/xsoldier/patches/patch-ac
+++ /dev/null
@@ -1,12 +0,0 @@
-$NetBSD: patch-ac,v 1.1 1999/12/23 01:44:03 wiz Exp $
---- score.c.orig Mon Feb 24 16:25:44 1997
-+++ score.c Wed Dec 22 02:32:19 1999
-@@ -53,7 +53,7 @@ int ReadHiscore(PlayerData *p)
- p->Rec[i].score = score;
- p->Rec[i].loop = loop;
- p->Rec[i].stage = stage;
-- strcpy(p->Rec[i].name,name);
-+ strncpy(p->Rec[i].name,name,sizeof(p->Rec[i].name));
- }
- fclose(fp);
- }
diff --git a/games/xsoldier/patches/patch-ad b/games/xsoldier/patches/patch-ad
deleted file mode 100644
index b0a543bcd4e..00000000000
--- a/games/xsoldier/patches/patch-ad
+++ /dev/null
@@ -1,21 +0,0 @@
-$NetBSD: patch-ad,v 1.2 2004/05/23 23:28:29 danw Exp $
-
---- manage.c.orig Mon Feb 24 11:20:07 1997
-+++ manage.c
-@@ -9,7 +9,6 @@
-
- #include <stdio.h>
- #include <stdlib.h>
--#include <malloc.h>
- #include <X11/Xlib.h>
- #include <X11/Xutil.h>
-
-@@ -306,7 +305,7 @@ PlayerData *NewPlayerData(void)
- if ((pw=getpwuid(getuid())) == NULL)
- sprintf(name,"%d",getuid());
- else
-- strcpy(name,pw->pw_name);
-+ strncpy(name,pw->pw_name,sizeof(name));
-
- New = (PlayerData *)malloc(sizeof(PlayerData));
-
diff --git a/games/xsoldier/patches/patch-main.c b/games/xsoldier/patches/patch-main.c
new file mode 100644
index 00000000000..46b4c3fcaf7
--- /dev/null
+++ b/games/xsoldier/patches/patch-main.c
@@ -0,0 +1,14 @@
+$NetBSD: patch-main.c,v 1.1 2015/10/06 22:10:02 leot Exp $
+
+"wait.h" is no longer used and available.
+
+--- main.c.orig 2006-09-16 09:20:54.000000000 +0000
++++ main.c
+@@ -33,7 +33,6 @@
+ /* DeleteAllStar */
+ #include "star.h"
+ #include "score.h"
+-#include "wait.h"
+ #include "graphic.h"
+ #include "input.h"
+