build_boot_image command

Boot images are built using the build_boot_image command included in the development kit.

Usage

build_boot_image
  --help                     display this help and exit
  --boot_image <file>        save boot image in file
  --debug_boot_image <file>  save debug boot image in file
  --rootdisk <file>          save rootdisk in file
  --kernel <file>            save NFS kernel in file
  --config <config>          build boot image with config
  --source <path>            path to directory containing iips
  --info <name> <value>      set variable name=value in boot image build info
  --toolchain <path>         path to toolchain
  --iip <iip>                include iip in boot image
  [--architecture <arch>]    architecture to build boot image for in the format
                             architecture_hw-compatibility (e.g. st40_vip19x0)
  [--processor <processor>]   processor to build boot image for
  [--hw_comp <hw_comp>]      hardware variant to build boot image for
  [--goldenimage]            build a golden image
Various
Parameter Description
--architecture Name of target architecture. Valid values are st40_vip19x0 which is used for the Motorola VIP19X0 series, st40_vip19x3 which is used for the Motorola VIP19X3 series, bcm74xx_vip25x2 which is used for the Motorola VIP25X2 series, bcm74xx_vip22x2 which is used for the Motorola VIP22X2 series. And other target architectures are listed here: bcm74xx_vip10x2 bcm74xx_svr610 bcm74xx_ip700 bcm74xx_dcx3200p3. If this parameter is not set, the parameters 'processor' and 'hw_comp' must be specified.
--processor Name of target processor. Valid values are st40 which is used for the Motorola box using ST chipset, bcm74xx which is used for the Motorola box using Broadcom chipset.
--hw_comp Name of hardware variant. Valid values are vip19x0, vip19x3 when using ST chipset; vip25x2,vip22x2, vip10x2, svr610, ip700, dcx3200p3 when using Broadcom chipset.
--toolchain Path to the KreaTV toolchain.
--goldenimage build a golden image.
Boot image input files/directories
Parameter Description
--source Directories in which build_boot_image can find IIPs. Subdirectories will also be searched. It is possible to specify multiple sources.
--iip IP-STB Installation Package. A more convenient way to specify packages is to use a configuration file instead.
--config Configuration file containing IIP names. Blank lines and lines with '#' in the beginning (comments) are ignored. It is also possible to pass information values (see the --info parameter) through the configuration file. A comment line containing $<name>:<value> would be the equivalent of passing "--info <name> <value>" to build_boot_image.
Boot image targets
Parameter Description
--boot_image Boot image name.
--debug_boot_image Debug boot image name. A debug boot image prints information to the screen while the Motorola IP-STB is booting.
--rootdisk Rootdisk name. A rootdisk is usually only used together with a NFS kernel to NFS boot the Motorola IP-STB.
--kernel NFS kernel name. An NFS kernel is usually only used together with a rootdisk to NFS boot the Motorola IP-STB.
Boot image information
Parameter Description
--info Information about the boot image. All items are added to the Information Service using the names config.build.<name>.

It is also possible to pass information values using a configuration file, see the --config parameter.

The following items are quaranteed to have a value (set by build_boot_image, but possible to override):

  • branch (empty string as default)
  • date
  • host
  • time
  • user
  • version (empty string as default)

The following items are recommended to set:

  • company (name of the company building the boot image)
  • configuration (filename of the configuration file used)

Boot image config syntax

Below is a description of all valid boot image config syntax constructs. Note that adding a parameter to an IIP that does not have this documented will result in a build error.

# This is a comment. Empty lines and comments are ignored.

# Below is a comment that is the equivalent of passing.
# "--info <name> <value>" to build_boot_image.
# $<name>:<value>$

# Basic format without and with parameters.
iip-name
iip-name:param1=value1,param2=value2

# Include other configs (the two "" are optional).
@include "/absolute/path/to/config"
@include "../relative/this/config"

# Extra directory to search for IIPs, in addition to the ones given to
# build_boot_image with --source. May be given several times.
@search "/external/vendor/latest"

# Instead of writing "iip-name:param1=value1,param2=value2" on a single line,
# it can be split into two lines using "::" instead of ":" the second time.
# The result is that the parameters are concatenated.
iip-name:param1=value1
iip-name::param2=value2

# Remove an IIP by placing a "-" before the IIP name.
-iip-name

# Break long lines with backslash. Spaces before the backslash and at the start
# of the next line are ignored.
iip-name:long-parameter-name=with-a-long-parameter-value- \
  that-continues-on-the-next-line

# Environment variables are expanded in IIP parameters and path to include file.
iip-name:user=%USER%
@include "%HOME%/config"

# Environment variables are also expanded in the architecture list. This can be
# used to e.g. conditionally include an IIP based on the environment.
iip-name(%ARCHITECTURE%)

# A specific IIP can be include by using an absolute path.
/external/vendor/iip-name.iip:parameters

# All of the above constructs can be specified for only one or several
# architecture(s) using the syntax (arch1,arch2,...). See examples below.

# Include config only when building for VIP1900.
@include(vip1900) "extra/config"

# Include IIP only for VIP2000.
iip-name(vip2000)

# Add an extra parameter for VIP1900 and VIP2000.
iip-name(vip1900,vip2000)::param=value

# Include IIP for all platforms but VIP1500.
iip-name
-iip-name(vip1500)

