diff options
author | nia <nia@pkgsrc.org> | 2019-11-03 12:12:56 +0000 |
---|---|---|
committer | nia <nia@pkgsrc.org> | 2019-11-03 12:12:56 +0000 |
commit | e40443a8f3838a2b05f2c6bdecd8060d3c69ad97 (patch) | |
tree | b3ef289615343a147bfb0983bdc7ca229b020252 /games/openjk | |
parent | 396f2f73ae9f6a347dcf682f86afda8436499ed9 (diff) | |
download | pkgsrc-e40443a8f3838a2b05f2c6bdecd8060d3c69ad97.tar.gz |
Add games/openjk.
OpenJK is an effort by the JACoders group to maintain and improve the game
engine on which the Star Wars: Jedi Academy game runs on, while maintaining
full backwards compatibility with the existing game. This project does not
attempt to rebalance or otherwise modify core gameplay.
You will need a copy of Jedi Academy to play OpenJK.
Diffstat (limited to 'games/openjk')
-rw-r--r-- | games/openjk/DESCR | 6 | ||||
-rw-r--r-- | games/openjk/MESSAGE | 14 | ||||
-rw-r--r-- | games/openjk/Makefile | 81 | ||||
-rw-r--r-- | games/openjk/PLIST | 23 | ||||
-rw-r--r-- | games/openjk/distinfo | 7 | ||||
-rw-r--r-- | games/openjk/files/openjk.desktop | 9 | ||||
-rw-r--r-- | games/openjk/files/openjk.sh.in | 2 | ||||
-rw-r--r-- | games/openjk/patches/patch-CMakeModules_InstallConfig.cmake | 17 |
8 files changed, 159 insertions, 0 deletions
diff --git a/games/openjk/DESCR b/games/openjk/DESCR new file mode 100644 index 00000000000..ed1118b326a --- /dev/null +++ b/games/openjk/DESCR @@ -0,0 +1,6 @@ +OpenJK is an effort by the JACoders group to maintain and improve the game +engine on which the Star Wars: Jedi Academy game runs on, while maintaining +full backwards compatibility with the existing game. This project does not +attempt to rebalance or otherwise modify core gameplay. + +You will need a copy of Jedi Academy to play OpenJK. diff --git a/games/openjk/MESSAGE b/games/openjk/MESSAGE new file mode 100644 index 00000000000..c261b75106e --- /dev/null +++ b/games/openjk/MESSAGE @@ -0,0 +1,14 @@ +=========================================================================== +$NetBSD: MESSAGE,v 1.1 2019/11/03 12:12:56 nia Exp $ + +OpenJK requires the original game files from Star Wars: Jedi Knight: Jedi +Academy to be useful. + +If using the GOG version, you must extract the files from the setup exe +using the innoextract package. + +The files will be in a directory named app. Inside the app directory, there +is a GameData directory. Inside the GameData directory, there is a directory +named base. This base directory must be moved to ~/.local/share/openjk + +=========================================================================== diff --git a/games/openjk/Makefile b/games/openjk/Makefile new file mode 100644 index 00000000000..3e82b2d271f --- /dev/null +++ b/games/openjk/Makefile @@ -0,0 +1,81 @@ +# $NetBSD: Makefile,v 1.1 2019/11/03 12:12:56 nia Exp $ + +DISTNAME= openjk-0.0.0.20191030 +CATEGORIES= games +MASTER_SITES= ${MASTER_SITE_GITHUB:=JACoders/} +GITHUB_PROJECT= OpenJK +GITHUB_TAG= 4881be7478a833791d127fce7563de252d2246f7 + +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= https://github.com/JACoders/OpenJK +COMMENT= Community version of the Star Wars: Jedi Academy game engine +LICENSE= gnu-gpl-v2 + +WRKSRC= ${WRKDIR}/${GITHUB_PROJECT}-${GITHUB_TAG} + +TOOL_DEPENDS+= icoutils-[0-9]*:../../graphics/icoutils + +USE_CMAKE= yes +USE_TOOLS+= pkg-config +USE_LANGUAGES= c c++11 + +# C++11 +GCC_REQD+= 4.7 + +CMAKE_ARGS+= -DJK2InstallDir="share/JediAcademy" + +.include "../../mk/bsd.prefs.mk" +.if ${OPSYS} != "Darwin" +CXXFLAGS+= -I${BUILDLINK_DIR}/include/GL +.else +CMAKE_ARGS+= -DUseInternalJPEG=OFF +.endif + +.if ${MACHINE_ARCH} == "i386" && ${OPSYS} == "Darwin" +OPENJK_ARCH= x86 +.elif ${MACHINE_ARCH} == "powerpc" +OPENJK_ARCH= ppc +.elif !empty(MACHINE_ARCH:Mpowerpc64*) +OPENJK_ARCH= ppc64 +.elif !empty(MACHINE_ARCH:M*arm*) +OPENJK_ARCH= arm +.else +OPENJK_ARCH= ${MACHINE_ARCH} +.endif + +PLIST_SUBST+= OPENJK_ARCH=${OPENJK_ARCH} + +INSTALLATION_DIRS+= bin +INSTALLATION_DIRS+= share/applications + +post-build: +.for bin in openjk openjk_sp openjkded + ${SED} -e 's,@PREFIX@,${PREFIX},g' \ + -e 's,@OPENJK_BIN@,${bin}.${OPENJK_ARCH},g' \ + ${FILESDIR}/openjk.sh.in > ${WRKDIR}/${bin} +.endfor +.for s in 256 128 64 48 32 16 + ${PREFIX}/bin/icotool -x -w ${s} -h ${s} -o ${WRKDIR}/${s}.png \ + ${WRKSRC}/shared/icons/icon.ico +.endfor + +post-install: + ${INSTALL_SCRIPT} ${WRKDIR}/openjk ${DESTDIR}${PREFIX}/bin + ${INSTALL_SCRIPT} ${WRKDIR}/openjk_sp ${DESTDIR}${PREFIX}/bin + ${INSTALL_SCRIPT} ${WRKDIR}/openjkded ${DESTDIR}${PREFIX}/bin + ${INSTALL_DATA} ${FILESDIR}/openjk.desktop ${DESTDIR}${PREFIX}/share/applications +.for s in 256 128 64 48 32 16 + ${INSTALL_DATA_DIR} ${DESTDIR}${PREFIX}/share/icons/hicolor/${s}x${s}/apps + ${INSTALL_DATA} ${WRKDIR}/${s}.png \ + ${DESTDIR}${PREFIX}/share/icons/hicolor/${s}x${s}/apps/openjk.png +.endfor + +.include "../../audio/openal-soft/buildlink3.mk" +.include "../../devel/SDL2/buildlink3.mk" +.include "../../devel/zlib/buildlink3.mk" +.include "../../graphics/glu/buildlink3.mk" +.include "../../graphics/hicolor-icon-theme/buildlink3.mk" +.include "../../graphics/png/buildlink3.mk" +.include "../../mk/jpeg.buildlink3.mk" +.include "../../sysutils/desktop-file-utils/desktopdb.mk" +.include "../../mk/bsd.pkg.mk" diff --git a/games/openjk/PLIST b/games/openjk/PLIST new file mode 100644 index 00000000000..f7f96a3c5cb --- /dev/null +++ b/games/openjk/PLIST @@ -0,0 +1,23 @@ +@comment $NetBSD: PLIST,v 1.1 2019/11/03 12:12:56 nia Exp $ +bin/openjk +bin/openjk_sp +bin/openjkded +share/JediAcademy/OpenJK/cgame${OPENJK_ARCH}.so +share/JediAcademy/OpenJK/jagame${OPENJK_ARCH}.so +share/JediAcademy/OpenJK/jampgame${OPENJK_ARCH}.so +share/JediAcademy/OpenJK/ui${OPENJK_ARCH}.so +share/JediAcademy/base/cgame${OPENJK_ARCH}.so +share/JediAcademy/base/jampgame${OPENJK_ARCH}.so +share/JediAcademy/base/ui${OPENJK_ARCH}.so +share/JediAcademy/openjk.${OPENJK_ARCH} +share/JediAcademy/openjk_sp.${OPENJK_ARCH} +share/JediAcademy/openjkded.${OPENJK_ARCH} +share/JediAcademy/rd-vanilla_${OPENJK_ARCH}.so +share/JediAcademy/rdsp-vanilla_${OPENJK_ARCH}.so +share/applications/openjk.desktop +share/icons/hicolor/128x128/apps/openjk.png +share/icons/hicolor/16x16/apps/openjk.png +share/icons/hicolor/256x256/apps/openjk.png +share/icons/hicolor/32x32/apps/openjk.png +share/icons/hicolor/48x48/apps/openjk.png +share/icons/hicolor/64x64/apps/openjk.png diff --git a/games/openjk/distinfo b/games/openjk/distinfo new file mode 100644 index 00000000000..9fc2a8357dc --- /dev/null +++ b/games/openjk/distinfo @@ -0,0 +1,7 @@ +$NetBSD: distinfo,v 1.1 2019/11/03 12:12:56 nia Exp $ + +SHA1 (openjk-0.0.0.20191030-4881be7478a833791d127fce7563de252d2246f7.tar.gz) = 353e4014b3f1bf87cd0e50b995a40cc1eac220ff +RMD160 (openjk-0.0.0.20191030-4881be7478a833791d127fce7563de252d2246f7.tar.gz) = 56fe62caa27f4d9023701d39d6884fb4e1bc55f2 +SHA512 (openjk-0.0.0.20191030-4881be7478a833791d127fce7563de252d2246f7.tar.gz) = 2b98203573ec20acc3154acf701dcb2c378fa3cd93bb36e58a4ed89bbab15e0119fc4e8e2fb808a213e65ffb8ce12c5038763e5ef2285bad064e82599603e562 +Size (openjk-0.0.0.20191030-4881be7478a833791d127fce7563de252d2246f7.tar.gz) = 13394830 bytes +SHA1 (patch-CMakeModules_InstallConfig.cmake) = e7231d65a1504c1f87eebe4abfe3188a551f306b diff --git a/games/openjk/files/openjk.desktop b/games/openjk/files/openjk.desktop new file mode 100644 index 00000000000..9f758523cde --- /dev/null +++ b/games/openjk/files/openjk.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Jedi Knight: Jedi Academy +Exec=openjk --quiet +Terminal=false +Icon=openjk +Type=Application +Categories=Game;ActionGame; +Comment=Action shooter video game set in the Star Wars universe +Keywords=fps;first person shooter;dark forces;raven;deathmatch;multi-player;ctf; diff --git a/games/openjk/files/openjk.sh.in b/games/openjk/files/openjk.sh.in new file mode 100644 index 00000000000..8df5246344d --- /dev/null +++ b/games/openjk/files/openjk.sh.in @@ -0,0 +1,2 @@ +#!/bin/sh +cd @PREFIX@/share/JediAcademy && exec ./@OPENJK_BIN@ diff --git a/games/openjk/patches/patch-CMakeModules_InstallConfig.cmake b/games/openjk/patches/patch-CMakeModules_InstallConfig.cmake new file mode 100644 index 00000000000..a9d67dbb060 --- /dev/null +++ b/games/openjk/patches/patch-CMakeModules_InstallConfig.cmake @@ -0,0 +1,17 @@ +$NetBSD: patch-CMakeModules_InstallConfig.cmake,v 1.1 2019/11/03 12:12:56 nia Exp $ + +Install to share/. + +--- CMakeModules/InstallConfig.cmake.orig 2019-10-30 05:48:12.000000000 +0000 ++++ CMakeModules/InstallConfig.cmake +@@ -17,8 +17,8 @@ + #============================================================================ + + # Subdirectories to package JK2 and JKA into +-set(JKAInstallDir "JediAcademy") +-set(JK2InstallDir "JediOutcast") ++set(JKAInstallDir "share/JediAcademy") ++set(JK2InstallDir "share/JediOutcast") + + # Install components + set(JKAMPCoreComponent "JKAMPCore") |