diff options
Diffstat (limited to 'games')
-rw-r--r-- | games/Makefile | 1 | ||||
-rw-r--r-- | games/java-games-suite/Makefile | 47 | ||||
-rw-r--r-- | games/java-games-suite/distinfo | 2 | ||||
-rw-r--r-- | games/java-games-suite/files/java-games-suite.sh.in | 25 | ||||
-rw-r--r-- | games/java-games-suite/pkg-descr | 12 |
5 files changed, 87 insertions, 0 deletions
diff --git a/games/Makefile b/games/Makefile index 3b35050c6142..81300b37e9ac 100644 --- a/games/Makefile +++ b/games/Makefile @@ -418,6 +418,7 @@ SUBDIR += ivan SUBDIR += jag SUBDIR += jaggedalliance2 + SUBDIR += java-games-suite SUBDIR += jchessboard SUBDIR += jfk SUBDIR += jfsw diff --git a/games/java-games-suite/Makefile b/games/java-games-suite/Makefile new file mode 100644 index 000000000000..95ab5e04e63c --- /dev/null +++ b/games/java-games-suite/Makefile @@ -0,0 +1,47 @@ +# Created by: Jason Helfman <jgh@FreeBSD.org> +# $FreeBSD$ + +PORTNAME= java-games-suite +PORTVERSION= 1.0 +CATEGORIES= games java +MASTER_SITES= SF/javagamessuite + +MAINTAINER= jgh@FreeBSD.org +COMMENT= Simple Java games collection + +USE_JAVA= yes +JAVA_VERSION= 1.6+ +PLIST_FILES= bin/java-games-suite \ + %%JAVAJARDIR%%/MM.jar \ + %%JAVAJARDIR%%/reversi.jar \ + %%JAVAJARDIR%%/Mine.jar \ + %%JAVAJARDIR%%/Tetris.jar \ + %%JAVAJARDIR%%/RT.jar \ + %%JAVAJARDIR%%/Number.jar +SUB_FILES= ${PORTNAME}.sh +GAMES= MM reversi Mine Tetris RT Number + +post-extract-script: +.for game in ${GAMES} + @${ECHO_CMD} "Main-Class: ${game}" > ${WRKSRC}/${game}/MANIFEST.MF +.endfor + +do-build: +.for game in ${GAMES} + cd ${WRKSRC}/${game} && \ + ${JAVAC} ${game}.java +.endfor + +post-build-script: +.for game in ${GAMES} + @cd ${WRKSRC}/${game} && \ + ${JAR} -cfm ${game}.jar MANIFEST.MF ${game}.java ${game}.class +.endfor + +do-install: +.for game in ${GAMES} + ${INSTALL_DATA} ${WRKSRC}/${game}/${game}.jar ${JAVAJARDIR} +.endfor + ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}.sh ${PREFIX}/bin/${PORTNAME} + +.include <bsd.port.mk> diff --git a/games/java-games-suite/distinfo b/games/java-games-suite/distinfo new file mode 100644 index 000000000000..834bd963aa90 --- /dev/null +++ b/games/java-games-suite/distinfo @@ -0,0 +1,2 @@ +SHA256 (java-games-suite-1.0.tar.gz) = 9a58681bf96872cdb542c7958dbeae6bf7cfa3a4f5b6dfa15245654777df348a +SIZE (java-games-suite-1.0.tar.gz) = 12779 diff --git a/games/java-games-suite/files/java-games-suite.sh.in b/games/java-games-suite/files/java-games-suite.sh.in new file mode 100644 index 000000000000..b40581e68a3a --- /dev/null +++ b/games/java-games-suite/files/java-games-suite.sh.in @@ -0,0 +1,25 @@ +#!/bin/sh + +case "$1" in + mastermind) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/MM.jar" + ;; + reversi) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/reversi.jar" + ;; + mine) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/Mine.jar" + ;; + tetris) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/Tetris.jar" + ;; + rt) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/RT.jar" + ;; + number) + JAVA_VERSION="%%JAVA_VERSION%%" "%%LOCALBASE%%/bin/java" -jar "%%JAVAJARDIR%%/Number.jar" + ;; + *) + echo $"Usage: $0 {mastermind|reversi|mine|tetris|rt|number}" + exit 1 +esac diff --git a/games/java-games-suite/pkg-descr b/games/java-games-suite/pkg-descr new file mode 100644 index 000000000000..b5ff763efd40 --- /dev/null +++ b/games/java-games-suite/pkg-descr @@ -0,0 +1,12 @@ +Simple Java games collection developed by Greg Cawthorne + +Current game list is: + +Tetris: Tetris, currently in beta +MM: MasterMind +Reversi: Commonly known as Othello. +Mine: MineSweeper +RT: Reaction Tester +Number: Number guessing game + +WWW: http://sourceforge.net/projects/javagamessuite |