Bug 65298 - [MAINTAINER] java/trove4j: update to 1.1b3 and pkg-plist removal
Summary: [MAINTAINER] java/trove4j: update to 1.1b3 and pkg-plist removal
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Greg Lewis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-04-07 19:00 UTC by Hervé Quiroz
Modified: 2004-04-09 18:56 UTC (History)
0 users

See Also:


Attachments
trove4j-1.1b3.patch (3.28 KB, patch)
2004-04-07 19:00 UTC, Hervé Quiroz
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Hervé Quiroz 2004-04-07 19:00:34 UTC
- Update to 1.1b3
- Use PLIST_FILES to remove pkg-plist entirely
- Done some cleanning
- Use MASTER_SITE_SOURCEFORGE_EXTENDED
- Moved some statements so portlint does not complain anymore
- Added 'devel' category

Generated with FreeBSD Port Tools 0.50
Comment 1 Greg Lewis freebsd_committer freebsd_triage 2004-04-08 16:40:39 UTC
Responsible Changed
From-To: freebsd-ports-bugs->glewis

I'll take this. 

Herve, one comment.  I think that ${ECHO_MSG} is more appropriate than 
${ECHO_CMD} for displaying messages to the user during install.
Comment 2 Hervé Quiroz 2004-04-08 18:44:15 UTC
Greg,

> Herve, one comment.  I think that ${ECHO_MSG} is more appropriate than 
> ${ECHO_CMD} for displaying messages to the user during install.

I don't know actually, as ${ECHO_MSG} will print messages after a
"===>", which will make them appear like make(1) feedback. I used
${ECHO_CMD} to produce ">> " statements looking like the results from
checksum verification for instance:

$ make
===>  Vulnerability check disabled
===>  Extracting for trove4j-1.0.2_1
>> Checksum OK for trove-1.0.2.tar.gz.
===>  Patching for trove4j-1.0.2_1
===>  Configuring for trove4j-1.0.2_1

But I understand your point as using ${ECHO_MSG} will allow the final
user to reduce the verbosity if he wants to.

So I agree with your suggestion. I will use ${ECHO_MSG} from now for all
of my ports. There will be a problem with the '-n' switch, so that means
that the port will not notify what is being installed to the user, just
where this is going to be installed, which is not a problem actually.

Do you want me to submit another patch ? If I have some time before I go
home, I will send you something.

I discovered another issue with this port: ${INSTALL_MAN} should be used
to install man pages (I thought it was manual pages actually). This will
have nasty effects if the user chooses to compress man pages on-the-fly.
So we should probably change this for ${INSTALL_DATA}. Anyway, all of
the other ports use directly ${CP} so why bother? I initially used
${INSTALL_*} macros to have user/group permissions correctly set...

That means we will need a patch so I will send you something in a few
hours.

Herve
Comment 3 Greg Lewis 2004-04-08 19:21:56 UTC
On Thu, Apr 08, 2004 at 07:44:15PM +0200, Herve Quiroz wrote:
> Greg,
> 
> > Herve, one comment.  I think that ${ECHO_MSG} is more appropriate than 
> > ${ECHO_CMD} for displaying messages to the user during install.
> 
> I don't know actually, as ${ECHO_MSG} will print messages after a
> "===>", which will make them appear like make(1) feedback. I used
> ${ECHO_CMD} to produce ">> " statements looking like the results from
> checksum verification for instance:

Uh no.  Thats not how ECHO_MSG works.  From bsd.port.mk:

ECHO_MSG?=              ${ECHO_CMD}

So you can do a straight replace of your ${ECHO_CMD} with ${ECHO_MSG}.
Its just the more appropriate thing to use for printing messages to the
user.

> So I agree with your suggestion. I will use ${ECHO_MSG} from now for all
> of my ports. There will be a problem with the '-n' switch, so that means
> that the port will not notify what is being installed to the user, just
> where this is going to be installed, which is not a problem actually.

See above, there will be no problem with -n :).

> Do you want me to submit another patch ? If I have some time before I go
> home, I will send you something.

Yes please, as it seems you have some other things to fix below.

> I discovered another issue with this port: ${INSTALL_MAN} should be used
> to install man pages (I thought it was manual pages actually). This will

It is manual pages, its just often abbreviated man pages.

> have nasty effects if the user chooses to compress man pages on-the-fly.
> So we should probably change this for ${INSTALL_DATA}. Anyway, all of
> the other ports use directly ${CP} so why bother? I initially used
> ${INSTALL_*} macros to have user/group permissions correctly set...

I see what you mean.  The port is installing documentation with
${INSTALL_MAN}.  Yes, it should use ${INSTALL_DATA} instead.

Personally I would probably install the javadoc stuff with cpio and
the install the individual files in a for loop rather than have one
for loop doing both the directory and the files.  But thats more a
matter of taste.

> That means we will need a patch so I will send you something in a few
> hours.

Thanks!

-- 
Greg Lewis                          Email   : glewis@eyesbeyond.com
Eyes Beyond                         Web     : http://www.eyesbeyond.com
Information Technology              FreeBSD : glewis@FreeBSD.org
Comment 4 Hervé Quiroz 2004-04-08 20:50:14 UTC
On Thu, Apr 08, 2004 at 12:21:56PM -0600, Greg Lewis wrote:
> Uh no.  Thats not how ECHO_MSG works.  From bsd.port.mk:
> 
> ECHO_MSG?=              ${ECHO_CMD}
> 
> So you can do a straight replace of your ${ECHO_CMD} with ${ECHO_MSG}.
> Its just the more appropriate thing to use for printing messages to the
> user.

You're right. I don't know how I managed to misunderstand this... But I
was working on another PR regarding bsd.java.mk in the same time (that
you should receive in a few minutes BTW).

