Date: Thu, 8 Sep 2011 21:20:03 GMT From: Phil Phillips <pphillips@experts-exchange.com> To: freebsd-ports-bugs@FreeBSD.org Subject: Re: ports/160571: [PATCH] www/tomcat55: allow for separate java start arguments in rc script Message-ID: <201109082120.p88LK2mH042002@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/160571; it has been noted by GNATS. From: Phil Phillips <pphillips@experts-exchange.com> To: bug-followup@FreeBSD.org, pphillips@experts-exchange.com Cc: Subject: Re: ports/160571: [PATCH] www/tomcat55: allow for separate java start arguments in rc script Date: Thu, 08 Sep 2011 14:17:36 -0700 This is a multi-part message in MIME format. --------------000505050007090204080804 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Updating patch to include %%TOMCAT_VERSION%% where needed. --------------000505050007090204080804 Content-Type: text/plain; name="tomcat55.patch.txt" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="tomcat55.patch.txt" --- Makefile.orig 2011-08-10 17:06:33.000000000 -0700 +++ Makefile 2011-09-08 13:31:24.000000000 -0700 @@ -7,7 +7,7 @@ PORTNAME= tomcat PORTVERSION= 5.5.33 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= www java MASTER_SITES= ${MASTER_SITE_APACHE} MASTER_SITE_SUBDIR= tomcat/tomcat-5/v${PORTVERSION}/bin --- files/tomcat55.sh.in.orig 2011-07-19 15:45:27.000000000 -0700 +++ files/tomcat55.sh.in 2011-09-08 13:31:00.000000000 -0700 @@ -58,6 +58,10 @@ # Set to "" by default. # Java VM args to use. # +# tomcat%%TOMCAT_VERSION%%_java_start_opts (str): +# Set to "" by default. +# Additional Java VM args to use when starting tomcat. +# tomcat%%TOMCAT_VERSION%%_enable="${tomcat%%TOMCAT_VERSION%%_enable:-"NO"}" tomcat%%TOMCAT_VERSION%%_java_version="${tomcat%%TOMCAT_VERSION%%_java_version:-"%%JAVA_VERSION%%"}" @@ -93,15 +97,22 @@ export JAVA_OS="${tomcat%%TOMCAT_VERSION%%_java_os}" fi -java_command="%%LOCALBASE%%/bin/java \ - ${tomcat%%TOMCAT_VERSION%%_java_opts} \ - -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS \ +java_args="-Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS \ -classpath %%TOMCAT_HOME%%/%%JAR_FILE%%:%%TOMCAT_HOME%%/bin/commons-logging-api.jar:${tomcat%%TOMCAT_VERSION%%_classpath} \ -Dcatalina.base=${tomcat%%TOMCAT_VERSION%%_catalina_base} \ -Dcatalina.home=${tomcat%%TOMCAT_VERSION%%_catalina_home} \ -Djava.io.tmpdir=${tomcat%%TOMCAT_VERSION%%_catalina_tmpdir} \ org.apache.catalina.startup.Bootstrap" +java_start_command="%%LOCALBASE%%/bin/java \ + ${tomcat%%TOMCAT_VERSION%%_java_opts} \ + ${tomcat%%TOMCAT_VERSION%%_java_start_opts} \ + ${java_args}" + +java_stop_command="%%LOCALBASE%%/bin/java \ + ${tomcat%%TOMCAT_VERSION%%_java_opts} \ + ${java_args}" + log_args="%%LOG_ARGS%%" # Subvert the check_pid_file procname check. @@ -118,7 +129,7 @@ required_files="${tomcat%%TOMCAT_VERSION%%_catalina_home}/conf/server.xml" command="/usr/sbin/daemon" -flags="-p ${pidfile} ${java_command} start ${tomcat%%TOMCAT_VERSION%%_flags} ${log_args}" +flags="-p ${pidfile} ${java_start_command} start ${tomcat%%TOMCAT_VERSION%%_flags} ${log_args}" start_precmd=pid_touch stop_cmd="tomcat%%TOMCAT_VERSION%%_stop" @@ -137,7 +148,7 @@ fi echo "Stopping ${name}." - ${java_command} stop + ${java_stop_command} stop tomcat_wait_max_for_pid ${tomcat%%TOMCAT_VERSION%%_stop_timeout} `cat $pidfile` kill -KILL `cat $pidfile` 2> /dev/null && echo "Killed." rm -f ${pidfile} --------------000505050007090204080804--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201109082120.p88LK2mH042002>