Date: Tue, 14 Aug 2018 18:50:39 +0000 (UTC) From: Mikhail Teterin <mi@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r477194 - in head/games/jin: . files Message-ID: <201808141850.w7EIod4h059368@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mi Date: Tue Aug 14 18:50:39 2018 New Revision: 477194 URL: https://svnweb.freebsd.org/changeset/ports/477194 Log: Switch from installing pre-built JARs to building from source. Use the modern bsh provided by lang/beanshell instead of the ancient bundled version. Claim maintainership. Approved by: nivit (whilom maintainer) Added: head/games/jin/files/patch-build.xml (contents, props changed) head/games/jin/files/patch-new-bsh (contents, props changed) Modified: head/games/jin/Makefile head/games/jin/distinfo head/games/jin/files/jin.in head/games/jin/pkg-plist Modified: head/games/jin/Makefile ============================================================================== --- head/games/jin/Makefile Tue Aug 14 18:38:02 2018 (r477193) +++ head/games/jin/Makefile Tue Aug 14 18:50:39 2018 (r477194) @@ -3,40 +3,43 @@ PORTNAME= jin PORTVERSION= 2.14.1 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= games java MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION} -DISTNAME= ${PORTNAME}-${PORTVERSION}-unix +DISTNAME= ${PORTNAME}-${PORTVERSION}-source -MAINTAINER= nivit@FreeBSD.org +MAINTAINER= mi@aldan.algebra.com COMMENT= Graphical client for chess servers -NO_BUILD= yes +LICENSE= GPLv2+ +LICENSE_FILE= ${WRKSRC}/src/free/jin/legal/copyright.txt + +RUN_DEPENDS= ${JAVAJARDIR}/bsh.jar:lang/bsh +BUILD_DEPENDS= ${RUN_DEPENDS} + +USES= dos2unix +DOS2UNIX_GLOB= *.java *.txt USE_JAVA= yes -JAVA_VERSION= 1.6+ +USE_ANT= yes +MAKE_ARGS+= -lib ${JAVAJARDIR}/bsh.jar + SUB_FILES= ${PORTNAME} -SUB_LIST= JINJAR=${JINJAR} +SUB_LIST= JINJAR=${JINJAR:Q} JAVA_VERSION=${JAVA_PORT_VERSION:R} DATADIR= ${JAVASHAREDIR}/${PORTNAME} +EXTRACT_AFTER_ARGS= --exclude 'bsh*.jar' \ + --exclude os-specific/unix/jin \ + --exclude jgoodies-windows.jar + JINJAR= ${PORTNAME}.jar WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION} -FIND_DIRS= . -type d -FIND_DATA= . -type f -RM_FILES= ${PORTNAME} README changelog.txt gpl.txt - -post-extract: -.for f in ${RM_FILES} - @${RM} ${WRKSRC}/${f} -.endfor - do-install: - @${MKDIR} ${STAGEDIR}${DATADIR} - @cd ${WRKSRC} && ${FIND} ${FIND_DIRS} -exec ${MKDIR} ${STAGEDIR}${DATADIR}/{} ";" - @cd ${WRKSRC} && ${FIND} ${FIND_DATA} -exec ${INSTALL_DATA} {} ${STAGEDIR}${DATADIR}/{} ";" - @${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} + ${FIND} ${WRKSRC} -empty -delete + cd ${WRKSRC}/build && ${COPYTREE_BIN} . ${STAGEDIR}${DATADIR} + ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} .include <bsd.port.mk> Modified: head/games/jin/distinfo ============================================================================== --- head/games/jin/distinfo Tue Aug 14 18:38:02 2018 (r477193) +++ head/games/jin/distinfo Tue Aug 14 18:50:39 2018 (r477194) @@ -1,2 +1,3 @@ -SHA256 (jin-2.14.1-unix.tar.gz) = 07652a896ec36f037ba9fd0af0d714a24aaf478926c9adb3677d45b5bfb08544 -SIZE (jin-2.14.1-unix.tar.gz) = 17579169 +TIMESTAMP = 1534015381 +SHA256 (jin-2.14.1-source.tar.gz) = 7f3c346d42dffbeee07a1a0db2bb2ce4f3174b82fa8b9a581c0933df153671d6 +SIZE (jin-2.14.1-source.tar.gz) = 17854073 Modified: head/games/jin/files/jin.in ============================================================================== --- head/games/jin/files/jin.in Tue Aug 14 18:38:02 2018 (r477193) +++ head/games/jin/files/jin.in Tue Aug 14 18:50:39 2018 (r477194) @@ -1,5 +1,5 @@ #!/bin/sh # $FreeBSD$ cd %%DATADIR%% -JAVA_VERSION="%%JAVA_VERSION%%" \ -exec "%%LOCALBASE%%/bin/java" -jar %%DATADIR%%/%%JINJAR%% "$@" +export JAVA_VERSION="%%JAVA_VERSION%%+" +exec "%%LOCALBASE%%/bin/java" -cp %%JAVAJARDIR%%/bsh.jar:%%JINJAR%% free.jin.JinApplication "$@" Added: head/games/jin/files/patch-build.xml ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/games/jin/files/patch-build.xml Tue Aug 14 18:50:39 2018 (r477194) @@ -0,0 +1,22 @@ +--- build.xml 2007-03-04 19:55:00 -0500 ++++ build.xml 2018-08-11 17:06:49 -0400 +@@ -21,5 +21,4 @@ + <property name="build.dir" value="build" /> + <property name="build.compiler" value="modern" /> +- <property name="build.target" value="${java.specification.version}" /> + <property name="build.compress" value="no" /> + <property name="build.manifest" value="manifest.txt" /> +@@ -60,6 +59,4 @@ + includes="**" + classpathref="compile.class.path"> +- <compilerarg compiler="modern" line="-target ${build.target}" /> +- <compilerarg compiler="modern" line="-source 1.2" /> + </javac> + </target> +@@ -72,6 +69,4 @@ + includes="**" + classpath="${classes.dir}"> +- <compilerarg compiler="modern" line="-target ${build.target}" /> +- <compilerarg compiler="modern" line="-source 1.2" /> + </javac> + </target> Added: head/games/jin/files/patch-new-bsh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/games/jin/files/patch-new-bsh Tue Aug 14 18:50:39 2018 (r477194) @@ -0,0 +1,34 @@ +The Beanshell API has evolved since 2007, when Jin was last released... + + -mi + +--- src/free/jin/gamelogger/LoggingRule.java 2007-03-04 19:55:00 EDT ++++ src/free/jin/gamelogger/LoggingRule.java 2018-08-11 15:50:42 EDT +@@ -24,4 +24,5 @@ + import bsh.Interpreter; + import bsh.EvalError; ++import bsh.ParseException; + + +@@ -105,5 +106,5 @@ + Object val = bsh.eval(condition); + if (!(val instanceof Boolean)) +- throw new EvalError("Not a boolean expression"); ++ throw new ParseException(condition + ": Not a boolean expression"); + + this.condition = condition; +--- src/free/jin/scripter/CommandsScriptDialog.java 2007-03-04 19:54:59 EDT ++++ src/free/jin/scripter/CommandsScriptDialog.java 2018-08-11 15:55:06 EDT +@@ -32,4 +32,5 @@ + + import bsh.EvalError; ++import bsh.ParseException; + import bsh.Interpreter; + import free.jin.I18n; +@@ -176,5 +177,5 @@ + Object val = bsh.eval(condition); + if (!(val instanceof Boolean)) +- throw new EvalError("Not a boolean expression"); ++ throw new ParseException(condition + ": Not a boolean expression"); + } catch (EvalError e){ + I18n i18n = I18n.get(CommandsScriptDialog.class); Modified: head/games/jin/pkg-plist ============================================================================== --- head/games/jin/pkg-plist Tue Aug 14 18:38:02 2018 (r477193) +++ head/games/jin/pkg-plist Tue Aug 14 18:50:39 2018 (r477194) @@ -3,11 +3,8 @@ bin/jin %%DATADIR%%/actions/getserverhelp.jar %%DATADIR%%/actions/seek.jar %%DATADIR%%/chess.jar -%%DATADIR%%/copyright.txt -%%DATADIR%%/icon.png %%DATADIR%%/jin.jar %%DATADIR%%/libs/board.jar -%%DATADIR%%/libs/bsh-core-1.2b7.jar %%DATADIR%%/libs/console.jar %%DATADIR%%/libs/fics/timesealing.jar %%DATADIR%%/libs/icc/timestamping.jar @@ -77,5 +74,3 @@ bin/jin %%DATADIR%%/servers/chessclub.jar %%DATADIR%%/servers/freechess.jar %%DATADIR%%/util.jar -@dir %%DATADIR%%/actions/fics -@dir %%DATADIR%%/actions/icc
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201808141850.w7EIod4h059368>