Subject: Re: /usr/pkg/etc/rc.d/*
To: NetBSD-current Discussion List <current-users@netbsd.org>
From: Michael G. Schabert <mikeride@mac.com>
List: current-users
Date: 03/13/2003 23:23:57
At 3:22 PM -0500 3/9/03, Greg A. Woods wrote:
>[ On Sunday, March 9, 2003 at 20:24:50 (+0100), Tom Ivar Helbekkmo wrote: ]
>>  Subject: Re: /usr/pkg/etc/rc.d/*
>>
>>  "Greg A. Woods" <woods@weird.com> writes:
>>
>>  > How can you logically assume that something which needs configuration
>>  > can "just work" when you install it in your particular environment?
>>
>>  I don't think anyone is assuming that.  What's being assumed is that
>>  you can install a software package from pkg_src, configure it, and add
>>  "mumble=YES" to /etc/rc.conf -- and expect it to start at the next
>>  reboot.
>
>Anyone making such an assumption apparently hasn't read the text that's
>displayed when such a package is installed!  ;-)

Oh, really??

alpha# more MESSAGE
===========================================================================
$NetBSD: MESSAGE,v 1.3 2002/08/29 11:16:14 abs Exp $

To have Netatalk start automatically at boot, you will need to set the
following variables in /etc/rc.conf (replacing "YES" with "NO" for those
services you wish to not run):
                 atalkd=YES
                 afpd=YES
                 papd=YES
                 timelord=YES

Example Netatalk config files have been installed in the examples directory
at ${PREFIX}/share/examples/netatalk. Production config files are
installed in ${PKG_SYSCONFDIR}. If no config files existed before this
package was installed, default config files were copied in.

===========================================================================

Care to say that again? ;-)

The "solution" to copy /usr/pkg/etc/rc.d/* to /etc/rc.d/ (whether by 
PKG_RCD_SCRIPTS or otherwise) is a  pretty absurd hack on an 
otherwise-elegant interface. /usr/pkg/etc is a fully-functional "etc" 
as far as every other function. Packages should not be invading any 
space other than /usr/pkg and /usr/X11R6/* (save for notable 
exceptions like static shells).

When NetBSD made the decision to create /usr/pkg/*, and have it be a 
functional mirror of / as far as "hier" goes, the cleanest and 
"right" answer would be to support (1) adding foo=YES for packages to 
/etc/rc.conf out of the box or (2) create a /usr/pkg/etc/rc.conf that 
is the functional equivalent to /etc/rc.conf. This would give a 
unified interface to everything.

But of course, I'm just one guy with no affiliation to TNF, so I 
speak for no-one but myself.

Mike
-- 
Bikers don't *DO* taglines.