GBS Logo HELP HOME Generic Build Support (GBS) - User Manual
The tool.gbs files Bottom Doc. Button
Release RMC-06.02
(2024-04-29)


- Home
Getting Started
- Quick Start
- Release Notes
- Install Notes
- Create a GBS-WA/System
- FAQ
- Terms and Conditions (The Fine Print)
Basics
- Definitions & Acronyms
- Introduction
- Top Level Directory Structure
- Full Directory Structure
- Handling SubSystems & Steps
- Procedures
- Software Configuration Management Support

Manual Pages
- The Command-Line Interface
- All Commands
- The gbssys... Commands
- Generating Code (Building)
- Libraries & Executables and Testing
- Exporting Deliverables
- Auditing
- Customisations (Session)
- Customisations (User)
- Customisations (Admin)
- Integration with other Tools
- Plugins (Admin)
- Environment Variables (EnvVars)
User Files
- The GLKBT (glk/glb/glt) Files
Internal (.gbs) Files
- GBS Files - General
- audit.gbs
- broadcast.gbs
- build.gbs
- export.gbs
- flags_*.gbs
- subsys.gbs (.bat/.sh)
- incs_*.gbs
- owners.gbs
- sca_*.gbs
- scope.gbs
- site.gbs (.bat/.sh)
- steps.gbs
- switch.gbs (.bat/.sh)
- system.gbs
- tool.gbs
Various
- Development
- About
- Metrics Help

Full Documentation
- All Docs - Printable


Contents Bottom Doc. Button Top Document Button Down Section Button Blank

Description
Example of a tool.gbs

Description Bottom Doc. Button Top Document Button Down Section Button Up Section Button

Purpose Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Blank

The tool.gbs files are located in the GBS_SYSTOOLS_PATH/tool directories and are used to define the particularities of a Tool.

General Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Please refer to .gbs files: General information

Additional for this file:

  • Lines with no leading white-space (called header-lines) define an item.
  • Following lines with leading white-space (called sub-lines) define the parameters for that item.
  • Reserved words (keywords) are case sensitive
  • The search path for the .include Directive is:
    - $GBS_SYSTOOLS_PATH/$GBS_TOOL
    - $GBS_SYSTOOLS_PATH

Contents Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

SETUP definition
DEFAULTS definition
INIT definition
RUN definition

SETUP Definition Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Purpose:

To define general stuff, valid for the whole definition set.

Syntax:

SETUP
NICE_NAME = nice_name

Semantics:

NICE_NAME
Specifies a more descriptive name of the Tool. It is used in messages.
nice_name
Free format (just do not make it too long)

DEFAULTS definition Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Purpose:

To set Tool dependent defaults, overriding the GBS defaults

Syntax:

DEFAULTS
ACTION = action-definition

Semantics:

Refer to RUN semantics below.

INIT definition Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Purpose:

To perform general initialisation.
It is possible to define derived Tool dependent Environment Variables
Note that all references to the 'outside-world' must be specified in the switch.gbs.
On Windows it can be used to (re)define an EnvVar with spaces removed. (Converted to ShortPathName)

Syntax:

INIT
SET_W = envvar_name => envvar_value
...
SET_X = envvar_name => envvar_value
...
SET = envvar_name => envvar_value
...
SETPATH = path_envvar_name => envvar_value-list
...
BIN_DIR = bin_dir

Semantics:

SET_W, SET_X & SET
Specifies an Environment Variable.
envvar_name
Uppercase please
envvar_value
If placed between quotes (") it will be canonicalised (/.. solved) and on Windows converted to a ShortPathName without spaces.
SET_W is executed for Windows only.
SET_X is executed for Linux only.
SET is executed for all platforms
and must be specified after SET_W and SET_X
SETPATH
Specifies a PATH Environment Variable.
path_envvar_name
Case dependent on OS
envvar_value-list
If placed between quotes (") items will be canonicalised (/.. solved) and on Windows converted to a ShortPathName without spaces.
Items will be properly joined (';' on Windows, ':' on Linux)
Must be specified after SET_W, SET_X & SET
BIN_DIR
Specifies the directory in which the executables of the plugin reside, relative to GBSEXT_<plugin>_PATH.
It is used to assemble GBSEXT_<plugin>_BIN_PATH which must be used in the COMMAND sub-section.
bin_dir
One or more directories, separated by '/'

RUN Definition Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Purpose:

To provide information on how to run the Tool program (executable or script)

Syntax:

RUN
ACTION = actiondefinition
...
COMMAND = [ [ pre-condition ; ] ok_exit_values-comma-list ; ] command-definition
...

Semantics:

ACTION
Specifies possible actions of the Tool. To be used as pos-arg, option or EnvVar
action-definition
action-definition := action_name... => option
E.g.:
ACTION = API => api
ACTION = FULL => full
Default is the first in the list
COMMAND
Command to invoke the Tool program.
Syntax and Semantics:
Refer to the COMMAND description
More than one COMMAND can be specified.
The command is called with the following positional parameters:
  • $1 selected_action
    The option value of the DEFAULT ACTION
  • $2 subsys_def_list
    A comma-list of selected SubSystem definitions
    subsys_def := subsystem:subsystem_type
    subsystem_type := GBS | MSVS | make | Other
    E.g.: subsys1:GBS,subsys2:make,subsys3:GBS
  • $3 out_file_spec
    $GBS_SILO_PATH/tools/$GBS_TOOL/index.html
  • $4 out_file_path
    $GBS_SILO_PATH/tools/$GBS_TOOL
The following additional Environment Variables are set and may be used:

Notes: Bottom Doc. Button Top Document Button Down Section Button Up Section Button Blank Up Chapter Button

None

Example of a tool.gbs: Bottom Doc. Button Top Document Button Down Section Button Up Section Button

File 1 (Basic reference - implicit default) Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Blank

    #========================================================
    #   doxygen_api [doxygen] tool.gbs
    #========================================================
    .plugin doxygen
    
    .include <tool.gbs>
    
    ###EOF###
    

File 2 (Basic reference - explicit default) Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

    #========================================================
    #   [doxygen] tool.gbs
    #========================================================
    .plugin doxygen
    
    .include <tool.gbs>
    
    DEFAULTS
        ACTION = FULL
    
    ###EOF###
    

File 3 (Full specification) Bottom Doc. Button Top Document Button Blank Up Section Button Blank Up Chapter Button

    #========================================================
    #   %TOOL% [doxygen] tool.gbs
    #========================================================
    
    SETUP
        NICE_NAME	= DoxyGen
    
    INIT
        BIN_DIR	= bin
    
    RUN
        ACTION = API    => api
        ACTION = FULL   => full
        COMMAND = >doxygen/bin/doxygen.pl %1 %2 %3 %4
    
    ##EOF##
    

tool.html