aboutsummaryrefslogtreecommitdiff
path: root/games/blockrage
diff options
context:
space:
mode:
authorMichael Scheidell <scheidell@FreeBSD.org>2012-08-09 12:01:19 +0000
committerMichael Scheidell <scheidell@FreeBSD.org>2012-08-09 12:01:19 +0000
commit5c3dc9827c1d1ff5e6873977eb9bd4a2fa73726e (patch)
treef20ebc844406dcf48349c441fb53ddd62c3bef3f /games/blockrage
parentd2501d919f8bc96e65ef34f77bd70e618f2c1131 (diff)
downloadports-5c3dc9827c1d1ff5e6873977eb9bd4a2fa73726e.tar.gz
ports-5c3dc9827c1d1ff5e6873977eb9bd4a2fa73726e.zip
Notes
Diffstat (limited to 'games/blockrage')
-rw-r--r--games/blockrage/Makefile28
-rw-r--r--games/blockrage/files/blockrage.in7
2 files changed, 26 insertions, 9 deletions
diff --git a/games/blockrage/Makefile b/games/blockrage/Makefile
index 32541308eab0..30809211bb67 100644
--- a/games/blockrage/Makefile
+++ b/games/blockrage/Makefile
@@ -7,6 +7,7 @@
PORTNAME= blockrage
PORTVERSION= 0.2.3
+PORTREVISION= 1
CATEGORIES= games
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTVERSION}
@@ -15,36 +16,45 @@ COMMENT= Block Rage is falling blocks game with a 2-player hotseat mode
LICENSE= GPLv2
+OPTIONS_DEFINE= DATA
+OPTIONS_DEFAULT= DATA
+
GNU_CONFIGURE= yes
ALL_TARGET= ${PORTNAME}
USE_SDL= sdl image mixer
MAKE_JOBS_SAFE= yes
-PLIST_FILES= bin/blockrage
+PLIST_FILES= bin/${PORTNAME}
-MAN6= blockrage.6
+MAN6= ${PORTNAME}.6
PORTDATA= *
PORTDOCS= ChangeLog KNOWN_BUGS README TODO
+SUB_FILES= ${PORTNAME}
+
+.include <bsd.port.options.mk>
+
do-install:
# Scripts
- @${PRINTF} "#!/bin/sh\n\ncd ${DATADIR} &&\
- ./blockrage\n" > ${WRKDIR}/blockrage.sh
- @${INSTALL_SCRIPT} ${WRKDIR}/blockrage.sh ${PREFIX}/bin/blockrage
+ ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${PREFIX}/bin
+
# Executable
${MKDIR} ${DATADIR}
- ${INSTALL_PROGRAM} ${WRKSRC}/blockrage ${DATADIR}
+ ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${DATADIR}
post-install:
${INSTALL_MAN} ${WRKSRC}/${MAN6} ${MAN6PREFIX}/man/man6
+
# Data
-.for d in data blockrage-fhs.rc blockrage.cfg blockrage.rc
+.if ${PORT_OPTIONS:MDATA}
+. for d in data blockrage-fhs.rc blockrage.cfg blockrage.rc
@(cd ${WRKSRC} && ${COPYTREE_SHARE} ${d} ${DATADIR})
-.endfor
+. endfor
+.endif
# Documentations
-.if !defined(NOPORTDOCS)
+.if ${PORT_OPTIONS:MDOCS}
${MKDIR} ${DOCSDIR}
. for f in ${PORTDOCS}
${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
diff --git a/games/blockrage/files/blockrage.in b/games/blockrage/files/blockrage.in
new file mode 100644
index 000000000000..2e50a1170316
--- /dev/null
+++ b/games/blockrage/files/blockrage.in
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+
+echo "Block Rage: Starting up..."
+cd "%%DATADIR%%"
+./blockrage \ No newline at end of file