raptor_self_version_check.html 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. <html>
  2. <body>
  3. <h1>Raptor self version check</h1>
  4. Starting with 2.16.16, Raptor has the capability to validate its own version
  5. against a regular expression specified in the SDK. This regular expression
  6. defines a range of versions of Raptor deemed compatible.<br/><br/>
  7. In addition to this, SDK creators can also specify a version description
  8. message that is displayed to users when using an incompatible version.<br/>
  9. <h2>Usage</h2>
  10. The recommendation is that the 'generic' variant in the XML file in
  11. epoc32/sbs_config/ is extended to enable the version check. To do this, an
  12. 'env' tag should be added as a child element of the 'generic' variant. This
  13. 'env' tag must specify the following attributes and values (note that the
  14. values are case sensitive):
  15. <br/>
  16. <br/>
  17. <table border="1" cellspacing="0" cellpadding="3" >
  18. <tr>
  19. <th>Attribute</th>
  20. <th>Value</th>
  21. </tr>
  22. <tr>
  23. <td>'name'</td>
  24. <td>'SBS'</td>
  25. </tr>
  26. <tr>
  27. <td>'default'</td>
  28. <td>'sbs'</td>
  29. </tr>
  30. <tr>
  31. <td>'type'</td>
  32. <td>'tool'</td>
  33. </tr>
  34. <tr>
  35. <td>'versionCommand'</td>
  36. <td>'$(SBS) --version'</td>
  37. </tr>
  38. <tr>
  39. <td>'versionResult'</td>
  40. <td>A regular expression matching the required versions. It is an error if<br/>
  41. the version of the currently running version of Raptor does not match this.</td>
  42. </tr>
  43. <tr>
  44. <td>'versionDescription'</td>
  45. <td>A message to display to users if the version check fails</td>
  46. </tr>
  47. </table>
  48. <br/>
  49. <br/>
  50. Below is an example of an 'env' attribute (with one attribute per line for
  51. clarity):</br>
  52. <pre>
  53. &lt;env
  54. name='SBS'
  55. default='sbs'
  56. type='tool'
  57. versionCommand='$(SBS) --version'
  58. versionResult='2\.17\.[0-9]+'
  59. versionDescription='SBS v2.17.0 or newer is required for this SDK.'
  60. /&gt;
  61. </pre>
  62. In this example, the 'versionResult' attribute specifies that any of the
  63. versions 2.17.x can be used with the SDK. The 'versionDescription' attribute's
  64. value could be extended to give more specific details.
  65. <h2>Command line usage</h2>
  66. In the SDK's, the 'armv5' group is redefined to have the 'generic' variant on
  67. by default. The effect of this is that any build that uses the 'generic'
  68. variant will have the Raptor self version check by default.
  69. <br/><br/>
  70. An error is always raised if the version check fails. If '-k' is passed to
  71. Raptor, the build will continue, and without '-k', the build will stop.
  72. <h2>Note</h2>
  73. Starting with 2.16.4, the sbs.bat and sbs shell scripts set the SBS
  74. environment variable, so it is available in the build, and in particular
  75. for the version check.
  76. </body>
  77. </html>