[Ns-developers] Proposed examples directory hierarchy
tomh at tomh.org
Mon Oct 5 21:59:41 PDT 2009
craigdo at ee.washington.edu wrote:
> [ ... ]
>> 1. Bug 612 nor P1 All ns-bugs at isi.edu NEW example scripts
>> This bug is really about organization of the examples directory.
>> Unless I hear any objections I will try and wire in some
>> subdirectories using waf and see what happens. If all goes
>> smoothly I will propose the directory hierarchy tomorrow and
>> we can close this bug fairly easily.
> Nothing came up, so below is what I did with the subdirectories. If I don't
> hear an objection, I'll just push these changes tonight along with the four
> new wifi examples mentioned in the bug.
I might suggest to wait a day for comments to come in.
> To address the problem of it being very time consuming to build all of the
> examples, I added a blunt instrument. You now have two configuration
> ./waf configure --disable-examples
> ./waf configure --enable-examples
> If you --disable-examples none of the examples are built, none of the
> examples are tested in test.py, and regression testing won't run (since it
> depends on the examples).
How about, instead of a configure time option, a build option that does
not try to link examples? Building the examples is not the typical
recurring delay, it is linking them.
It seems that "./waf" and "./waf build" are functionally the same now--
could we, for instance, make "./waf build" not try to link all examples?
It would then be nice if there were an easy test.py option that avoided
examples, including their linking, such as "test.py -i" (e.g. for
internal, or pick your favorite option argument) that was equivalent to
"test.py -c unit -c bvt -c system". So, for instance, this would
support a workflow such as "edit file in src/, ./waf build, ./test.py
-i" (or even have test.py figure out what needs to be built) that avoids
linking and testing examples at each development step.
We had similar behavior for a brief time with "./waf --check" but that
now appears to be disabled.
More information about the Ns-developers