This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: CDL configuration question


On Thu, 2001-12-06 at 04:18, surya prakash wrote:
> Hi all,
> 
> I have a doubt regarding the CDL configuration options.
> The background is this. We are trying to port Redboot to MC68360 (QUICC)
> 
> Based board. I am planning to use  the already available MBX board's
> port ( PowerPC-MPC860) for ease of porting.
> 
> Basically I want to use the HAL header files generated using the  ecos
> config tool for powerpc mbx target and later changing them according to
> my target specifications. I will compile and link the files using my own
> 
> make file.  Will this generate the correct bin for my target ??
> 
> I was thinking that .cdl files are used only for generating some
> #defines in the header files and these header files are used later for
> compiling source files.   Are the .cdl files are used directly during
> compilation also ??  What is ecos.ecc file ?? Is this file used by the
> ecos config tool while
> compiling and linking the source files or only while generating header
> files ??  Can I edit this file suitably for my target and build the
> sources ??
> 
> or ecos.ecc is used for compilaton/linking ??
> 

The CDL files are used to create configuration information, in the form
of the various ".h" files in <pkgconf/XXX.h>  This step happens when you
run 'ecosconfig tree' (or it's equivalent in the ConfigTool).

The 'ecos.ecc' file is actually a database (CDL description) which 
totally describes the current configuration.  It is only used by the CDL
tools (ecosconfig, ConfigTool)

The best (i.e. most proper) way for you to create a new configuration 
would be to clone an existing one, starting with the CDL files.  For 
your system, the 'mbx' is probably a reasonable starting point.  Here 
are the steps I follow when making a new configuration like this:
  * Duplicate the HAL hierarchy.
      This [typically] involves some renaming of files, e.g.
          hal/powerpc/mbx/currnet/cdl/hal_powerpc_mbx.cdl 
      becomes
          hal/powerpc/mbx/currnet/cdl/hal_powerpc_XYZ.cdl
      whatever XYZ is.  Note that this should be the name of your
      platform, not necessarily x68360, etc.
  * Modify platform specific details (in the same HAL hierarchy)
  * Add CDL records to the master database, ecos.db

A good example to see how this was done would be to compare two 
platforms which are very similar.  On the PowerPC, look at 'mbx'
and 'viper'.

The worst thing to do would be to try and simply modify an existing
platform in place, with #ifdefs, etc.  This would make the code very
hard to manage and/or keep up to date with our CVS sources.

Good luck.  Feel free to ask questions - in this forum, please.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]