> Personally I would probably install the javadoc stuff with cpio and
> the install the individual files in a for loop rather than have one
> for loop doing both the directory and the files.  But thats more a
> matter of taste.
> 
> > That means we will need a patch so I will send you something in a few
> > hours.

And here it is:


diff -ur trove4j.original/Makefile trove4j/Makefile
--- trove4j.original/Makefile	Thu Apr  8 21:39:02 2004
+++ trove4j/Makefile	Thu Apr  8 21:43:58 2004
@@ -5,48 +5,39 @@
 # $FreeBSD: ports/java/trove4j/Makefile,v 1.5 2004/04/06 06:41:31 glewis Exp $
 
 PORTNAME=	trove4j
-PORTVERSION=	1.0.2
-PORTREVISION=	1
-CATEGORIES=	java
-MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
+PORTVERSION=	1.1b3
+CATEGORIES=	java devel
+MASTER_SITES=	${MASTER_SITE_SOURCEFORGE_EXTENDED}
 MASTER_SITE_SUBDIR=	trove4j
 DISTNAME=	trove-${PORTVERSION}
-COMMENT=	GNU Trove: High performance collections for Java
 
 MAINTAINER=	herve.quiroz@esil.univ-mrs.fr
+COMMENT=	GNU Trove: High performance collections for Java
 
 USE_JAVA=	yes
 JAVA_VERSION=	1.3+
 JAVA_RUN=	jdk
-NO_BUILD=	YES
-
-PORT_JARFILE=		trove.jar
-JAVA_WRKLIBDIR=		${WRKSRC}/lib
-JAVA_WRKDOCSDIR=	${WRKSRC}/javadocs
-PLIST_SUB+=		JAVAJARDIR=${JAVAJARDIR:S/^${PREFIX}\///}
+NO_BUILD=	yes
 
 .if !defined(NOPORTDOCS)
-PORTDOCS=	AUTHORS ChangeLog LICENSE.txt README-license.txt README.txt javadocs
+PORTDOCS=	javadocs AUTHORS ChangeLog LICENSE.txt README-license.txt README.txt
 .endif
+JARFILE=	trove.jar
+PLIST_FILES+=	${JAVAJARDIR:S,^${PREFIX}/,,}/${JARFILE}
 
 do-install:
-	@${ECHO_CMD} -n ">> Installing JAR file..."
+	@${ECHO_MSG} -n ">> Installing JAR as ${JAVAJARDIR}/${JARFILE}..."
 	@${MKDIR} ${JAVAJARDIR}
-	@cd ${JAVA_WRKLIBDIR} && ${INSTALL_DATA} ${PORT_JARFILE} ${JAVAJARDIR}
-	@${ECHO_CMD} " [DONE]"
+	@${CP} ${WRKSRC}/lib/${JARFILE} ${JAVAJARDIR}/
+	@${ECHO_MSG} " [ DONE ]"
 .if !defined(NOPORTDOCS)
-	@${ECHO_CMD} -n ">> Installing documentation..."
-	@cd ${JAVA_WRKDOCSDIR} && ${FIND} . -type d -exec ${MKDIR} ${DOCSDIR}/javadocs/{} ";"
-	@cd ${JAVA_WRKDOCSDIR} && ${FIND} . -type f -exec ${INSTALL_MAN} ${JAVA_WRKDOCSDIR}/{} ${DOCSDIR}/javadocs/{} ";"
-	@${INSTALL_MAN} ${WRKSRC}/AUTHORS ${DOCSDIR}/AUTHORS
-	@${INSTALL_MAN} ${WRKSRC}/ChangeLog ${DOCSDIR}/ChangeLog
-	@${INSTALL_MAN} ${WRKSRC}/LICENSE.txt ${DOCSDIR}/LICENSE.txt
-	@${INSTALL_MAN} ${WRKSRC}/README-license.txt ${DOCSDIR}/README-license.txt
-	@${INSTALL_MAN} ${WRKSRC}/README.txt ${DOCSDIR}/README.txt
-	@${ECHO_CMD} " [DONE]"
+	@${ECHO_MSG} -n ">> Installing documentation..."
+	@${MKDIR} ${DOCSDIR}
+.for DOCFILE in ${PORTDOCS}
+	@${CP} -r ${WRKSRC}/${DOCFILE} ${DOCSDIR}/
+	@${ECHO_MSG} -n " ${DOCFILE}"
+.endfor
+	@${ECHO_MSG} " [ DONE ]"
 .endif
-
-post-install:
-	@${ECHO_CMD} "${PORTNAME}-${PORTVERSION} installed as ${JAVAJARDIR}/${PORT_JARFILE}"
 
 .include <bsd.port.mk>
diff -ur trove4j.original/distinfo trove4j/distinfo
--- trove4j.original/distinfo	Thu Apr  8 21:39:02 2004
+++ trove4j/distinfo	Thu Apr  8 21:40:45 2004
@@ -1,2 +1,2 @@
-MD5 (trove-1.0.2.tar.gz) = a246a09db112b7986b02c2a9f771bae0
-SIZE (trove-1.0.2.tar.gz) = 796214
+MD5 (trove-1.1b3.tar.gz) = 14358eb68de9c2dfc7a132b58d2b899c
+SIZE (trove-1.1b3.tar.gz) = 805653
diff -ur trove4j.original/pkg-plist trove4j/pkg-plist
--- trove4j.original/pkg-plist	Thu Apr  8 21:39:02 2004
+++ trove4j/pkg-plist	Thu Apr  8 21:40:45 2004
@@ -1 +0,0 @@
-%%JAVAJARDIR%%/trove.jar
Comment 5 Greg Lewis freebsd_committer freebsd_triage 2004-04-09 18:56:18 UTC
State Changed
From-To: open->closed

Committed, thanks!