Release RMC-06.02
(2024-04-29)
|
Contents
Description
Description
Environment
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
- Enable WSL
- Open PowerShell as Administrator and run:
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
This may take a while...
- Restart computer
- Install your Linux Distribution of Choice
- Open Microsoft Store in start menu
- Search for 'Linux'
- Select wanted distro (e.g.: Ubuntu)
- Initialize the new distro
- Launch from Start menu
- Setup a new Linux user account
- 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
- Select an X server. E.g.:
Xming and
Xming fonts
GBS was tested with Xming.
- Download & Install both
- 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
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
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.:
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:
- Perl must be installed and the
perl command must be either in the PATH or
specified via an Environment-Variable (GBS_PERL_PATH).
- Decide where GBS will be installed (GBS_SCRIPTS_ROOT)
GBS will provide some nice defaults, but you can also specify you own location
- You will need to provide a Site-ID
and a Company and/or Project name
- You have the gbs .zip file in a DownloadDirectory (anywhere)
How to Install
'Install' command syntax here
Instructions for Install:
- Unzip the file to a new/empty temporary directory (NOT where you want to install GBS)
- cd to this directory (In the Navigator - if available)
- 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)
- Answer the questions.
For most questions you can assume the default. (between [])
- When done, do not forget to cleanup the temporary unzip directory
After the Install there will be:
- A 'Setup GBS [version]' shortcut on your Desktop and in System Programs
- 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:
- Subsequent installs can be run with -q flag (quiet).
This will run the script without human intervention assuming all defaults to be correct.
Setup
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.
|