From nobody Thu Aug 17 04:40:16 2023
X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1])
by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RRC3h3vyDz4qB9L;
Thu, 17 Aug 2023 04:40:16 +0000 (UTC)
(envelope-from git@FreeBSD.org)
Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256
client-signature RSA-PSS (4096 bits) client-digest SHA256)
(Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK))
by mx1.freebsd.org (Postfix) with ESMTPS id 4RRC3h3M6Vz3Q4L;
Thu, 17 Aug 2023 04:40:16 +0000 (UTC)
(envelope-from git@FreeBSD.org)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim;
t=1692247216;
h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
to:to:cc:mime-version:mime-version:content-type:content-type:
content-transfer-encoding:content-transfer-encoding;
bh=GiMZ1lPPix5N7vUExA6dBkitq7uRUX33M61nwFRXJmU=;
b=vYMmxHo5wp722++g3OAYV0kZA+dzC2NTVXhTUqJCVJFbvqyCpqPl2eAiA+v6iw7qidkQr/
DuQu6GOqhbEDIs3bGHegqGvQqGmK5jLLDX2XWI5Rp9WA31F9sefQRS/G6gB4fhCMK0xHb/
7N67VuCTFXPdKuZuEyKMUW7ovvRn9Hx3Az4Fn2R0X+OGJ77aunPnjatym24h3xDKy4gUz2
Sm6a03wp1q5DF0FJl3FIn73sZuZkWBeNY3fJwE7IDTv788PqAK5pIL/svHENWej0NfyK7C
bJNsykgd+UjJLz2JMmSN8z5S/llXIcCtArftwTt+z/f856foChjEEZeoOakJdQ==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org;
s=dkim; t=1692247216;
h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
to:to:cc:mime-version:mime-version:content-type:content-type:
content-transfer-encoding:content-transfer-encoding;
bh=GiMZ1lPPix5N7vUExA6dBkitq7uRUX33M61nwFRXJmU=;
b=T+WOKNJTqW1Ig6rMD/3gOwUgiJjGjwJeEEf+7aDiUpf3vxnbaUZvdhzZPKO8MzdWIdPkd2
AhacCdxwrCsgWf1ij5XCiRQMcegKU8l6oL09egFNykQNWYe4xKDuYWCvcc1WECCI3a6cVR
CROpIQFaJ1s3XzYXTGb69JEmglLtaOyNMAsayz4t61B6ySv7gLKvMJZ9QVILOnWpq20LoH
bpSX8RKoekb3qaZ9HKz7K8WAJnw0hNMyr3d8iaLm7SsmZn4oFe6D+Ob+6sYV2mQwndr05w
KHnmP45WPYGxKF6OiUU3qL6AjD9LHSdGSVeDML8h5SjPZsyz+t3baDU7t6daiQ==
ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1692247216; a=rsa-sha256; cv=none;
b=NKX86zb3tbL8PO04vIh3MSwPwxhj7ACcEv7LefGSjoXSFw+xl1hCMcoivwAuNgE/EkxXDz
/XnRVgUlm1C2ZkG+1xJZg2vW5C+agMfGt5ZXlC4ZwfySt4npUi7EjhABmSsMAx76k7dl6t
MsduuUoUFiQCyC2P0wis88uyxK3+RijSXQjkgAHeL3xAD0os2FbcSmI20IHyjEHMATPFew
hDXlu/ie/wcDO/MfMVYskVXBZKtExIlX/vhBM4ddNMFsA3rfQ0GgksMLOgQlKLBQhaBTYS
NqBWnsNgcBZEdL7IQichx+2pbPNf70LOgtDpTDYiyy82T9AXTbw2bQKVht1cVw==
ARC-Authentication-Results: i=1;
mx1.freebsd.org;
none
Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
(Client did not present a certificate)
by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RRC3h276Tz5Vc;
Thu, 17 Aug 2023 04:40:16 +0000 (UTC)
(envelope-from git@FreeBSD.org)
Received: from gitrepo.freebsd.org ([127.0.1.44])
by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 37H4eGBE054668;
Thu, 17 Aug 2023 04:40:16 GMT
(envelope-from git@gitrepo.freebsd.org)
Received: (from git@localhost)
by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 37H4eG7m054663;
Thu, 17 Aug 2023 04:40:16 GMT
(envelope-from git)
Date: Thu, 17 Aug 2023 04:40:16 GMT
Message-Id: <202308170440.37H4eG7m054663@gitrepo.freebsd.org>
To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org,
dev-commits-ports-main@FreeBSD.org
From: Koichiro Iwao
Subject: git: a1c897de331a - main - devel/maven: improve port for
multiple parallel versions
List-Id: Commits to the main branch of the FreeBSD ports repository
List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main
List-Help:
List-Post:
List-Subscribe:
List-Unsubscribe:
Sender: owner-dev-commits-ports-main@freebsd.org
X-BeenThere: dev-commits-ports-main@freebsd.org
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Git-Committer: meta
X-Git-Repository: ports
X-Git-Refname: refs/heads/main
X-Git-Reftype: branch
X-Git-Commit: a1c897de331a3363f0d74b0decf8d07ae2498f1c
Auto-Submitted: auto-generated
The branch main has been updated by meta:
URL: https://cgit.FreeBSD.org/ports/commit/?id=a1c897de331a3363f0d74b0decf8d07ae2498f1c
commit a1c897de331a3363f0d74b0decf8d07ae2498f1c
Author: Michael Osipov
AuthorDate: 2023-08-02 18:40:49 +0000
Commit: Koichiro Iwao
CommitDate: 2023-08-17 04:39:43 +0000
devel/maven: improve port for multiple parallel versions
PR: 272899
---
devel/maven/Makefile | 23 +++++++++++++----------
devel/maven/pkg-plist | 3 +--
2 files changed, 14 insertions(+), 12 deletions(-)
diff --git a/devel/maven/Makefile b/devel/maven/Makefile
index 2946e8d18566..38876c6aace3 100644
--- a/devel/maven/Makefile
+++ b/devel/maven/Makefile
@@ -1,8 +1,9 @@
PORTNAME= maven
DISTVERSION= 3.8.8
+PORTREVISION= 1
CATEGORIES= devel java
MASTER_SITES= APACHE/maven/maven-3/${DISTVERSION}/binaries
-DISTNAME= apache-maven-${DISTVERSION}-bin
+DISTNAME= apache-${PORTNAME}-${DISTVERSION}-bin
MAINTAINER= michaelo@apache.org
COMMENT= Java project management tool
@@ -17,17 +18,19 @@ CPE_VENDOR= apache
CPE_PRODUCT= maven
USE_JAVA= yes
-DATADIR= ${JAVASHAREDIR}/${PORTNAME}
+DATADIR= ${JAVASHAREDIR}/${INSTANCE_ID}
NO_ARCH= yes
NO_BUILD= yes
-WRKSRC= ${WRKDIR}/apache-maven-${DISTVERSION}
-PLIST_SUB= PORTVERSION=${PORTVERSION}
-INSTANCE_FILE= ${PORTNAME}-${PORTVERSION}
-INSTANCES_DIR= etc/maven-wrapper/instances.d/
+WRKSRC= ${WRKDIR}/${DISTNAME:S/-bin//}
+PLIST_SUB= PORTVERSION=${PORTVERSION} \
+ INSTANCE_ID=${INSTANCE_ID} \
+ INSTANCES_DIR=${INSTANCES_DIR}
+INSTANCE_ID= ${DISTNAME:S/-bin//:R}
+INSTANCES_DIR= ${LOCALBASE}/etc/maven-wrapper/instances.d
post-extract:
${RM} -r ${WRKSRC}/lib/jansi-native ${WRKSRC}/bin/*.cmd
- ${ECHO_CMD} "${DATADIR}" > ${WRKSRC}/${INSTANCE_FILE}
+ ${ECHO_CMD} "${DATADIR}" > ${WRKDIR}/${INSTANCE_ID}
post-patch:
@${REINPLACE_CMD} \
@@ -47,8 +50,8 @@ do-install:
${INSTALL_SCRIPT} ${WRKSRC}/bin/mvn ${STAGEDIR}${DATADIR}/bin
${INSTALL_SCRIPT} ${WRKSRC}/bin/mvnDebug ${STAGEDIR}${DATADIR}/bin
${INSTALL_SCRIPT} ${WRKSRC}/bin/mvnyjp ${STAGEDIR}${DATADIR}/bin
- @${MKDIR} ${STAGEDIR}${PREFIX}/${INSTANCES_DIR}
- ${INSTALL_DATA} ${WRKSRC}/${INSTANCE_FILE} \
- ${STAGEDIR}${PREFIX}/${INSTANCES_DIR}
+ @${MKDIR} ${STAGEDIR}${INSTANCES_DIR}
+ ${INSTALL_DATA} ${WRKDIR}/${INSTANCE_ID} \
+ ${STAGEDIR}${INSTANCES_DIR}
.include
diff --git a/devel/maven/pkg-plist b/devel/maven/pkg-plist
index 478dcab1dcd5..6bfdd1781c00 100644
--- a/devel/maven/pkg-plist
+++ b/devel/maven/pkg-plist
@@ -1,4 +1,4 @@
-%%ETCDIR%%-wrapper/instances.d/maven-%%PORTVERSION%%
+%%INSTANCES_DIR%%/%%INSTANCE_ID%%
%%DATADIR%%/LICENSE
%%DATADIR%%/NOTICE
%%DATADIR%%/README.txt
@@ -67,4 +67,3 @@
%%DATADIR%%/lib/wagon-http-3.5.3-shaded.jar
%%DATADIR%%/lib/wagon-provider-api-3.5.3.jar
%%DATADIR%%/lib/ext/README.txt
-%%DATADIR%%/maven-%%PORTVERSION%%