git: 17cd2716cd27 - main - java/berkeley-db: upgrade from 6.2.31 to 7.5.11

From: Mikhail Teterin <mi_at_FreeBSD.org>
Date: Sat, 21 May 2022 23:02:18 UTC
The branch main has been updated by mi:

URL: https://cgit.FreeBSD.org/ports/commit/?id=17cd2716cd27c7b8675f3acc7f6412b69a47ae5b

commit 17cd2716cd27c7b8675f3acc7f6412b69a47ae5b
Author:     Mikhail Teterin <mi@FreeBSD.org>
AuthorDate: 2022-05-21 23:00:07 +0000
Commit:     Mikhail Teterin <mi@FreeBSD.org>
CommitDate: 2022-05-21 23:00:07 +0000

    java/berkeley-db: upgrade from 6.2.31 to 7.5.11
    
    Changelog: https://docs.oracle.com/cd/E17277_02/html/changelog.html
    
    Set LICENSE and otherwise pet portlint. Limit Java to 8 -- newer
    versions are rejected by the vendor's code...
---
 java/berkeley-db/Makefile | 26 +++++++++++++++++---------
 java/berkeley-db/distinfo |  5 +++--
 2 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/java/berkeley-db/Makefile b/java/berkeley-db/Makefile
index 0fe504a9a91e..efc4808c4c7d 100644
--- a/java/berkeley-db/Makefile
+++ b/java/berkeley-db/Makefile
@@ -1,7 +1,7 @@
 # Created by: Mikhail Teterin
 
 PORTNAME=	je
-PORTVERSION=	6.2.31
+PORTVERSION=	7.5.11
 CATEGORIES=	java databases
 MASTER_SITES=	http://download.oracle.com/berkeley-db/	\
 		http://download-east.oracle.com/berkeley-db/	\
@@ -10,20 +10,21 @@ MASTER_SITES=	http://download.oracle.com/berkeley-db/	\
 MAINTAINER=	mi@aldan.algebra.com
 COMMENT=	Berkeley DB Java Edition
 
-BUILD_DEPENDS=	${JAVALIBDIR}/junit.jar:java/junit
+LICENSE=	APACHE20
+LICENSE_FILE=	${WRKSRC}/LICENSE
 
-BROKEN_armv6=		fails to build: build.xml: Java returned: 1
-BROKEN_armv7=		fails to build: build.xml: Java returned: 1
+BUILD_DEPENDS=	${JAVALIBDIR}/junit.jar:java/junit
 
 OPTIONS_DEFINE=	DOCS EXAMPLES TEST
 
-USE_JAVA=	yes
+USE_JAVA=	8
 USE_ANT=	yes
 MAKE_ENV+=	JAVALIBDIR="${JAVALIBDIR}"
 MAKE_ARGS+=	-cp ${JAVALIBDIR}/junit.jar
+EXTRACT_AFTER_ARGS+=	--exclude '*.jar'
 
-PLIST_FILES=	%%JAVAJARDIR%%/je.jar
-
+PLIST_FILES=	${JAVAJARDIR:S,^${PREFIX}/,,}/je-${PORTVERSION}.jar \
+		${JAVAJARDIR:S,^${PREFIX}/,,}/je.jar
 PORTDOCS=	*
 PORTEXAMPLES=	*
 
@@ -31,7 +32,7 @@ regression-test check test: build
 	#
 	# Running the vendor-provided self-tests. This may take a while
 	#
-	if ! (cd ${BUILD_WRKSRC} ; ${MAKE_ENV} ${ANT} ${MAKE_ARGS} test) ; \
+	@if ! (cd ${BUILD_WRKSRC} ; ${MAKE_ENV} ${ANT} ${MAKE_ARGS} test) ; \
 	then	\
 		${ECHO_MSG} Please, review test failures and consider \
 			reporting them via \
@@ -62,11 +63,18 @@ post-build:
 
 post-patch:
 	@${REINPLACE_CMD} "s,/usr/local,${PREFIX}," ${WRKSRC}/build.xml
+	${FIND} ${WRKSRC} -type f -name \*.java | ${XARGS} \
+	    ${REINPLACE_CMD} -i "" -E 's,[^[:print:]]+, ,g'
 
 do-install:
-	${INSTALL_DATA} ${WRKSRC}/build/lib/je.jar ${STAGEDIR}${JAVAJARDIR}
+	${INSTALL_DATA} ${WRKSRC}/build/lib/je.jar ${STAGEDIR}${JAVAJARDIR}/je-${PORTVERSION}.jar
+	${LN} -s -f je-${PORTVERSION}.jar ${STAGEDIR}${JAVAJARDIR}/je.jar
+
+post-install-DOCS-on:
 	@${MKDIR} ${STAGEDIR}${DOCSDIR}
 	@(cd ${WRKSRC}/docs/ && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
+
+post-install-EXAMPLES-on:
 	@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
 	@(cd ${WRKSRC}/examples/ && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR})
 
diff --git a/java/berkeley-db/distinfo b/java/berkeley-db/distinfo
index 5fc874fa33ac..c6896f61a834 100644
--- a/java/berkeley-db/distinfo
+++ b/java/berkeley-db/distinfo
@@ -1,2 +1,3 @@
-SHA256 (je-6.2.31.tar.gz) = d8854f6385e8369232c9805ef94232c8e9c4800ec0c60ff79a6e60d00036b969
-SIZE (je-6.2.31.tar.gz) = 11198631
+TIMESTAMP = 1653092902
+SHA256 (je-7.5.11.tar.gz) = f82505e66dff5a97dc0d2e4eaed3c09dde5cad790a91528fcf5154894acd6f4c
+SIZE (je-7.5.11.tar.gz) = 12073401