Changes between Initial Version and Version 1 of DsxConfig


Ignore:
Timestamp:
Aug 16, 2006, 2:25:24 PM (18 years ago)
Author:
Nicolas Pouillon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • DsxConfig

    v1 v1  
     1== Config files ==
     2
     3DSX configuration is done through dedicated configuration files.
     4The following files are evaluated in order:
     5
     6 * `$DSX_DIR/etc/dsx.conf`
     7Default config, system wide.
     8 * `~/.dsx.conf`
     9In your home dir, default config, user wide
     10 * `./dsx.conf`
     11Setup for current directory / project.
     12
     13== Syntax ==
     14
     15Config files have an "ini-like" syntax, much like windows ini files.
     16{{{
     17# Comment
     18; Another commentaire
     19[section]
     20key1 = value1
     21key2 = value2
     22key3 = multi-line
     23   value, subsequent lines to
     24   concatenate must begin with a
     25   whitespace character.
     26   
     27[another-section]
     28key = val
     29}}}
     30
     31Parser has a great feature: it may extend contents of a variable within another with %(variable-name)s syntax:
     32
     33{{{
     34[calc]
     35oper = 2x3
     36result = 6
     37long = the expression %(oper)s equals %(result)s
     38short = %(oper)s = %(result)s
     39}}}
     40
     41== DSX' interpretation ==
     42
     43Section [defaults] describes sections to look at for project parts:
     44
     45{{{
     46[defaults]
     47soclib = soclib-exemple
     48systemc = systemc-exemple
     49     
     50[systemc-exemple]
     51dir = /users/exemple/systemc-2.1.0
     52os = linux
     53     
     54[soclib-exemple]
     55dir = /users/exemple/soclib
     56}}}
     57
     58This makes it easier to switch between different concurent configurations
     59
     60== Sections to fill ==
     61
     62DSX config defines paths for your actual system configuration
     63
     64 * Compilation options and paths for SystemC, SystemCASS or any other SystemC implementation
     65 * Path to SoCLIB
     66 * Paths and prefixes to cross compilation software suite
     67
     68=== SystemC, SystemCASS ===
     69
     70Mandatory configuration items for SystemC implementation are:
     71
     72 * `nickname`
     73    Type of implementation, possible values are: systemc, systemcass.
     74 * `cflags`
     75    Additionnal compile-time arguments, typically include paths, -W options, ...
     76 * `libdir`
     77    Additionnal link-time arguments, typically library paths
     78 * `libs`
     79    Libraries
     80 * `cxx`
     81    C++ compiler, default is g++.
     82
     83Example:
     84{{{
     85[systemcass-labo]
     86; Globally substitued variables
     87dir=/users/outil/systemc/systemcass/systemcass/latest
     88os=i686-Linux.SLA4x
     89
     90; Generic declaration
     91nickname=systemcass
     92cflags=-I%(dir)s/include -O3 -rdynamic
     93libdir=%(dir)s/lib-%(os)s
     94libs=-lsystemc -ldl -rdynamic
     95cxx=g++
     96}}}
     97
     98=== Cross compilers ===
     99
     100Options:
     101
     102 * `cc-prefix`
     103    Prefix for tools' names
     104 * `cc-cflags`
     105    Additionnal compile time flags
     106
     107Example:
     108{{{
     109[mipsel]
     110cc-prefix=mipsel-unknown-elf-
     111cc-cflags=-O2 -Wall
     112
     113[ppc]
     114cc-prefix=/usr/local/cctools/ppc/bin/ppc-unknown-elf-
     115cc-cflags=-O2 -Wall
     116}}}