Date: Fri, 10 Dec 2004 22:17:13 +0800 From: "Kang Liu" <liukang@bjut.edu.cn> To: <freebsd-gnats-submit@FreeBSD.org>, <andy@gerweck.dyndns.org>, <freebsd-java@freebsd.org>, "'Herve Quiroz'" <hq@FreeBSD.org>, "'Brent Verner'" <brent@rcfile.org> Subject: Re: ports/43565: jakarta-tomcat41 port breaks upgrades Message-ID: <302687348.20823@bjut.edu.cn>
next in thread | raw e-mail | index | archive | help
FYI, here is the patch for www/jakarta-tomcat41, mainly based on the patch provided by Brent Verner, any suggestion is welcome. Kang Index: Makefile =================================================================== RCS file: /home/ncvs/ports/www/jakarta-tomcat41/Makefile,v retrieving revision 1.58 diff -u -r1.58 Makefile --- Makefile 6 Dec 2004 02:35:40 -0000 1.58 +++ Makefile 10 Dec 2004 14:01:48 -0000 @@ -7,6 +7,7 @@ PORTNAME= jakarta-tomcat PORTVERSION= 4.1.31 +PORTREVISION= 1 CATEGORIES= www java MASTER_SITES= ${MASTER_SITE_APACHE_JAKARTA} MASTER_SITE_SUBDIR= tomcat-4/v${PORTVERSION}/bin @@ -52,6 +53,8 @@ ${WRKSRC}/conf/server.xml JAR_FILE= bin/bootstrap.jar WRKDIR?= ${WRKDIRPREFIX}${.CURDIR}/work +CONF_EXT= sample +PLIST_SUB+= CONF_EXT=${CONF_EXT} .include <bsd.port.pre.mk> @@ -116,9 +119,19 @@ @${MKDIR} ${LOG_DIR} @${ECHO_CMD} " [ DONE ]" - @${ECHO_CMD} -n ">> Copying files to destination directory..." + @${ECHO_CMD} ">> Copying files to destination directory..." + @${CP} ${WRKDIR}/server.xml ${WRKSRC}/conf/ + @(cd ${WRKSRC};${FIND} conf -type f | ${SED} -e '/${CONF_EXT}/d') \ + | while read a; do \ + ${MV} ${WRKSRC}/$$a ${WRKSRC}/$$a.${CONF_EXT}; \ + if [ ! -e "${APP_HOME}/$$a" ]; then \ + ${ECHO_CMD} " Installing local configuration file: ${APP_HOME}/$$a"; \ + ${CP} ${WRKSRC}/$$a.${CONF_EXT} ${WRKSRC}/$$a; \ + else \ + ${ECHO_CMD} " Preserving local configuration file: ${APP_HOME}/$$a"; \ + fi; \ + done @${CP} -R ${WRKSRC}/* ${APP_HOME} - @${CP} ${WRKDIR}/server.xml ${APP_HOME}/conf/ @${ECHO_CMD} " [ DONE ]" @${ECHO_CMD} -n ">> Compiling and installing control program..." Index: pkg-plist =================================================================== RCS file: /home/ncvs/ports/www/jakarta-tomcat41/pkg-plist,v retrieving revision 1.23 diff -u -r1.23 pkg-plist --- pkg-plist 6 Dec 2004 02:35:40 -0000 1.23 +++ pkg-plist 10 Dec 2004 13:57:11 -0000 @@ -44,12 +44,12 @@ %%T%%/common/lib/naming-resources.jar %%T%%/common/lib/servlet.jar %%T%%/common/lib/tools.jar -%%T%%/conf/catalina.policy -%%T%%/conf/jk2.properties -%%T%%/conf/server-noexamples.xml.config -%%T%%/conf/server.xml -%%T%%/conf/tomcat-users.xml -%%T%%/conf/web.xml +%%T%%/conf/catalina.policy.%%CONF_EXT%% +%%T%%/conf/jk2.properties.%%CONF_EXT%% +%%T%%/conf/server-noexamples.xml.config.%%CONF_EXT%% +%%T%%/conf/server.xml.%%CONF_EXT%% +%%T%%/conf/tomcat-users.xml.%%CONF_EXT%% +%%T%%/conf/web.xml.%%CONF_EXT%% %%T%%/logs/stderr.log %%T%%/logs/stdout.log %%T%%/server/lib/catalina-ant.jar
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?302687348.20823>