Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Jan 2018 00:47:05 +0000 (UTC)
From:      Joseph Mingrone <jrm@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r460151 - head/www/tomcat85
Message-ID:  <201801280047.w0S0l5St031565@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jrm
Date: Sun Jan 28 00:47:05 2018
New Revision: 460151
URL: https://svnweb.freebsd.org/changeset/ports/460151

Log:
  www/tomcat85: Silence portlint warnings and modernize
  
  The blocks were updated to conform to the 'Order of Variables in Port
  Makefiles' chapter in the Porter's Handbook.
  
  PR:		225458
  Approved by:	vvd@unislabs.com (maintainer)
  Differential Revision:	https://reviews.freebsd.org/D14071

Modified:
  head/www/tomcat85/Makefile   (contents, props changed)
  head/www/tomcat85/pkg-plist   (contents, props changed)

Modified: head/www/tomcat85/Makefile
==============================================================================
--- head/www/tomcat85/Makefile	Sat Jan 27 20:14:28 2018	(r460150)
+++ head/www/tomcat85/Makefile	Sun Jan 28 00:47:05 2018	(r460151)
@@ -17,78 +17,55 @@ RUN_DEPENDS=	jsvc:devel/jakarta-commons-daemon
 
 USES=		cpe
 CPE_VENDOR=	apache
-
 USE_JAVA=	yes
 JAVA_VERSION=	1.7+
-NO_BUILD=	yes
-NO_ARCH=	yes
-
 USE_RC_SUBR=	${PKGBASE}
 
-TOMCAT_SUBDIR?=	${DISTNAME:R}
-TOMCAT_HOME=	${PREFIX}/${TOMCAT_SUBDIR}
-TOMCAT_CONF_FILES=	\
-		catalina.policy catalina.properties context.xml logging.properties \
-		server.xml tomcat-users.xml tomcat-users.xsd web.xml \
-		jaspic-providers.xml jaspic-providers.xsd
-
-OPTIONS_DEFINE= HOST_MANAGER MANAGER DOCS EXAMPLES ROOT
-HOST_MANAGER_DESC= Install Host Manager application
-MANAGER_DESC= Install Manager web application
-DOCS_DESC= Install Documentation web application
-EXAMPLES_DESC= Install Examples web application
-ROOT_DESC= Install default ROOT web application
-OPTIONS_DEFAULT= HOST_MANAGER MANAGER DOCS EXAMPLES ROOT
-OPTIONS_SUB= yes
-
+NO_ARCH=	yes
+NO_BUILD=	yes
 PLIST_SUB=	T=${TOMCAT_SUBDIR} \
-		WWWOWN=${WWWOWN} WWWGRP=${WWWGRP}
-
+		WWWOWN=${WWWOWN} \
+		WWWGRP=${WWWGRP}
 SUB_LIST=	TOMCAT_HOME=${TOMCAT_HOME} \
 		TOMCAT_USER=${WWWOWN} \
 		JAVA_HOME=${JAVA_HOME}
 
-.include <bsd.port.pre.mk>
+OPTIONS_DEFINE=		HOST_MANAGER MANAGER DOCS EXAMPLES ROOT
+OPTIONS_DEFAULT=	HOST_MANAGER MANAGER DOCS EXAMPLES ROOT
+OPTIONS_SUB=		yes
 
-pre-patch:
-	@${ECHO_MSG} "Installation settings:"
-	@${ECHO_MSG} "   Destination directory:    ${TOMCAT_HOME}"
-	@${ECHO_MSG} "   Location of JDK:          ${JAVA_HOME}"
-	@${ECHO_MSG} "   Location of Java port:    ${JAVA_PORT}"
+DOCS_DESC=		Install Documentation web application
+EXAMPLES_DESC=		Install Examples web application
+HOST_MANAGER_DESC=	Install Host Manager application
+MANAGER_DESC=		Install Manager web application
+ROOT_DESC=		Install default ROOT web application
 
-post-patch:
-	@${FIND} ${WRKSRC} -name '*.bat' -delete
-.for f in ${TOMCAT_CONF_FILES}
-	@${MV} ${WRKSRC}/conf/${f} ${WRKSRC}/conf/${f}.sample
-.endfor
+TOMCAT_SUBDIR?=	${DISTNAME:R}
+TOMCAT_HOME=	${PREFIX}/${TOMCAT_SUBDIR}
 
 do-install:
