buildframework/helium/sf/java/imaker/imaker.rst
author kelvzhu
Mon, 13 Sep 2010 13:11:19 +0800
changeset 640 ac0bbc1e5d79
parent 628 7c4a911dc066
child 645 b8d81fa19e7d
permissions -rw-r--r--
Merge sysdeftools's addtion
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     1
.. index::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     2
  module: Configuring ROM creation
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     3
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     4
========================
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     5
Configuring ROM creation
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     6
========================
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     7
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
     8
Called by :hlm-t:`build-roms` target. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
     9
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    10
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    11
.. index::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    12
   single: imakerconfigurationset type
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    13
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    14
The imakerconfigurationset type
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    15
-------------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    16
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    17
Information on how to configure the properties is given below:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    18
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    19
The imakerconfigurationset supports imakerconfiguration nested elements.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    20
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    21
**imakerconfiguration** element:
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    22
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    23
.. csv-table:: Attributes to modify
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    24
   :header: "Attribute", "Description", "Values"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    25
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    26
   ":hlm-p:`regionalVariation`", "Enable regional variation switching. - Deprecated (always false)", "false"
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    27
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    28
The imakerconfiguration supports three sub-types:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    29
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    30
.. csv-table:: Attributes to modify
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    31
   :header: "Sub-type", "Description"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    32
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    33
   ":hlm-p:`makefileset`", "Defines the list of iMaker configuration to run image creation on."
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    34
   ":hlm-p:`targetset`", "List of regular expression used to match which target need to be executed."
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    35
   ":hlm-p:`variableset`", "List of variable to set when executing iMaker."
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    36
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    37
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    38
Example of configuration:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    39
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    40
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    41
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    42
   <hlm:imakerconfigurationset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    43
      <hlm:imakerconfiguration regionalVariation="true">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    44
         <makefileset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    45
            <include name="**/product_name/*ui.mk" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    46
         </makefileset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    47
         <targetset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    48
            <include name="^core${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    49
            <include name="langpack_\d+" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    50
            <include name="^custvariant_.*${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    51
            <include name="^udaerase${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    52
         </targetset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    53
         <variableset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    54
            <variable name="USE_FOTI" value="0" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    55
            <variable name="USE_FOTA" value="1" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    56
            <variable name="TYPE" value="rnd" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    57
         </variableset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    58
      </hlm:imakerconfiguration>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    59
   </hlm:imakerconfigurationset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    60
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    61
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    62
Other example using product list and variable group:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    63
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    64
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    65
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    66
   <hlm:imakerconfigurationset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    67
      <hlm:imakerconfiguration>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    68
         <hlm:product list="product_name" ui="true" failonerror="false" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    69
         <targetset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    70
            <include name="^core${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    71
            <include name="langpack_\d+" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    72
            <include name="^custvariant_.*${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    73
            <include name="^udaerase${r'$'}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    74
         </targetset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    75
         <variableset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    76
            <variable name="USE_FOTI" value="0" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    77
            <variable name="USE_FOTA" value="1" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    78
         </variableset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    79
         <variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    80
            <variable name="TYPE" value="rnd" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    81
         </variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    82
         <variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    83
            <variable name="TYPE" value="subcon" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    84
         </variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    85
         <variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    86
            <variable name="TYPE" value="prd" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    87
         </variablegroup>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    88
      </hlm:imakerconfiguration>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    89
   </hlm:imakerconfigurationset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    90
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    91
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    92
.. index::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    93
   single: The iMaker Task
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    94
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    95
How to configure the target
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    96
---------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    97
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
    98
The target can be configured by defining an hlm:imakerconfigurationset element with the **imaker.rom.config** reference.
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    99
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   100
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   101
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   102
    <hlm:imakerconfigurationset id="imaker.rom.config">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   103
    ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   104
    </hlm:imakerconfigurationset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   105
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   106
The other configurable element is the engine. The :hlm-p:`imaker.engine` property defines the reference
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   107
to the engine configuration to use for building the roms. Helium defines two engines by default:
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   108
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   109
 - imaker.engine.default: multithreaded engine (hlm:defaultEngine type)
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   110
 - imaker.engine.ec: ECA engine - cluster base execution (hlm:emakeEngine type)
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   111
  
628
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   112
If the property is not defined Helium will guess the best engine to used based on the :hlm-p:`build.system` property.
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   113
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   114
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   115
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   116
The imakerconfiguration
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   117
-----------------------
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   118
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   119
The imakerconfiguration enables the build manager to configure his iMaker builds based on introspection. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   120
The makefileset element will configure the filtering of the "imaker help-config" command. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   121
Then for each of the configuration found the targetset elements will be used to filter the output from 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   122
the "imaker -f configuration.mk help-target-*-list" command. Finally a set of command will be generated. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   123
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   124
Each command will then be configure using the set of variables defined by the variableset elements. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   125
Only the WORKDIR variable is under the task control to ensure call safety during the parallelization. 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   126
The usage of the variablegroup will allow you to duplicate the common set of commands and apply 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   127
additional variables. Example:
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   128
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   129
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   130
 .. code-block:: xml
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   131
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   132
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   133
     <imakerconfiguration regionalVariation="true">
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   134
         <makefileset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   135
             <include name="**/product/*ui.mk"/>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   136
         </makefileset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   137
         <targetset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   138
             <include name="^core$" />
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   139
             <include name="langpack_\d+" />
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   140
             <include name="^custvariant_.*$" />
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   141
             <include name="^udaerase$" />
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   142
         </targetset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   143
         <variableset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   144
             <variable name="USE_FOTI" value="0"/>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   145
             <variable name="USE_FOTA" value="1"/>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   146
         </variableset>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   147
         <variablegroup>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   148
             <variable name="TYPE" value="rnd"/>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   149
         </variablegroup>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   150
         <variablegroup>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   151
             <variable name="TYPE" value="subcon"/>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   152
         </variablegroup>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   153
     </imakerconfiguration>
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   154
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   155
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   156
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   157
This configuration might produce the following calls :
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   158
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   159
 .. code-block:: xml
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   160
    
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   161
    imaker -f /epoc32/rom/config/platform/product/image_conf_product_ui.mk TYPE=rnd USE_FOTI=0 USE_FOTA=1 core
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   162
    imaker -f /epoc32/rom/config/platform/product/image_conf_product_ui.mk TYPE=subcon USE_FOTI=0 USE_FOTA=1 core
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   163
    imaker -f /epoc32/rom/config/platform/product/image_conf_product_ui.mk TYPE=rnd USE_FOTI=0 USE_FOTA=1 langpack_01
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   164
    imaker -f /epoc32/rom/config/platform/product/image_conf_product_ui.mk TYPE=subcon USE_FOTI=0 USE_FOTA=1 langpack_01
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   165
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   166
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   167
 
7c4a911dc066 helium_11.0.0-e00f171ca185
wbernard
parents: 587
diff changeset
   168