Glenn Fowler wrote:
[snip]
> > If that justification isn't enougth I'd like to follow
> > http://mail.opensolaris.org/pipermail/ksh93-integration-discuss/2007-January/002001.html
> > which AFAIK allows us to ship any of our code as CPL1.0 on demand and
> > would therefore avoid the need to add a CDDL license template into that
> > code (e.g. I am not happy with the idea to put a giant CDDL thing into
> > David&&Glenn's code for that tiny #ifdef/#include/etc.-hack...).
>
> > AFAIK that's all... :-)
>
> what is soalrish about
> #if SHOPT_CMDLIB_SOLARIS_BLTINS
> #include "solaris_cmdlist.h"
The Solaris part is hidden in "solaris_cmdlist.h" which defines the list
of builtins as specified in PSARC 2006/550.
> maybe its really xopenish and we (upstream) can just put in an
> equivalent change using the appropriate xopen guard macros/names
I thought a little bit about the issue last night - in theory the
following would work:
-- snip --
Index: src/lib/libshell/common/data/builtins.c
===================================================================
--- src/lib/libshell/common/data/builtins.c (revision 515)
+++ src/lib/libshell/common/data/builtins.c (working copy)
@@ -120,7 +120,9 @@
"wait", NV_BLTIN|BLT_ENV|BLT_EXIT, bltin(wait),
"type", NV_BLTIN|BLT_ENV, bltin(whence),
"whence", NV_BLTIN|BLT_ENV, bltin(whence),
-#if SHOPT_CMDLIB_BLTIN
+#if SHOPT_CMDLIB_VENDOR_BLTINSLIST
+#include SHOPT_CMDLIB_VENDOR_BLTINSLIST
+#elif SHOPT_CMDLIB_BLTIN
#define Q(f) #f /* libpp cpp workaround -- fixed
2005-04-11 */
#define CMDLIST(f) BDIR Q(f), NV_BLTIN|NV_NOFREE, bltin(f),
#include <cmdlist.h>
-- snip --
... this would introduce the symbol |SHOPT_CMDLIB_VENDOR_BLTINSLIST|
which points to a vendor/platform-specific include file (like
"solaris_cmdlist.h") where vendors can list their own set of builtins.
The advantage would be that we could get rid of the whole patch and the
matching *.diff file (and the related bickering about having diffs in
the OS/Net tree (for now =:-) )) ... but the disadvantage is that it may
give other vendors "ideas" that this is something which they can tune
randomly to match their flavour (at least I would add a comment like /*
If you change this make sure the test suite still works (otherwise
you'll be fed to komodo dragons... ALIVE! FEET FIRST (that you can watch
the process)!). */) ...
----
Bye,
Roland
--
__ . . __
(o.\ \/ /.o) roland.mainz at nrubsig.org
\__\/\/__/ MPEG specialist, C&&JAVA&&Sun&&Unix programmer
/O /==\ O\ TEL +49 641 7950090
(;O/ \/ \O;)