Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Nov 2005 12:29:47 +0000 (GMT)
From:      Robert Watson <rwatson@FreeBSD.org>
To:        Rob <spamrefuse@yahoo.com>
Cc:        freebsd-stable@freebsd.org, Kris Kennaway <kris@obsecurity.org>
Subject:   Re: GENERIC and DEFAULTS
Message-ID:  <20051102122547.Y45155@fledge.watson.org>
In-Reply-To: <20051102103619.40726.qmail@web36201.mail.mud.yahoo.com>
References:  <20051102103619.40726.qmail@web36201.mail.mud.yahoo.com>

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

On Wed, 2 Nov 2005, Rob wrote:

> Kris Kennaway wrote:
>>
>> You missed the part where I said that the error is commonly reported by 
>> people who have chosen not to build modules.
>
> The DEFAULTS construction is put in place to help 'novices' not to do 
> stupid things (as removing io/mem).
>
> However, does 'building a kernel without modules' qualify as a novice 
> action? I wonder. I think if you know how to do that, you've quite 
> progressed in the world of kernel building!

My hope is that, increasingly, FreeBSD users will create kernel 
configuration files using the "include" directive to specify a set of 
changes relative to GENERIC.  That will also help lower the rate of foot 
shooting involving kernel components becoming optional.  Most of my kernel 
configuration files now look something like this:

   include GENERIC
   ident FLEDGE

   makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols

   options COMPAT_AOUT
   options KDB
   options DDB
   options BREAK_TO_DEBUGGER
   options ALT_BREAK_TO_DEBUGGER

   options IPFIREWALL
   options DUMMYNET
   options IPDIVERT

   options INVARIANTS
   options INVARIANT_SUPPORT

   nooptions WITNESS
   nooptions WITNESS_SKIP_SPIN

Whereby I rely on GENERIC to provide the defaults for the configuration, 
and then tweak to add/remove particular options or devices.  I've found 
this to be a more reliable way to track changing branches, as I don't have 
to notice when the details of GENERIC (and now DEFAULTS) changes: I get 
new device drivers when they are added, and unless I take specific action, 
things don't disappear out from under me when they become optional, which 
was the problem most people had with device mem and device io.  They would 
upgrade their source tree, but not resync their configuration file to the 
latest tweaks in GENERIC.  This was not an error, of course, since options 
are there so they can be optional, but it did result in hard to debug 
problems.

Robert N M Watson



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051102122547.Y45155>