Contents
Description
Example of a sca_*.gbs
Description
Purpose
The sca_*.gbs files are used to define the behaviour of SCA Audits.
There are two types of sca_*.gbs files:
- The sca_build.gbs file
- Primary file
- Specifies the associated Build
- The sca_uppercase_name.gbs file
- Include file
- Can be included by the sca_build.gbs (and also by other sca_uppercase_name.gbs files.
The sca_*.gbs files can be placed in the following locations:
- $GBS_SUBSYS_PATH/audit/$audit
- $GBS_SYSAUDIT_PATH/$audit
The sca_build.gbs file is first searched in the current SubSystem/audit directory.
If not found it is searched in the SYSAUDIT directory
General
Please refer to .gbs files: General information
Additional for this file:
- The .include directive is allowed.
If the sca_build.gbs was found in the SubSystem the Include-path is:
- $GBS_SUBSYS_PATH/audit/$audit
- $GBS_SYSAUDIT_PATH/$audit
If the sca_build.gbs was found in the SYSAUDIT the Include-path is:
- $GBS_SYSAUDIT_PATH/$audit (same directory) only
Contents:
Syntax:
- +|-flag value|value-list [ #comments ]
The file is basically a 'flags' file.
Flags are switched on and off by placing a '+' or '-' in front
One flag per line
Possible flags are: E F Q T
Only the E flag can be disabled all others must be preceded by a '+'
Semantics:
- E value-list
- Enables/Disables Warnings/Errors from the sca tool.
- value-list
- ALL | message-id | message--wildcard-id
Initially all Warning/Errors are enabled
Wildcard characters are '*' and '?'
Note that '+E ALL' is the same as '+E *'
- F value
- Specifies the Format of the warning/error message on stdout.
- value
- NONE | DEFAULT | PCLINT | VISUAL_C | GNU_C | ECLIPSE
- Q path
- Ignore (Quiet) warnings/errors in the specified path / file-spec.
- path
- File or Directory Path
Note that system header-files and files in GBSEXT_plugin_PATH are Quieted by default.
- T threshold_expression
- Override Threshold setting for a Metric.
- threshold_expression
- Syntax:
- metric_name=[min_value][,max_value][:msg_nr]
- Either min_value or max_value must be specified, or both.
- msg_nr: Specifies a use-defined message to be output after file-analysis.
Not implemented yet.
Notes:
None
Example of a sca_*.gbs:
#========================================================
# [SYSAUDIT:pclint[mingw]] sca_mingw.gbs
#========================================================
.include sca_ALL.gbs
###EOF###
and...
#========================================================
# [SYSAUDIT:pclint[ALL]] sca_ALL.gbs
#========================================================
-E ALL
+E 1* 2* 3* # Enable all messages starting with 1 2 or 3
+E 537 # Repeated include file name
-E 1042 # At least one class-like operand is required with operator
+Q $GBSEXT_MINGW_CPP_PATH
+F NONE
+T TLN=20,400:6001
###EOF###
|