pkgsrc/games/cbzone/patches/patch-aa
obache 4c846a6ef2 * honor VARBASE for game score file.
* add user-destdir installation support
* take care score file for binary package

Bump PKGREVISION.
2011-03-16 08:47:37 +00:00

72 lines
2.3 KiB
Text

$NetBSD: patch-aa,v 1.5 2011/03/16 08:47:37 obache Exp $
--- Imakefile.orig 1993-08-02 05:45:08.000000000 +0000
+++ Imakefile
@@ -32,9 +32,9 @@ HDRS = c_config.h \
ETCS = cbzone.help \
cbzone.motd \
- cbzone.script \
- cbzone.highscores \
- Cbzone.ad
+ cbzone.script \
+ cbzone.highscores \
+ Cbzone.ad
MISC = Imakefile \
Makefile.orig \
@@ -53,15 +53,15 @@ SOUNDS = sounds/enemy_seen.au \
# this is where the shellscript, and executable will go
# TANK_BINDIR = $(BINDIR)
-TANK_BINDIR= /usr/local/games
+TANK_BINDIR= $(PREFIX)/bin
# this is where the scorefile and helpfile will go
# TANK_LIBDIR = $(LIBDIR)
-TANK_LIBDIR = /usr/local/games/lib/cbzone
+TANK_LIBDIR = $(PREFIX)/share/cbzone
# this is where the app-defaults file will go
# TANK_APPDIR = $(XAPPLOADDIR)
-TANK_APPDIR = $(TANK_LIBDIR)
+TANK_APPDIR = $(XAPPLOADDIR)
# this is where the sound files go
TANK_SOUNDDIR = $(TANK_LIBDIR)/sounds
@@ -72,33 +72,22 @@ LOCAL_LIBRARIES = $(XTOOLLIB) $(XLIB) -l
AllTarget(cbzone.script)
AllTarget(cbzone.exec)
-
+
MakeDirectories(install,$(TANK_BINDIR) $(TANK_LIBDIR) $(TANK_APPDIR) $(TANK_SOUNDDIR))
InstallProgram(cbzone.exec,$(TANK_BINDIR))
InstallNamedProg(cbzone.script,cbzone,$(TANK_BINDIR))
InstallNonExec(cbzone.help,$(TANK_LIBDIR))
InstallNonExec(cbzone.motd,$(TANK_LIBDIR))
-InstallNonExec(cbzone.highscores,$(TANK_LIBDIR))
InstallNamedNonExec(Cbzone.ad,Cbzone,$(TANK_APPDIR))
InstallMultiple($(SOUNDS),$(TANK_SOUNDDIR))
-install::
- @if chgrp games $(TANK_BINDIR)/cbzone.exec $(TANK_LIBDIR)/cbzone.highscores 2>/dev/null ; then \
- (set -x ; chmod 2755 $(TANK_BINDIR)/cbzone.exec ) ; \
- (set -x ; chmod 664 $(TANK_LIBDIR)/cbzone.highscores ) ; \
- else \
- echo 'Failed: chgrp games for "cbzone.exec", "cbzone.highscores".' ; \
- echo ' highscore file exists but could not be protected.' ; \
- ( set -x ; chmod 666 $(TANK_LIBDIR)/cbzone.highscores ) ; \
- fi
-
cbzone.highscores:
touch $@
chmod 664 $@
cbzone.exec: $(OBJS) $(DEPLIBS)
- RemoveTargetProgram($@)
- $(CC) -o $@ $(OBJS) $(LDOPTIONS) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS)
+ RemoveTargetProgram($@)
+ $(CC) -o $@ $(OBJS) $(LDOPTIONS) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS)
cbzone.script : cbzone.script.src
rm -f $@