aboutsummaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authormakc <makc@FreeBSD.org>2014-04-29 14:48:03 +0800
committermakc <makc@FreeBSD.org>2014-04-29 14:48:03 +0800
commita775654fd1de9abf2270351e1d720115c62aeb3c (patch)
treea6ba6117401c98eba8d48dfd1531276213c90250 /java
parent24b8e427f0d8c90c63a9e17ae69dfa1ac218cca0 (diff)
downloadfreebsd-ports-gnome-a775654fd1de9abf2270351e1d720115c62aeb3c.tar.gz
freebsd-ports-gnome-a775654fd1de9abf2270351e1d720115c62aeb3c.tar.zst
freebsd-ports-gnome-a775654fd1de9abf2270351e1d720115c62aeb3c.zip
java/jakarta-commons-collections:
- Add stage support - Drop unneeded JAVA_VERSION - Convert NOPORTDOCS to option - Clean up Makefile
Diffstat (limited to 'java')
-rw-r--r--java/jakarta-commons-collections/Makefile40
1 files changed, 14 insertions, 26 deletions
diff --git a/java/jakarta-commons-collections/Makefile b/java/jakarta-commons-collections/Makefile
index 11e72d2972f8..b22d9cbb82ad 100644
--- a/java/jakarta-commons-collections/Makefile
+++ b/java/jakarta-commons-collections/Makefile
@@ -13,40 +13,28 @@ MAINTAINER= ports@FreeBSD.org
COMMENT= Classes that extend/augment the Java Collections Framework
USE_JAVA= yes
-JAVA_VERSION= 1.6+
USE_ANT= yes
ALL_TARGET= jar
-.if !defined(NOPORTDOCS)
-ALL_TARGET+= javadoc
+PLIST_FILES= %%JAVAJARDIR%%/${PORTNAME}.jar
OTHERDOCS= DEVELOPERS-GUIDE.html LICENSE.txt PROPOSAL.html README.txt RELEASE-NOTES.html
PORTDOCS= apidocs ${OTHERDOCS}
-.endif
-JARFILE= ${PORTNAME}-${PORTVERSION}.jar
-DESTJARFILE= ${PORTNAME}.jar
-PLIST_FILES+= %%JAVAJARDIR%%/${DESTJARFILE}
-NO_STAGE= yes
-.include <bsd.port.pre.mk>
+OPTIONS_DEFINE= DOCS
-JDK_API!= (${FIND} -s ${LOCALBASE}/share/doc/jdk1.? -maxdepth 1 -name api -type d 2>/dev/null || ${ECHO_CMD}) | ${TAIL} -n 1
-.if ${JDK_API} != ""
-MAKE_ARGS+= -Djavadoc.links=${JDK_API}
-.endif
+DOCS_ALL_TARGET= javadoc
+
+.include <bsd.port.options.mk>
do-install:
- @${ECHO_MSG} -n ">> Installing JAR as ${JAVAJARDIR}/${DESTJARFILE}..."
- @${MKDIR} ${JAVAJARDIR}
- @${INSTALL_DATA} ${WRKSRC}/build/${JARFILE} ${JAVAJARDIR}/${DESTJARFILE}
- @${ECHO_MSG} " [ DONE ]"
-
-.if !defined(NOPORTDOCS)
- @${ECHO_MSG} -n ">> Installing documentation in ${DOCSDIR}..."
- @${MKDIR} ${DOCSDIR}
- @cd ${WRKSRC}/build/docs && ${FIND} apidocs \
- | ${CPIO} -pdmu -R ${SHAREOWN}:${SHAREGRP} ${DOCSDIR} > /dev/null 2>&1
- @${INSTALL_DATA} ${OTHERDOCS:S,^,${WRKSRC}/,} ${DOCSDIR}/
- @${ECHO_MSG} " [ DONE ]"
+ @${MKDIR} ${STAGEDIR}${JAVAJARDIR}
+ ${INSTALL_DATA} ${WRKSRC}/build/${PORTNAME}-${PORTVERSION}.jar \
+ ${STAGEDIR}${JAVAJARDIR}/${PORTNAME}.jar
+.if ${PORT_OPTIONS:MDOCS}
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ (cd ${WRKSRC}/build/docs && \
+ ${COPYTREE_SHARE} apidocs ${STAGEDIR}${DOCSDIR})
+ ${INSTALL_DATA} ${OTHERDOCS:S,^,${WRKSRC}/,} ${STAGEDIR}${DOCSDIR}
.endif
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>