GBS Logo HELP HOME Generic Build Support (GBS) - User Manual
Install Notes 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

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

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

OS / Shell

GBS runs on:

WSL Considerations

General

File locations
In WSL bash you can access Windows directories/files.
In Windows you cannot access WSL bash local directories/files (e.g.: ~/).
Therefore all GBS directories/files must be placed at a location accessible by Windows.
e.g.: MyDocuments or D:\Work
Install GBS on Windows
Before starting GBS on WSL you need to install it on Windows.
GBS will use the same physical installation for both Windows and WSL. So you will need WSL 1.
You need to install Perl AND GBS on Windows. For more info on installing Perl and GBS look below.

Install WSL

Documentation can be found at: WSL Installation Guide for Windows 10
  1. Enable WSL
    • Open PowerShell as Administrator and run:
      Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
      This may take a while...
    • Restart computer
  2. Install your Linux Distribution of Choice
    • Open Microsoft Store in start menu
    • Search for 'Linux'
    • Select wanted distro (e.g.: Ubuntu)
  3. Initialize the new distro
    • Launch from Start menu
    • Setup a new Linux user account
  4. Regularly Update & upgrade your distro's packages:
    sudo apt update && sudo apt upgrade

Install X Server

Documentation can be found at: Running Graphical Programs on Windows Subsystem on Linux
  1. Select an X server. E.g.: Xming and Xming fonts
    GBS was tested with Xming.
  2. Download & Install both
  3. Add export DISPLAY=localhost:0.0 to your ~/.bashrc file
    Use an editor (gedit/vim) or enter echo 'export DISPLAY=localhost:0.0' >> ~/.bashrc
    Mind the double >> !!!

Install commands using X server

  • gedit
    Enter: sudo apt install gedit (takes a long time, especially at 10%)

Additional bash commands

Refer to the Linux Considerations below for additional bash commands.

Linux considerations

On some Linux distributions some necessary bash commands are not installed.

xterm

Open a 'Terminal'
Note: A 'Terminal' is not always an xterm
To try: enter xterm -h
To install: enter sudo apt install xterm

at

Open a 'Terminal'
To try: enter at -h
To install: enter sudo apt install at
Make sure the atd daemon runs: enter sudo atd

Install Perl Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

GBS is based on Perl-scripts.
Perl must be installed and the perl command must be either in the PATH or specified via an Environment-Variable (GBS_PERL_PATH).
You need at least Perl version 5.16.3

If Perl (or the proper Perl version) is not in the PATH, define an environment variable GBS_PERL_PATH to point to the top-level directory where the proper Perl is installed.
e.g.: export GBS_PERL_PATH=/opt/ActivePerl-5.26

Perl can be obtained for free via GBS was developed and tested on Windows 10 with the Perl Distributions from ActiveState

Install

After download From ActiveState:
  • Windows:
    MSI Installer
    • Run the downloaded .msi file
      Answer the questions
      Note the Note below on install location
  • Linux:
    AS Package (Gzipped Tarball)
    • Copy the downloaded .gz file to an empty temporary directory
    • cd to that directory
    • tar zxf downloaded-file
      Creates a directory (tree) in the same directory
    • cd ActivePerl-5.26.version
      (The created directory)
    • ./install.sh
      Answer the questions
    • Adjust PATH or define GBS_PERL_PATH
More information: Installing ActivePerl 5.26.x

Note: There is a bug in core Perl on Windows that doesn't set up @INC correctly if Perl is installed into a directory that starts with the letter '5'. Your problem should go away if you install into something like C:\MyPrograms\perl\v5.10 instead.
This bug is at least 10 years old and somewhat related to finding additional site_lib directories when you are using the versioned directory layout scheme where multiple Perl versions share site_lib directories.
Found in Perl Monks

Missing Perl Modules

Missing Perl modules can be installed via CPAN. More info: How to install CPAN modules

Install GBS Bottom Doc. Button Top Document Button Down Section Button Up Section Button Down Chapter Button Up Chapter Button

Pre-Installed

If GBS is pre-installed (local or on a network drive) your GBS Administrator will be able to tell you where GBS is installed.
You will then only need to do the Setup as explained below.

Where to Install

Several versions of GBS can be installed in a GBS_SCRIPTS_ROOT directory.
They are installed using the Hard versioned directories method.
The latest build of a version is always installed under the plain version> directory. E.g: RMC-06.02
This is called the Current Build of a version. It will be overwritten with every install of the same version.
Specific Builds are installed under version_build directory. E.g.:

