Waf branch - Configuration [4/6]

Amar Takhar amar at rtems.org
Fri Feb 6 07:04:06 UTC 2015


Onto the BSP configuration.  Each one is a class with a very simple method of 
defining the features it supports.

See rtems_waf/defaults/bsp/sparc.py

The 'Base' class defines options for that architecture.  Multiple inheritance is 
supported see erc32.

These classes are only meant to define the defaults for a BSP.  Every user can 
change any option they want.  There are no 'hidden' options they're all put into 
config.cfg with *full* documentation on what it does.

There are two 'sections' to each config.  build() defines only modify when RTEMS 
is built eg enabling or disabling a feature or modifying how the build works.

header() is config.h or bsp header files.  You can do a find build -name "*.h" 
to see the various autogenerated files.

GCC spec files are autogenerated and no longer exist in source.  This is 
necessary in order to support more than one compiler as these options need to be 
translated.

By defining requirements via RTEMS Config it lets us use any compiler or tool we 
want trivially.  RTEMS Config removes lock-in.  It holds information and 
disburses it as we see fit.  Whether that is a compiler, GUI, documentation or 
the build system.  This also lets us have binary distributions that ships all 
BSPS.  We can also ship bsp+tests as separate packages which allows users to 
get started w/out building RTEMS immediately on all platforms.

Waf works on all operating systems the only requirement is stock Python.
Users can also use MSVC as their IDE if they chose -- it will work fine we 
can even add integration by creating a plugin that pulls in the RTEMS Config 
information.


Caveats:

 - This is a preview only.  It works but there are issues.
 - Joel/Chris have already stated that BSPs need to be 'encapsulated'.  This 
   means the config and all source need to be in a separate dir to allow for 
   private BSPs.  This will be supported after the source move.
 - This is usable once we decide to go forward.  It is something I have worked 
   on over the last 4 years.  While there are issues there is nothing I cannot 
   fix in the python code.  What needs help is the source definitions from 
   auto*->waf.

I also had to make a lot of 'temp' hacks to the build due to the changes in the 
last year.  My commit messages aren't detailed for the 'waf' branch.  The 'fix' 
and 'include' branches have useful messages.


More emails to follow (5/6)


Amar.


More information about the devel mailing list