1.1. Prior Required Tool Installations

The GNATbench plug-in for Wind River Workbench requires Workbench, version 3.2.3.x, 3.3.x or 4.x to be installed prior to installing GNATbench itself.

1.2. Installing GNATbench

The file gnatbench-<version>-<platform>-bin.zip is an archive to be installed through the regular Eclipse installation mechanism.

Open Workbench and select ‘Help -> Install New Software’. If this menu is not available, it can be added by selecting on Workbench ‘Window -> Open Perspective -> Advanced Device Development’.

Click on the ‘Add’ button to add a repository. Select ‘Archive’ and navigate to the zip file downloaded from AdaCore. The Location field will then reference that file. You can optionally enter a repository name for future reference, such as “GNATbench” (without the quotes). Click ‘OK’.

The Eclipse installer will then offer the choice of different versions of GNATbench for installation. For Workbench, select ‘AdaCore Plugins for WindRiver Workbench’ item matching your installed Workbench version (see Help > About Wind River Workbench menu to get the right version). Be certain to NOT select other version!

Click ‘Next’ and follow the installation wizard to completion. During the installation process, a dialog can be raised asking if you trust the AdaCore certificates. Check the mark next to the GNATbench certificate and press ‘OK’.

Note: the GNATbench Ada Development User Guide could be accessed after installation, along with all other User Guides, through “Help -> Help Contents” menu entry. Please read the “Before You Begin” section before beginning to use the plug-in.

1.3. GNATbench Installation into Workbench using administrator login

Users can use a Workbench installation managed by an administrator as long as the access rights allow them to read all files of the installation (same group as the user who installed Workbench).

By default, GNATbench and others Workbench extensions are installed in the user’s home directory. If you want to install them in a shared location or in any another location, you need to provide the new location to Workbench.

This is done changing osgi.configuration.area definition. It can be done editing config.ini file or adding a “-configuration <location>” startup option to the Workbench start command.

To check that the location was successfully changed, display osgi.configuration.area property in the configuration page of the Wind River Workbench installation details dialog. (see /Help menu)

See Eclipse Workbench User Guide: Running Eclipse in the Workbench online help for more information on startup options.

1.4. Verifying Correct GNATbench Installation

To verify that GNATbench has been installed into Workbench, use the Workbench Help menu. First, select Help and then “About Wind River Workbench” at the bottom of the selections. Then press the “Installation Details” button at the bottom of the resulting dialog box. Another pop-up dialog box will appear, with tabbed pages showing the installed software, installation history, features, plug-ins, and configuration. Click on the “Plug-ins” tab to show all the installed plug-ins. You should see a number of plug-ins with “AdaCore” shown in the Provider column. If so, installation is likely fine. If not, installation has not occurred or did not complete successfully.

The list of plug-ins will look something (but not exactly) like the figure below.

plug-ins list

Finally, verify that GNATbench is ready to use installed GNAT compilers.

At least one GNAT compiler should be installed to use GNATbench. Please note that no GNAT compiler is installed during GNATbench installation.

If a GNAT compiler was previously installed, check that any required changes to environment during GNAT installation have been done. As an example of such changes, the GNAT tools path should be added to the PATH environment variable. Otherwise, a GNAT compiler installation is requested and any required changes to environment variables must be performed. When a new compiler is installed, a workbench restart may be required to use the latest environment.

Successfully detected compilers are displayed in the /Ada/Toolchains preferences page accessible from the /Window/Preferences menu by selecting the Ada entry and then Toolchains.

toolchains window

If no toolchains are displayed, click on “Scan” button to start a toolchain scan.

1.5. Configuring the Project Build Type (Wind River Workbench 3.x only)

“Flexible” managed builds are used by default in Workbench; the older “Standard” managed builds are deprecated. Standard managed builds are still supported for existing GNATbench projects but, all new GNATbench projects will use Flexible managed builds. Therefore you should disable Standard managed builds so that you do not accidentally select them when creating new projects.

You should also ensure the option to “Create default build targets for new projects using flexible managed build” option remains enabled.

The build facility is controlled using the Wind River “Build” preference page. Set the options on the page as shown below. Note that you will only have to do this preference configuration once unless the preferences are somehow reverted.

enabling standard build pref page