Example 1 - simple configuration

The example below will build a boot image for the Motorola VIP1510 with a few applications and options. The following simple configuration is used:

The following configuration file (<config>) is used:

#
#
# $configuration:example$
#

# Applications
kreatv-app-webkit-portal::cache=0
kreatv-app-webkit-portal::database_storage_path=/flash/database/webkit/
kreatv-app-webkit-portal::gfx_pixmap_memory_limit=32
kreatv-app-webkit-portal::http_secure_mode=0
kreatv-app-webkit-portal::ntp_wait_limit=5
kreatv-app-webkit-portal::startinfront
kreatv-app-webkit-portal::sys_pixmap_memory_limit=64

# Keyboard mapping
kreatv-option-kreatvinput-keymaps:pc-en


# UI language
kreatv-option-ui-langs:eng

# Font
kreatv-font-kreativ

# Stream clients
kreatv-option-streamclients:basic

# Time zone
kreatv-option-tz:CET-1CEST-2,M3.5.0/02:00:00,M10.5.0/03:00:00

The example assumes that the development kit is installed in <dk> and the KreaTV Application Suite is available in <app-suite>. <toolchain> contains the toolchain path. The following command will then build the boot image:

build_boot_image \
    --toolchain <path> \
    --source <dk> \
    --source <app-suite> \
    --boot_image ip-stb-bi-example.bin \
    --architecture vip1900_25 \
    --config <config> \
    --info version 3.0.1.test

Complete scripts that build boot images for Motorola IP-STBs are included in the KreaTV Application Suite.

Example 2 - evaluation configuration

The following configuration will build a boot image that is very similar to an "evaluation" configuration. Added is also logging support:

This is the configuration file:


# $configuration:eval$
# Applications

kreatv-app-webkit-portal::cache=0
kreatv-app-webkit-portal::database_storage_path=/flash/database/webkit/
kreatv-app-webkit-portal::gfx_pixmap_memory_limit=32
kreatv-app-webkit-portal::http_secure_mode=0
kreatv-app-webkit-portal::ntp_wait_limit=5
kreatv-app-webkit-portal::startinfront
kreatv-app-webkit-portal::sys_pixmap_memory_limit=64

### Fonts

kreatv-font-kreativ

# Licenses
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_ac3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_eac3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_aac.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_mpeg2.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_wmv3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_h264.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_ca_macrovision.license

kreatv-option-toi2
kreatv-option-dvr::timeshift-buffer-max-bitrate=20
kreatv-option-dvr::timeshift-buffer-max-framerate=60
kreatv-option-dvr::timeshift-buffer-max-time=30
kreatv-option-streamclients:rtsp,basic,http,bitband

# Central European Time
kreatv-option-tz:CET-1CEST-2,M3.5.0/02:00:00,M10.5.0/03:00:00
kreatv-option-ui-langs:da-DK,en-US,fi-FI,no-NO,sv-SE
kreatv-option-usb
kreatv-option-kreatvinput-keymaps:pc-en
kreatv-option-kreatvgfx-stack
kreatv-option-kreatvgfx-subtitlerenderer:dvb,teletext,dvd,xsub

### Tools
kreatv-tool-logging
kreatv-tool-telnet

Example 3 - configuration with downloadable applications

KreaTV Dynamic Download makes runtime IIP download possible. IIPs can hold applications and these can either be downloaded at boot, started at boot or started when activated. Only one uninstallable application is allowed to be installed at a given moment.

Note! There is also a possibility to register dynamically downloadable applications at runtime. This means they do not have to be listed in the configuration file at all.

The following configuration holds a bunch of dynamically downloadable applications:

This is the configuration file:


# $configuration:eval$
# Applications

kreatv-app-webkit-portal::cache=0
kreatv-app-webkit-portal::database_storage_path=/flash/database/webkit/
kreatv-app-webkit-portal::gfx_pixmap_memory_limit=32
kreatv-app-webkit-portal::http_secure_mode=0
kreatv-app-webkit-portal::ntp_wait_limit=5
kreatv-app-webkit-portal::startinfront
kreatv-app-webkit-portal::sys_pixmap_memory_limit=64

### Fonts

kreatv-font-kreativ

# Licenses
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_ac3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_eac3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_audio_decode_aac.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_mpeg2.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_wmv3.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_video_decode_h264.license
kreatv-option-license::file=%BSG_SRC_ABS%/platform/iips/options/license/kreatv_ca_macrovision.license

kreatv-option-toi2
kreatv-option-softwareservice
kreatv-option-application-download
kreatv-option-dvr::timeshift-buffer-max-bitrate=20
kreatv-option-dvr::timeshift-buffer-max-framerate=60
kreatv-option-dvr::timeshift-buffer-max-time=30
kreatv-option-streamclients:rtsp,basic,http,bitband

# Central European Time
kreatv-option-tz:CET-1CEST-2,M3.5.0/02:00:00,M10.5.0/03:00:00
kreatv-option-ui-langs:da-DK,en-US,fi-FI,no-NO,sv-SE
kreatv-option-usb
kreatv-option-kreatvinput-keymaps:pc-en
kreatv-option-kreatvgfx-stack
kreatv-option-kreatvgfx-subtitlerenderer:dvb,teletext,dvd,xsub

### Tools
kreatv-tool-logging
kreatv-tool-telnet