git: 9b6b0e1f4312 - main - games/minecraft-server: update to 1.20.6
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 10 Jun 2024 20:38:43 UTC
The branch main has been updated by vvd: URL: https://cgit.FreeBSD.org/ports/commit/?id=9b6b0e1f4312735dd31cb8220e8da3d50b37db12 commit 9b6b0e1f4312735dd31cb8220e8da3d50b37db12 Author: Alexandre Labarre <freebsd.tug890@passmail.net> AuthorDate: 2024-06-10 20:31:44 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2024-06-10 20:31:44 +0000 games/minecraft-server: update to 1.20.6 Changes: https://www.minecraft.net/en-us/article/minecraft-java-edition-1-20-5 https://www.minecraft.net/en-us/article/minecraft-java-edition-1-20-6 This version require at least Java 18 - bump to 21 (next LTS version). Add possibility to run with different Java versions using environment variable JAVA_VERSION for standalone server and minecraft_java_version variable in rc.conf for daemon. Also several small fixes. PR: 279204 Tested by: vvd Approved by: freebsd@jonathanprice.org (maintainer, timeout 20 days) --- games/minecraft-server/Makefile | 11 +++++----- games/minecraft-server/distinfo | 6 ++--- games/minecraft-server/files/minecraft-server.in | 5 ++++- games/minecraft-server/files/minecraft.in | 2 +- games/minecraft-server/files/pkg-deinstall.in | 2 +- games/minecraft-server/files/pkg-message.in | 7 ++++++ games/minecraft-server/pkg-plist | 28 +++++++++++++----------- 7 files changed, 37 insertions(+), 24 deletions(-) diff --git a/games/minecraft-server/Makefile b/games/minecraft-server/Makefile index 5838f53b667c..c709fe3e1c27 100644 --- a/games/minecraft-server/Makefile +++ b/games/minecraft-server/Makefile @@ -1,7 +1,7 @@ PORTNAME= minecraft-server -PORTVERSION= 1.20.4 +DISTVERSION= 1.20.6 CATEGORIES= games java -MASTER_SITES= https://piston-data.mojang.com/v1/objects/8dd1a28015f51b1803213892b50b7b4fc76e594d/ +MASTER_SITES= https://piston-data.mojang.com/v1/objects/145ff0858209bcfc164859ba735d4199aafa1eea/ DISTNAME= server EXTRACT_SUFX= .jar DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} @@ -17,12 +17,12 @@ LICENSE_TEXT= The license can be viewed at: https://account.mojang.com/documents LICENSE_PERMS= no-dist-mirror no-dist-sell no-pkg-mirror no-pkg-sell USE_JAVA= yes -JAVA_VERSION= 17 +JAVA_VERSION= 21 NO_ARCH= yes NO_BUILD= yes SUB_FILES= minecraft-server pkg-deinstall pkg-message -SUB_LIST= VERSION=${PORTVERSION} +SUB_LIST= JAVA_VERSION=${JAVA_VERSION} VERSION=${PORTVERSION} USERS= mcserver GROUPS= ${USERS} @@ -49,12 +49,13 @@ do-install: ${MKDIR} ${STAGEDIR}${ETCDIR} ${MKDIR} ${STAGEDIR}/var/db/minecraft-server ${MKDIR} ${STAGEDIR}/var/log/minecraft-server + ${MKDIR} ${STAGEDIR}/var/log/minecraft-server/debug .for file in ${CONFIG_FILES} ${LN} -s ${ETCDIR}/${file} ${STAGEDIR}${PREFIX}/${PORTNAME}/${file} .endfor + ${LN} -sf /var/db/minecraft-server ${STAGEDIR}${PREFIX}/${PORTNAME}/world ${LN} -sf /var/log/minecraft-server ${STAGEDIR}${PREFIX}/${PORTNAME}/logs ${LN} -sf /var/log/minecraft-server/debug ${STAGEDIR}${PREFIX}/${PORTNAME}/debug - ${LN} -sf /var/db/minecraft-server ${STAGEDIR}${PREFIX}/${PORTNAME}/world post-install-STANDALONE-on: ${INSTALL_SCRIPT} ${WRKDIR}/minecraft-server \ diff --git a/games/minecraft-server/distinfo b/games/minecraft-server/distinfo index 274aea17127d..eda4c31b11d3 100644 --- a/games/minecraft-server/distinfo +++ b/games/minecraft-server/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1708874498 -SHA256 (minecraft-server-1.20.4/server.jar) = c03fa6f39daa69ddf413c965a3a83084db746a7a138ce535a693293b5472d363 -SIZE (minecraft-server-1.20.4/server.jar) = 49150256 +TIMESTAMP = 1716300294 +SHA256 (minecraft-server-1.20.6/server.jar) = c6d01d018ca782e506f0ec60652d47fd565078be9122b625c1681bc86c29c7ec +SIZE (minecraft-server-1.20.6/server.jar) = 51420480 diff --git a/games/minecraft-server/files/minecraft-server.in b/games/minecraft-server/files/minecraft-server.in index 907ff1806c7d..959db1f0d617 100644 --- a/games/minecraft-server/files/minecraft-server.in +++ b/games/minecraft-server/files/minecraft-server.in @@ -5,6 +5,9 @@ if [ "$(id -u)" != "0" ]; then exit 1 fi -export JAVA_VERSION=17 +if [ -z "${JAVA_VERSION}" ]; then + JAVA_VERSION=%%JAVA_VERSION%% +fi +export JAVA_VERSION cd %%PREFIX%%/minecraft-server su -m mcserver -c "%%LOCALBASE%%/bin/java $(cat %%PREFIX%%/etc/minecraft-server/java-args.txt) -jar server.jar nogui" diff --git a/games/minecraft-server/files/minecraft.in b/games/minecraft-server/files/minecraft.in index 6eeaf0d09cae..ac2b0496f706 100644 --- a/games/minecraft-server/files/minecraft.in +++ b/games/minecraft-server/files/minecraft.in @@ -28,7 +28,7 @@ console_cmd="${name}_console" status_cmd="${name}_status" kill_cmd="${name}_kill" -export JAVA_VERSION=17 +export JAVA_VERSION=${minecraft_java_version:-"%%JAVA_VERSION%%"} is_running() { diff --git a/games/minecraft-server/files/pkg-deinstall.in b/games/minecraft-server/files/pkg-deinstall.in index 12946b6a016a..e1c1656f2f1c 100644 --- a/games/minecraft-server/files/pkg-deinstall.in +++ b/games/minecraft-server/files/pkg-deinstall.in @@ -12,4 +12,4 @@ echo "NOTE: The game world has not been deleted. It is still in" echo "/var/db/minecraft-server. If it is no longer required, it will" echo "need to be manually deleted." echo "Also, you may wish to delete any remaining files in" -echo "%%PREFIX%%/minecraft-server and %%ETCDIR%%" +echo "%%PREFIX%%/minecraft-server, %%ETCDIR%% and /var/log/minecraft-server" diff --git a/games/minecraft-server/files/pkg-message.in b/games/minecraft-server/files/pkg-message.in index 390cf46ca947..4aecf4043c9f 100644 --- a/games/minecraft-server/files/pkg-message.in +++ b/games/minecraft-server/files/pkg-message.in @@ -13,12 +13,19 @@ It is required to read the EULA, and then set eula=true Without daemon option: - To run the server, run %%PREFIX%%/bin/minecraft-server - To edit java's parameters, edit %%ETCDIR%%/java-args.txt +- To run with a specific version of Java, set environment variable JAVA_VERSION, + for example: + export JAVA_VERSION=22 + %%PREFIX%%/bin/minecraft-server + or: + JAVA_VERSION=22 %%PREFIX%%/bin/minecraft-server With daemon option: - The service has been installed with the name 'minecraft' - To adjust maximum memory usage (-Xmx), use minecraft_memx= in /etc/rc.conf - To adjust initial memory usage (-Xms), use minecraft_mems= in /etc/rc.conf - To add other java parameters, use minecraft_args= in /etc/rc.conf +- To run with a specific version of Java, use minecraft_java_version= in /etc/rc.conf - To see the interactive console, type service minecraft console EOM } diff --git a/games/minecraft-server/pkg-plist b/games/minecraft-server/pkg-plist index 9a8c87aa2341..1782fab03eda 100644 --- a/games/minecraft-server/pkg-plist +++ b/games/minecraft-server/pkg-plist @@ -17,15 +17,16 @@ minecraft-server/world @dir minecraft-server @dir /var/db/minecraft-server @dir /var/log/minecraft-server -@rmtry minecraft-server/libraries/com/github/oshi/oshi-core/6.4.5/oshi-core-6.4.5.jar +@dir /var/log/minecraft-server/debug +@rmtry minecraft-server/libraries/com/github/oshi/oshi-core/6.4.10/oshi-core-6.4.10.jar @rmtry minecraft-server/libraries/com/google/code/gson/gson/2.10.1/gson-2.10.1.jar @rmtry minecraft-server/libraries/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar @rmtry minecraft-server/libraries/com/google/guava/guava/32.1.2-jre/guava-32.1.2-jre.jar -@rmtry minecraft-server/libraries/com/mojang/authlib/6.0.52/authlib-6.0.52.jar +@rmtry minecraft-server/libraries/com/mojang/authlib/6.0.54/authlib-6.0.54.jar @rmtry minecraft-server/libraries/com/mojang/brigadier/1.2.9/brigadier-1.2.9.jar -@rmtry minecraft-server/libraries/com/mojang/datafixerupper/6.0.8/datafixerupper-6.0.8.jar -@rmtry minecraft-server/libraries/com/mojang/logging/1.1.1/logging-1.1.1.jar -@rmtry minecraft-server/libraries/commons-io/commons-io/2.13.0/commons-io-2.13.0.jar +@rmtry minecraft-server/libraries/com/mojang/datafixerupper/7.0.14/datafixerupper-7.0.14.jar +@rmtry minecraft-server/libraries/com/mojang/logging/1.2.7/logging-1.2.7.jar +@rmtry minecraft-server/libraries/commons-io/commons-io/2.15.1/commons-io-2.15.1.jar @rmtry minecraft-server/libraries/io/netty/netty-buffer/4.1.97.Final/netty-buffer-4.1.97.Final.jar @rmtry minecraft-server/libraries/io/netty/netty-codec/4.1.97.Final/netty-codec-4.1.97.Final.jar @rmtry minecraft-server/libraries/io/netty/netty-common/4.1.97.Final/netty-common-4.1.97.Final.jar @@ -37,15 +38,16 @@ minecraft-server/world @rmtry minecraft-server/libraries/io/netty/netty-transport-native-epoll/4.1.97.Final/netty-transport-native-epoll-4.1.97.Final-linux-x86_64.jar @rmtry minecraft-server/libraries/io/netty/netty-transport-native-unix-common/4.1.97.Final/netty-transport-native-unix-common-4.1.97.Final.jar @rmtry minecraft-server/libraries/it/unimi/dsi/fastutil/8.5.12/fastutil-8.5.12.jar -@rmtry minecraft-server/libraries/net/java/dev/jna/jna/5.13.0/jna-5.13.0.jar -@rmtry minecraft-server/libraries/net/java/dev/jna/jna-platform/5.13.0/jna-platform-5.13.0.jar +@rmtry minecraft-server/libraries/net/java/dev/jna/jna/5.14.0/jna-5.14.0.jar +@rmtry minecraft-server/libraries/net/java/dev/jna/jna-platform/5.14.0/jna-platform-5.14.0.jar @rmtry minecraft-server/libraries/net/sf/jopt-simple/jopt-simple/5.0.4/jopt-simple-5.0.4.jar -@rmtry minecraft-server/libraries/org/apache/commons/commons-lang3/3.13.0/commons-lang3-3.13.0.jar -@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-api/2.19.0/log4j-api-2.19.0.jar -@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-core/2.19.0/log4j-core-2.19.0.jar -@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-slf4j2-impl/2.19.0/log4j-slf4j2-impl-2.19.0.jar +@rmtry minecraft-server/libraries/org/apache/commons/commons-lang3/3.14.0/commons-lang3-3.14.0.jar +@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-api/2.22.1/log4j-api-2.22.1.jar +@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-core/2.22.1/log4j-core-2.22.1.jar +@rmtry minecraft-server/libraries/org/apache/logging/log4j/log4j-slf4j2-impl/2.22.1/log4j-slf4j2-impl-2.22.1.jar @rmtry minecraft-server/libraries/org/joml/joml/1.10.5/joml-1.10.5.jar -@rmtry minecraft-server/libraries/org/slf4j/slf4j-api/2.0.7/slf4j-api-2.0.7.jar -@rmtry minecraft-server/versions/1.20.4/server-1.20.4.jar +@rmtry minecraft-server/libraries/org/slf4j/slf4j-api/2.0.9/slf4j-api-2.0.9.jar +@rmtry minecraft-server/libraries/org/lz4/lz4-java/1.8.0/lz4-java-1.8.0.jar +@rmtry minecraft-server/versions/1.20.6/server-1.20.6.jar @owner @group