cvs commit: src/usr.sbin/config configvers.h

Peter Wemm peter at wemm.org
Fri Nov 4 16:33:56 PST 2005


On Friday 04 November 2005 01:34 am, Ceri Davies wrote:
> On Fri, Nov 04, 2005 at 09:18:58AM +0200, Ruslan Ermilov wrote:
> > On Fri, Nov 04, 2005 at 04:16:44AM +0000, Warner Losh wrote:
> > > imp         2005-11-04 04:16:44 UTC
> > >
> > >   FreeBSD src repository
> > >
> > >   Modified files:
> > >     usr.sbin/config      configvers.h
> > >   Log:
> > >   since nocpu isn't used in the kernel config base, we don't need
> > > to bump the version.  Peter Wemm, John Baldwin and I hammered
> > > this out after the last time I needlessly incremented the
> > > version.
> > >
> > >   Revision  Changes    Path
> > >   1.38      +1 -1      src/usr.sbin/config/configvers.h
> >
> > Our users wanted to *use* the "nocpu" directive in their configs
> > that are based on GENERIC (GENERIC is included), hence I bumped
> > config(8).  Otherwise, one day some would scream that "nocpu"
> > doesn't work for them, because they're using the older version
> > of config(8).
>
> I'd agree that the Makefiles don't need to be bumped, as they don't
> actually require the new config, but config has new functionality and
> the version should probably be bumped in the binary.

The reason for configvers in the first place was that config(8) didn't 
fail for many error conditions at all.  It would create a bogus kernel 
build environment even though a parser change caused hundreds of syntax 
errors.

This was a real problem because 'make buildkernel' had become all the 
'in' thing to do, and people were getting hosed because 
buildkernel/installkernel would quite happily install a bogus kernel 
after generating hundreds of lines of error messages.  The victim would 
be none the wiser because the config output would be lost in the noise 
of the make output.  config was originally written to be used 
interactively and the results read, not run from a make script.

Over time, config was fixed to correctly return error codes for parser 
problems, and the syntax evolved so that errors were more likely to be 
detected.

These days we generally don't need to bump configvers because syntax 
changes are correctly detected.  configvers should only be bumped if 
they are NOT detected, or if the interface between /sys/conf/* 
and /usr/sbin/config has changed.

Adding 'nocpu' does not require a configvers bump.  An older config(8) 
will correctly fail with a syntax error if it is exposed to a newer 
'nocpu' keyword.

Needlessly bumping configvers is harmful because it disrupts users and 
developers.  config should NOT be made to fail just because it is out 
of sync with 'nocpu' support whennocpu isn't used.  That would be just 
silly.
-- 
Peter Wemm - peter at wemm.org; peter at FreeBSD.org; peter at yahoo-inc.com
"All of this is for nothing if we don't go to the stars" - JMS/B5


More information about the cvs-all mailing list