Toplevel Directory
GBS can be installed in two ways:
  • Single User:
    GBS will be installed in your environment.
    Setup (make this version current) is optional.
    A Local Shortcut will be created to run the Setup.
  • Multi User:
    GBS will be installed in a System area or on another global accessible location (E.g.: network drive).
    A System Shortcut will be created for individual users to Setup this version.
    Elevated privileges are required. (Linux: sudo -E, Windows: Run as Administrator).
If GBS is pre-installed (local or on a network drive) you will then only need to do the Setup as explained below.

The Install scripts only installs GBS (possibly on a central location).
To be able to use GBS, each user must 'Setup' GBS as explained below.
This tells GBS which of the versions to use.
During the Install you have the option to execute the setup immediately after the install (not with Multi-User).

Prerequisites:
  1. Perl must be installed and the perl command must be either in the PATH or specified via an Environment-Variable (GBS_PERL_PATH).
  2. Decide where GBS will be installed (GBS_SCRIPTS_ROOT)
    GBS will provide some nice defaults, but you can also specify you own location
  3. You will need to provide a Site-ID and a Company and/or Project name
  4. You have the gbs .zip file in a DownloadDirectory (anywhere)

How to Install

'Install' command syntax here

Instructions for Install:
  1. Unzip the file to a new/empty temporary directory (NOT where you want to install GBS)
  2. cd to this directory (In the Navigator - if available)
  3. cd to the newly created top directory (if not already there). (E.g.: gbs_RMC-06.02_2023-04-27) On Windows, from the Windows Explorer:
    • Run Install.bat (Single-User) or
      Run Install_As_Administrator.bat (Multi-User)
    On Linux:
    • If in the Navigator: Open a terminal in the current directory
    • Set the properties of Install.sh to executable:
      chmod u+x Install.sh
    • Enter:
      ./Install.sh (Single-User) or
      ./Install_As_Administrator.sh (Multi-User)
  4. Answer the questions.
    For most questions you can assume the default. (between [])
  5. When done, do not forget to cleanup the temporary unzip directory

After the Install there will be:
  1. A 'Setup GBS [version]' shortcut on your Desktop and in System Programs
  2. An 'unzipgbs.bat/.sh' and 'unzipgbs_admin.bat/.sh' in your:
    • Used Download directory (if known) or else the standard Downloads directory.
    • Documents directory (so you can always find it and copy it to the actual download directory).
    This command-file can be used for future Installs to unzip and install GBS combined.
    To use it, it must be in the same directory as the zip file.
Notes:
  1. Subsequent installs can be run with -q flag (quiet). This will run the script without human intervention assuming all defaults to be correct.

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

General

To setup GBS:
  • If you have a 'GBS Setup [version]' icon on your desktop:
    • DoubleClick it.
      Note: it may also be in 'All Apps' (Windows) or 'Applications' (Linux)
  • No icon:
    • [ Inquire at your GBS Administrator where GBS is installed. ]
    • Open a Terminal: CMD-Prompt (Windows) or XTerm (Linux)
    • Navigate to the directory where the wanted GBS-version is installed.
      e.g.: Q:\Tools\RMC\GBS\2.02
    • Execute:
      _gbssetup.bat  (Windows) (Mind the '_'!) or
      . _gbssetup.sh (Linux) (Mind the dot, the space and the '_'!)
      The full command syntax can be found here
  • A Terminal is started. Answer the questions.
    - Possible values are between ( )
    - Default value is between [ ]
    - Enter ! to quit processing safely
    Lines beginning with a '|' (vertical bar) are grouped in a 'form' with an 'OK?' question at the end. (N will repeat the questions, E will Cancel)
What happens on Windows:
  • Some internal stuff is setup
  • A GBS Startup and a GBS Help shortcut are placed on your Desktop and in the 'All Programs' menu.
What happens on Linux:
  • Some internal stuff is setup
  • Your ENV-file(s) (~/.bashrc and/or ~/bash_aliases) are updated to contain some GBS Startup stuff
  • On systems with a GUI (e.g. GNOME, Xfce, KDE, etc) a GBS Startup and a GBS Help shortcut are placed on your Desktop and in the 'All Programs' menu.


install.html