Date: Fri, 29 Sep 2006 16:24:46 +0900 From: Hirohisa Yamaguchi <umq@ueo.co.jp> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/103800: [patch] www/apache22 multiple instantiation does not work in recent releases Message-ID: <868xk3b0e9.wl%umq@ueo.co.jp> Resent-Message-ID: <200609290730.k8T7UHjD052180@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 103800 >Category: ports >Synopsis: [patch] www/apache22 multiple instantiation does not work in recent releases >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Fri Sep 29 07:30:17 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Hirohisa Yamaguchi >Release: FreeBSD 7.0-CURRENT amd64 >Organization: <organization of PR author (multiple lines)> >Environment: System: FreeBSD calliope.****.org 7.0-CURRENT FreeBSD 7.0-CURRENT #2: Fri Sep 1 13:15:27 JST 2006 root@calliope.****.org:/usr/obj/usr/src/sys/CALLIOPE64 amd64 >Description: In recent releases, .sh suffix on rc start scripts are deleted. http://www.freebsd.org/cgi/cvsweb.cgi/ports/Mk/bsd.port.mk#rev1.510 In ``multiple instantiation'' feature, the rc script calls itself recursively, and a change in name of the script file might cause failure. >How-To-Repeat: 1. setting up www/apache22 to run multiple instance 2. $PREFIX/etc/rc.d/apache22 start >Fix: the patch follows: diff -Npru ports.orig/www/apache22/Makefile ports/www/apache22/Makefile --- ports.orig/www/apache22/Makefile Mon Sep 25 01:16:39 2006 +++ ports/www/apache22/Makefile Fri Sep 29 15:46:34 2006 @@ -126,6 +126,13 @@ CONFIGURE_ARGS+= --with-ldap \ .include "${APACHEDIR}/Makefile.modules" .include <bsd.port.pre.mk> +# .sh suffix is stripped in recent releases. +.if (${OSVERSION} >= 700007 || ( ${OSVERSION} < 700000 && ${OSVERSION} >= 600101 )) +SUB_LIST= "RC_SCRIPT=${PREFIX}/etc/rc.d/${USE_RC_SUBR:S/.sh$//}" +.else +SUB_LIST= "RC_SCRIPT=${PREFIX}/etc/rc.d/${USE_RC_SUBR}" +.endif + .if defined(WITH_APR_FROM_PORTS) PLIST_SUB+= APR_PORTS="@comment " LIB_DEPENDS+= apr-1:${PORTSDIR}/devel/apr diff -Npru ports.orig/www/apache22/files/apache22.sh.in ports/www/apache22/files/apache22.sh.in --- ports.orig/www/apache22/files/apache22.sh.in Mon Sep 25 01:16:40 2006 +++ ports/www/apache22/files/apache22.sh.in Fri Sep 29 15:43:48 2006 @@ -92,7 +92,7 @@ else if [ "x$1" != "xrestart" ]; then for profile in ${apache22_profiles}; do echo "===> apache22 profile: ${profile}" - %%PREFIX%%/etc/rc.d/apache22.sh $1 ${profile} + %%RC_SCRIPT%% $1 ${profile} retcode="$?" if [ "0${retcode}" -ne 0 ]; then failed="${profile} (${retcode}) ${failed:-}" >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?868xk3b0e9.wl%umq>