Date: Wed, 22 Jan 1997 17:23:24 +1030 (CST) From: Michael Smith <msmith@atrad.adelaide.edu.au> To: davidn@unique.usn.blaze.net.au (David Nugent) Cc: msmith@atrad.adelaide.edu.au, hosokawa@mt.cs.keio.ac.jp, jkh@time.cdrom.com, keithl@wakko.gil.net, chat@freebsd.org, config@freebsd.org Subject: Re: Kernel configuration Message-ID: <199701220653.RAA14007@genesis.atrad.adelaide.edu.au> In-Reply-To: <Mutt.19970122150121.davidn@labs.blaze.net.au> from David Nugent at "Jan 22, 97 03:01:22 pm"
next in thread | previous in thread | raw e-mail | index | archive | help
David Nugent stands accused of saying: > Michael Smith writes: > > option "GPL_MATH_EMULATE" { > > description "Support for systems with no math coprocessor" > > description "(Improved but GPL-licensed version)" > > excludes {option MATH_EMULATE} > > header opt_math_emulate.h > > } > > > > I realise that we're arguing for syntaxes friendly to our chosen > > implementation languages here; I just feel that the SGML-like syntax > > is a lot harder to work with. > > Agreed. The above is pretty clear, less verbose and much easier on > the eyes. I quite like it. :) Thankyou 8) I've been using that style of syntax in our current software for about 18 months now (in case you were wondering whether I'm just making this up as I go along 8), and it's proven to be very useful. Just digressing on the Tcl side for a moment, you define : proc option {name attr} { global Options; lappend Options(list) $name; while {$attr != ""} { set token [lvarpop attr]; switch -- $token { description { lappend Options($name:description) [lvarpop attr]; } ... and then you can test for a description somewhere else : if {[info exists Options($name:description)]} { ... } > One other thing I would add is some form of option "grouping", though, You could group based on the file the options are defined in, or you could add a 'group' attribute, perhaps even with a heirachial syntax if you thought it was worth it. > and perhaps even a way of nesting options (which might even include > support for device-specific flags). Note the 'sio' example, which specifically implies (sic) this; the 'requires {device sio}' means that the option makes no sense without the 'sio' device configured (and thus would ideally not be visible at all). Likewise you could nest options using the 'requires' attribute. > Perhaps the standard metaconfig file could be in English, and > supplimental description files supplied for other languages. That actually sounds fairly reasonable. In situations where only english text was available, the tool could fall back on that as a default. (eg. I distribute a new driver with a .ki file but not a .kim (message translation) file) > David Nugent - Unique Computing Pty Ltd - Melbourne, Australia -- ]] Mike Smith, Software Engineer msmith@gsoft.com.au [[ ]] Genesis Software genesis@gsoft.com.au [[ ]] High-speed data acquisition and (GSM mobile) 0411-222-496 [[ ]] realtime instrument control. (ph) +61-8-8267-3493 [[ ]] Unix hardware collector. "Where are your PEZ?" The Tick [[
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199701220653.RAA14007>