-	@${ECHO_MSG} -n ">> Creating destination directory..."
 	@${MKDIR} ${STAGEDIR}${TOMCAT_HOME}/logs
 	@${MKDIR} ${STAGEDIR}${TOMCAT_HOME}/endorsed
-	@${ECHO_MSG} " [ DONE ]"
+	${CP} -R ${WRKSRC}/* ${STAGEDIR}${TOMCAT_HOME}
 
-	@${ECHO_MSG} -n ">> Copying files to destination directory..."
-	@${CP} -R ${WRKSRC}/* ${STAGEDIR}${TOMCAT_HOME}
-.if !${PORT_OPTIONS:MHOST_MANAGER}
+post-install:
+	@${RM} ${STAGEDIR}${TOMCAT_HOME}/bin/*.bat
+	(cd ${STAGEDIR}${TOMCAT_HOME}/conf &&\
+		for f in $$(find . -type f); do ${MV} $$f $$f.sample; done)
+
+post-install-HOST_MANAGER-off:
 	@${RM} -R ${STAGEDIR}${TOMCAT_HOME}/webapps/host-manager
-.endif
-.if !${PORT_OPTIONS:MMANAGER}
+
+post-install-MANAGER-off:
 	@${RM} -R ${STAGEDIR}${TOMCAT_HOME}/webapps/manager
-.endif
-.if !${PORT_OPTIONS:MDOCS}
+
+post-install-DOCS-off:
 	@${RM} -R ${STAGEDIR}${TOMCAT_HOME}/webapps/docs
-.endif
-.if !${PORT_OPTIONS:MEXAMPLES}
+
+post-install-EXAMPLES-off:
 	@${RM} -R ${STAGEDIR}${TOMCAT_HOME}/webapps/examples
-.endif
-.if !${PORT_OPTIONS:MROOT}
+
+post-install-ROOT-off:
 	@${RM} -R ${STAGEDIR}${TOMCAT_HOME}/webapps/ROOT
-.endif
-	@${ECHO_MSG} " [ DONE ]"
 
-	@${ECHO_MSG} -n ">> Fixing permissions..."
-	@${FIND} ${STAGEDIR}${TOMCAT_HOME} -type d -print0 | ${XARGS} -0 ${CHMOD} 755
-	@${ECHO_MSG} " [ DONE ]"
-
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Modified: head/www/tomcat85/pkg-plist
==============================================================================
--- head/www/tomcat85/pkg-plist	Sat Jan 27 20:14:28 2018	(r460150)
+++ head/www/tomcat85/pkg-plist	Sun Jan 28 00:47:05 2018	(r460151)
@@ -17,22 +17,6 @@
 %%T%%/bin/tomcat-native.tar.gz
 %%T%%/bin/tool-wrapper.sh
 %%T%%/bin/version.sh
-@owner %%WWWOWN%%
-@group %%WWWGRP%%
-@sample %%T%%/conf/catalina.policy.sample
-@sample %%T%%/conf/catalina.properties.sample
-@sample %%T%%/conf/context.xml.sample
-@sample %%T%%/conf/jaspic-providers.xml.sample
-@sample %%T%%/conf/jaspic-providers.xsd.sample
-@sample %%T%%/conf/logging.properties.sample
-@sample %%T%%/conf/server.xml.sample
-@sample %%T%%/conf/tomcat-users.xml.sample
-@sample %%T%%/conf/tomcat-users.xsd.sample
-@sample %%T%%/conf/web.xml.sample
-@dir %%T%%/conf
-@owner
-@group
-@dir %%T%%/endorsed
 %%T%%/lib/annotations-api.jar
 %%T%%/lib/catalina-ant.jar
 %%T%%/lib/catalina-ha.jar
@@ -58,26 +42,26 @@
 %%T%%/lib/tomcat-util.jar
 %%T%%/lib/tomcat-websocket.jar
 %%T%%/lib/websocket-api.jar
+@dir %%T%%/endorsed
+@postunexec [ ! -d %D/%%T%% ] || echo If permanently deleting this package, %D/%%T%% must be removed manually
 @owner %%WWWOWN%%
 @group %%WWWGRP%%
+@dir %%T%%/conf
 @dir %%T%%/logs
-%%T%%/temp/safeToDelete.tmp
 @dir %%T%%/temp
-%%ROOT%%%%T%%/webapps/ROOT/RELEASE-NOTES.txt
-%%ROOT%%%%T%%/webapps/ROOT/WEB-INF/web.xml
-%%ROOT%%%%T%%/webapps/ROOT/asf-logo-wide.svg
-%%ROOT%%%%T%%/webapps/ROOT/bg-button.png
-%%ROOT%%%%T%%/webapps/ROOT/bg-middle.png
-%%ROOT%%%%T%%/webapps/ROOT/bg-nav-item.png
-%%ROOT%%%%T%%/webapps/ROOT/bg-nav.png
-%%ROOT%%%%T%%/webapps/ROOT/bg-upper.png
-%%ROOT%%%%T%%/webapps/ROOT/favicon.ico
-%%ROOT%%%%T%%/webapps/ROOT/index.jsp
-%%ROOT%%%%T%%/webapps/ROOT/tomcat-power.gif
-%%ROOT%%%%T%%/webapps/ROOT/tomcat.css
-%%ROOT%%%%T%%/webapps/ROOT/tomcat.gif
-%%ROOT%%%%T%%/webapps/ROOT/tomcat.png
-%%ROOT%%%%T%%/webapps/ROOT/tomcat.svg
+@dir %%T%%/webapps
+@dir %%T%%/work
+@sample %%T%%/conf/catalina.policy.sample
+@sample %%T%%/conf/catalina.properties.sample
+@sample %%T%%/conf/context.xml.sample
+@sample %%T%%/conf/jaspic-providers.xml.sample
+@sample %%T%%/conf/jaspic-providers.xsd.sample
+@sample %%T%%/conf/logging.properties.sample
+@sample %%T%%/conf/server.xml.sample
+@sample %%T%%/conf/tomcat-users.xml.sample
+@sample %%T%%/conf/tomcat-users.xsd.sample
+@sample %%T%%/conf/web.xml.sample
+%%T%%/temp/safeToDelete.tmp
 %%DOCS%%%%T%%/webapps/docs/BUILDING.txt
 %%DOCS%%%%T%%/webapps/docs/RELEASE-NOTES.txt
 %%DOCS%%%%T%%/webapps/docs/RUNNING.txt
@@ -639,8 +623,18 @@
 %%MANAGER%%%%T%%/webapps/manager/index.jsp
 %%MANAGER%%%%T%%/webapps/manager/status.xsd
 %%MANAGER%%%%T%%/webapps/manager/xform.xsl
-@dir %%T%%/webapps
-@dir %%T%%/work
-@owner
-@group
-@postunexec [ ! -d %D/%%T%% ] || echo If permanently deleting this package, %D/%%T%% must be removed manually
+%%ROOT%%%%T%%/webapps/ROOT/RELEASE-NOTES.txt
+%%ROOT%%%%T%%/webapps/ROOT/WEB-INF/web.xml
+%%ROOT%%%%T%%/webapps/ROOT/asf-logo-wide.svg
+%%ROOT%%%%T%%/webapps/ROOT/bg-button.png
+%%ROOT%%%%T%%/webapps/ROOT/bg-middle.png
+%%ROOT%%%%T%%/webapps/ROOT/bg-nav-item.png
+%%ROOT%%%%T%%/webapps/ROOT/bg-nav.png
+%%ROOT%%%%T%%/webapps/ROOT/bg-upper.png
+%%ROOT%%%%T%%/webapps/ROOT/favicon.ico
+%%ROOT%%%%T%%/webapps/ROOT/index.jsp
+%%ROOT%%%%T%%/webapps/ROOT/tomcat-power.gif
+%%ROOT%%%%T%%/webapps/ROOT/tomcat.css
+%%ROOT%%%%T%%/webapps/ROOT/tomcat.gif
+%%ROOT%%%%T%%/webapps/ROOT/tomcat.png
+%%ROOT%%%%T%%/webapps/ROOT/tomcat.svg



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201801280047.w0S0l5St031565>