1 # SDKs management scripts
3 To support a new SDK family, you must create a new directory under
4 `scripts/sdk/xxx` where xxx is the new SDK family.
6 Then you must create the following scripts (or executable) :
9 - `db-dump`: returned the list of available SDKs (JSON format)
10 - `db-update`: update SDKs database
11 - `get-family-config`: returned SDK family configuration structure (JSON format)
12 - `get-sdk-info`: extract SDK info (JSON format) from a SDK file/tarball
13 - `remove`: remove an existing SDK
19 This script returns code 0 when sdk is successfully installed, else returns an
22 List of parameters to implement:
24 - `-f|--file <filepath>` : install a SDK using a file
25 - `--force`: force SDK install when a SDK already in the same destination directory
26 - `-u|--url <url>` : download SDK using this URL and then install it
27 - `-no-clean` : don't cleanup temporary files
28 - `-h|--help` : display help
32 Returned the list all SDKs (available and installed) using JSON format.
37 "name": "My SDK name",
38 "uuid": "a-unique-id",
39 "description": "A description",
42 "arch": "architecture",
43 "path": "path where sdk installed locally",
44 "url": "https://website.url.to.download.sdk",
45 "image_url": "https://website.url.to.download.image",
46 "status": "Not Installed | Installed",
47 "date": "2017-12-25 00:00",
49 "md5sum": "123456789",
50 "setupFile": "path to file to setup SDK environment"
52 "name": "My SDK name 2",
53 "description": "A description 2",
62 Update sdk database that may be used by `list` command.
64 ## `get-family-config`
66 Returned SDK configuration as JSON format:
71 "description": "bla bla",
72 "rootDir": "/yyy/zzz",
73 "envSetupFilename": "my-envfilename*",
74 "scriptsDir": "scripts_path"
80 - `familyName` : sdk familyName (usually same name used as xxx directory)
81 - `rootDir` : root directory where SDK are/will be installed
82 - `envSetupFilename` : sdk files (present in each sdk) that will be sourced to
87 Extract SDK info, such as name, version, ... from a SDK tarball file (when
88 --file option is set) or from a url (when --url option is set).
90 This script may also be used to check that a SDK tarball file is correct in
91 order to determine for example that the SDK family.
93 List of parameters to implement:
95 - `-f|--file <filepath>` : SDK tarball file used to get SDK info
96 - `-u|--url <url>` : url link used to get SDK info
97 - `--md5` : md5sum value used to validate SDK tarball file
98 - `-h|--help` : display help
100 This script returns an error (value different from 0) and potential print an
101 error message. Else when info are successfully extracted, this script must
102 returned the following JSON structure:
106 "name": "My SDK name",
107 "uuid": "a-unique-id",
108 "description": "A description",
109 "profile": "profile",
110 "version": "version",
111 "arch": "architecture",
113 "url": "https://website.url.to.download.sdk",
114 "image_url": "https://website.url.to.download.image",
115 "status": "Not Installed",
116 "date": "2017-12-25 00:00",
118 "md5sum": "123456789",
119 "setupFile": "path to file to setup SDK environment"
125 Remove an existing SDK
127 The first argument is the full path of the directory of the SDK to removed.