A manifest file stores software update information, including the vendor and hardware IDs of the target, timestamps, version numbers, and the size and path of the delta file. You must provide a manifest file as part of an update package.
The manifest file follows the .ini file format, which has these characteristics:
You can describe multiple updates in one manifest file. Each set of fields describing an update must begin with the id field wrapped in square brackets:
[id="UPDATE_ID"]
The lines that follow are treated as attributes of the same update until another update is specified or the end of the file is reached. All updates require a certain minimum set of fields:
Key | Description | Required | Example |
---|---|---|---|
action | Comma-seperated list of actions available for this update:
|
No | action=CAN_DECLINE_INSTALL,CAN_DEFER_INSTALL |
base_version | Expected version of the software currently installed on the target. The UpdateTarget can use this field to determine if it can accept the update. | No | base_version="00.00.00" |
format_version | Format version of the file. This must be the first field set in the file. Currently, the swu-core library supports version 20130918. | Yes | format_version=20130918 |
grace_period | Grace period for the update. The value is treated as a signed 64-bit unixtime. | No | grace_period=60000 |
hardware_id | Hardware ID, used with the value in vendor_id to uniquely identify an UpdateTarget when it's matched with an Update. | Yes | hardware_id="CAR2.1" |
id | Unique ID used by the update. This field starts a new update record in the manifest file. | Yes | [id="UPDATE_001"] |
long | Long description of the update contents. This field has no length limit. | No | long="The following bugs have been addressed in this release\n\t-Bug 77\n\t-Bug 88..." |
max_defer_period | Maximum deferral period for the update. The value is treated as a signed 64-bit value representing Unix time. | No | max_defer_period=3600000 |
name | Name of the update. | Yes | name="Security Release 242" |
path | Path of the software update file. This can be either an absolute path or a path relative to the manifest file. | Yes | path=./update_file/the_file_to_use.bin |
post_install_command | Command string to be run by the UpdateTarget after the install completes. | No | post_install_command="/scripts/post_update.sh" |
pre_install_command | Command string to be run by the UpdateTarget before the install starts. | No | pre_install_command="/scripts/prepare_for_update.sh" |
priority | Priority level of the update. This integer value must be between 1 and 20, where 1 is the highest priority and 20 is the lowest. | No | priority=3 |
short | Short description of the update contents. This field has no length limit. | No | short="Contains necessary bug fixes" |
size | Size of the software update file (in bytes). This is an unsigned 32-bit integer value. | No | size=22000000 |
timestamp | Release timestamp for the update. The value is treated as a signed 64-bit value representing Unix time. | No | timestamp=1375119694 |
vendor_id | Vendor ID, used with the value in hardware_id to uniquely identify an UpdateTarget when it's matched with an Update. | Yes | vendor_id="QNX" |
version | Version of the software update. | Yes | version="00.00.01" |
; This is a sample manifest file. ; All manifest files must start with the format_version key format_version=20130918 ; A comment about this first update [id="UPDATE001"] vendor_id="QNX" hardware_id="CAR2" timestamp=1375116694 short="A simple update to test some things" long="This is a simple test of the SWU system.\n\n\ \tTabbed text on a new line" version="00.00.01" base_version="00.00.00" name="Test Update" action=CAN_DECLINE_INSTALL,CAN_DEFER_INSTALL grace_period=600 size=2147483700 ; This update points to a delta file in the same directory path=mydelta.mld pre_install_command="/base/scripts/prepare_self_update.sh" ; A comment about this second update [id="UPDATE002"] name="Another Test Update" vendor_id="QNX" hardware_id="CAR2" long="This text description can be as long as need be,\ provided you escape any line breaks in the text string" version="00.00.01" short="YATU (Yet another Test Update)" timestamp=1375119694 ; This update points to an absolute path for a file elsewhere ; in the filesystem. path=/dos/mydelta.mld