diff options
author | Alex Dupre <ale@FreeBSD.org> | 2010-03-01 15:36:47 +0000 |
---|---|---|
committer | Alex Dupre <ale@FreeBSD.org> | 2010-03-01 15:36:47 +0000 |
commit | d0015165ef8d01e3ff6ffb4447fa68872d6ad382 (patch) | |
tree | c9628c15d2ee611842c77a2a48142c554ee7d54e /www/tomcat6 | |
parent | Add rzsh to /etc/shells (this was handled correctly by pkg-plist when (diff) |
- Update to 6.0.24 release [1]
- Fix rc.d stop script [2]
PR: ports/144274 [1], ports/140015 [2]
Submitted by: wen [1], Christer Solskogen <christer.solskogen@gmail.com> [2]
Feature safe: yes
Notes
Notes:
svn path=/head/; revision=250460
Diffstat (limited to 'www/tomcat6')
-rw-r--r-- | www/tomcat6/Makefile | 3 | ||||
-rw-r--r-- | www/tomcat6/distinfo | 6 | ||||
-rw-r--r-- | www/tomcat6/files/tomcat6.sh.in | 34 |
3 files changed, 30 insertions, 13 deletions
diff --git a/www/tomcat6/Makefile b/www/tomcat6/Makefile index b4454658f4e6..8f96f98825b5 100644 --- a/www/tomcat6/Makefile +++ b/www/tomcat6/Makefile @@ -6,8 +6,7 @@ # PORTNAME= tomcat -PORTVERSION= 6.0.20 -PORTREVISION= 1 +PORTVERSION= 6.0.24 CATEGORIES= www java MASTER_SITES= ${MASTER_SITE_APACHE} MASTER_SITE_SUBDIR= tomcat/tomcat-6/v${PORTVERSION}/bin diff --git a/www/tomcat6/distinfo b/www/tomcat6/distinfo index 313dc61dc622..9e06e41cf8ce 100644 --- a/www/tomcat6/distinfo +++ b/www/tomcat6/distinfo @@ -1,3 +1,3 @@ -MD5 (apache-tomcat-6.0.20.tar.gz) = 5944999abe79d01dc2ee7776d9d57873 -SHA256 (apache-tomcat-6.0.20.tar.gz) = a443c1720dc25d0963dd47b299b4c5e81d51462147c351f18e5c59bf7646046e -SIZE (apache-tomcat-6.0.20.tar.gz) = 5998298 +MD5 (apache-tomcat-6.0.24.tar.gz) = de8bec8e4eb87f00d588339f49ba7e83 +SHA256 (apache-tomcat-6.0.24.tar.gz) = 02a5efe773cc2d79e025f96e3aeb747f46d1dd262d0d9b848b84e60d319e6ff6 +SIZE (apache-tomcat-6.0.24.tar.gz) = 6104116 diff --git a/www/tomcat6/files/tomcat6.sh.in b/www/tomcat6/files/tomcat6.sh.in index dc5670fb91be..f5cd4b61d675 100644 --- a/www/tomcat6/files/tomcat6.sh.in +++ b/www/tomcat6/files/tomcat6.sh.in @@ -74,7 +74,6 @@ tomcat%%TOMCAT_VERSION%%_stop_timeout="${tomcat%%TOMCAT_VERSION%%_stop_timeout:- name="tomcat%%TOMCAT_VERSION%%" rcvar=`set_rcvar` pidfile="/var/run/%%APP_SHORTNAME%%.pid" -procname="java" load_rc_config "${name}" @@ -94,6 +93,7 @@ if [ -n "${tomcat%%TOMCAT_VERSION%%_java_os}" ] ; then export JAVA_OS="${tomcat%%TOMCAT_VERSION%%_java_os}" fi +java_class="org.apache.catalina.startup.Bootstrap" java_command="%%LOCALBASE%%/bin/java \ ${tomcat%%TOMCAT_VERSION%%_java_opts} \ -Djava.endorsed.dirs=%%TOMCAT_HOME%%/endorsed \ @@ -101,7 +101,7 @@ java_command="%%LOCALBASE%%/bin/java \ -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_class}" log_args=">> ${tomcat%%TOMCAT_VERSION%%_stdout_log} \ 2>> ${tomcat%%TOMCAT_VERSION%%_stderr_log} " @@ -111,17 +111,16 @@ 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}" -start_precmd=pid_touch -stop_cmd="tomcat%%TOMCAT_VERSION%%_stop" +start_precmd="pid_touch" +stop_cmd="tomcat_stop" -pid_touch () -{ +pid_touch() { touch $pidfile chown $tomcat%%TOMCAT_VERSION%%_user $pidfile } -tomcat%%TOMCAT_VERSION%%_stop() { - rc_pid=$(check_pidfile $pidfile $procname) +tomcat_stop() { + rc_pid=$(tomcat_check_pidfile $pidfile) if [ -z "$rc_pid" ]; then [ -n "$rc_fast" ] && return 0 @@ -140,6 +139,25 @@ tomcat%%TOMCAT_VERSION%%_stop() { rm -f ${pidfile} } +tomcat_check_pidfile() { + _pidfile=$1 + if [ -z "$_pidfile" -o -z "$_procname" ]; then + err 3 'USAGE: check_pidfile pidfile procname [interpreter]' + fi + if [ ! -f $_pidfile ]; then + debug "pid file ($_pidfile): not readable." + return + fi + read _pid _junk < $_pidfile + if [ -z "$_pid" ]; then + debug "pid file ($_pidfile): no pid in file." + return + fi + if [ -n "`%%LOCALBASE%%/bin/jps -l | grep -e "^$_pid $java_class\$"`" ]; then + echo -n $_pid + fi +} + tomcat_wait_max_for_pid() { _timeout=$1 shift |