RT-Druid command line

From ERIKA WIKI
Jump to: navigation, search

Introduction

It is possible to execute few RT-Druid's tasks without using a GUI. These tasks are invoked using RT-Druid scripts, usually located in <RT-Druid location>/evidence.

 Please, note that RT-Druid is based on eclipse framework even in the CLI form. This means that 
 - direct invocation of RT-Druid scripts result in execution of an eclipse environment

Packaging

RT-Druid is distributed in several packagings:

  • Update site: it contains only RT-Druid and Erika Enterprise plugins and can be used to update an existing installation of RT-Druid, or to add RT-Druid functionalities to a generic (and standard) installation of eclipse.
  • GUI: it contains RT-Druid and Erika Enterprise plugins, eclipse framework and c/c++ support. There are several versions, depending on Os (es. Windows, Linux).
  • CLI: it contains RT-Druid and Erika Enterprise plugins. It also contains the minimum set of eclipse plugins required by RT-Druid.

All above packages, contains the RT-Druid scripts.

Advantages

Both GUI and CLI packages can be used without a graphical interface, but the CLI one is smaller:

  • GUI packages requires around 300MByte
  • CLI with Erika Enterprise, RT-Druid requires around 20MByte

The CLI package is really portable: since it relies only on the java VM, the same package can be used on any architectures that has a java VM. This is not true for the GUI packages.


Disadvantages

On the other side, all CLI versions cannot be automatically updated and the easy way to "update" them is to download a new one.

Configuration

Usually, it is useful to configure one or more parameter before run RT-Druid from command line, like compiler and Erika Enterprise path. It can be done using property files, as explained in RT-Druid_configuration.


RT-Druid scripts

Here is the list of available scripts:

Task Name Description
generate_code Generates all configuration files for Erika Enterprise 3

Each script is available in for windows (with .bat suffix) and for cygwin/linux (with .sh suffix).


generate_code

The generate_code script invoke RT-Druid to generate all configuration files for Erika Enterprise 3. It has 3 parameter

  • the RT-Druid location in the filesystem
  • the OIL input file
  • the output dir where the code is generated

Example:

./generate_code.sh ~/evidence/rtdruid3/ ~/myproject/conf.oil ~/myproject/build