Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 14 Jun 2001 10:49:11 +0300
From:      Danny Braniss <danny@cs.huji.ac.il>
To:        Peter Pentchev <roam@orbitel.bg>
Cc:        Warner Losh <imp@harmony.village.org>, Sheldon Hearn <sheldonh@starjuice.net>, freebsd-hackers@FreeBSD.ORG
Subject:   rc, was: Re: Plan to import NetBSD rc system 
Message-ID:  <E15ARsN-00062o-00@sexta.cs.huji.ac.il>
In-Reply-To: Message from Peter Pentchev <roam@orbitel.bg>  of "Wed, 13 Jun 2001 12:15:25 %2B0300." <20010613121525.D22123@ringworld.oblivion.bg> 

next in thread | previous in thread | raw e-mail | index | archive | help

> I've asked -ports before whether it is suitable to let ports startup scripts
> honor /etc/rc.conf{,.local} settings by sourcing /etc/defaults/rc.conf and
> then running a source_rc_confs (or whatever is appropriate).

my suggestion:

this is the 'modified' loop for the ${local_startup} in /etc/rc:

case ${local_startup} in
[Nn][Oo] | '')
	;;
*)
	echo -n 'Local package initialization:'
	for dir in ${local_startup}; do
		if [ -d "${dir}" ]; then
			for script in ${dir}/*.sh; do
				s=`basename ${script} .sh` 
				v=`eval echo '$'${s}_enable|dd conv=ucase`
				if [ -x "${script}" -a ${v} = YES ]; then
					(set -T
					 trap 'exit 1' 2
					 ${script} start)
				fi
			done
		fi
	done
	echo '.'
	;;
esac

you just add: mysql_enable="YeS"

danny



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E15ARsN-00062o-00>