ChorusOS 4.0 Porting Guide

Global Variables

The global variables folder contains definitions of global system image configuration variables.

Some of them are board-specific and used within the board-specific configuration files only. For example, a configuration for a PC/AT target defines the LOADER configuration variable, with a value specifying which of the two initial loaders (SVR4 boot and Linux LILO boot) will be used to load the system image. The format of the system image is tailored to match the requirements of the initial loader specified by LOADER.

There is one mandatory global variable, IMAGE_DIR. This variable specifies the working directory to be used by the mkimage tool to store the files created during system image generation.

Example 5-1 is an extract of the SBC8260 board-specific configuration file, and defines two global configuration variables, IMAGE_DIR and RESULT.


Example 5-1 SBC8260 Global Variable Configuration

<definition name='IMAGE_DIR'>
			<description>'mkimage' tool output repository</description>
			<string/>
			<vstring>${BUILD_DIR}/image/${BOOT_MODE}/${SYSTEM}</vstring>
</definition>

<definition name='RESULT'>
			<description>the resulting system image file pathname</description>
			<string/>
			<vstring>${BUILD_DIR}/${SYSTEM}.${BOOT_MODE}</vstring>
</definition>

The value of IMAGE_DIR specifies the mkimage working directory as a function of the BOOT_MODE and SYSTEM configuration variables. For example, the working directory for RAM-based chorus system image generation is ${BUILD_DIR}/image/RAM/chorus.

The value of RESULT specifies the filename of the resulting (bootable) system image file. The filename also depends on the BOOT_MODE and SYSTEM configuration variables. For example, the bootable RAM-based chorus system image file will be stored in ${BUILD_DIR}/chorus.RAM.