Re: [kbuild-devel] Re: Cross-referencing frenzy

Rogier Wolff
2001-04-19T15:22:32Z

Eric S. Raymond wrote:
> Rogier Wolff <R.E.Wolff@BitWizard.nl>:
> > I think it should be possible to do:
> >
> > /* to enable the special stuff, change the "undef" to "define",
> > If you really want you can add this to Config.in so that you're presented
> > with this choice when configuring your kernel. But it's not neccesary
> > for the general public to always see this toggle. */
> > #undef CONFIG_SX_SPECIALSTUFF
> >
> > #ifdef CONFIG_SX_SPECIALSTUFF
> > ...
> >
> > #endif
>
> Yes, I could write and test code to handle this in about twenty minutes.
> And I was about to do it when I realized that it would be the wrong thing.
>
> The right answer is that CONFIG_SX_SPECIALSTUFF *should* be flagged as
> an error -- because it doesn't belong in the CONFIG_ namespace, which
> by definition should be reserved for things the configurators control.
>
> It should be called something else: perhaps ENABLE_SX_SPECIALSTUFF

You surely can do

#undef ENABLE_SX_SPECIALSTUFF

however, then the "upgrade path" to a configurable parameter in the
configuration stuff is harder.

Now, as far as I know, this is rarely (if ever) used right now. (but
I've been tempted to do it in the past) Maybe with better
configuration tools, always declaring it a configuration option is a
good idea.

Think about it. Consider the issue, decide whatever you want. Tell me
about it. (i.e. what you suggest is the best way to deal with this.) (*)

Roger.

(*) you may say: "But I just did that". However the above hints at
that you skipped over the "but I'd like to prepare for the case where
the configuration of that parameter should be made easier by including
it in the config mechanism."

--
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2137555 **
*-- BitWizard writes Linux device drivers for any device you may have! --*
* There are old pilots, and there are bold pilots.
* There are also old, bald pilots.