Subsections of Package Management

Installing Software

Subsections of Installing Software

Compiling from source

Introduction

With Compile, GoboLinux build utility, software sources can be downloaded, compiled and installed in a single step. An example will follow next.

In order to install irssi, a text-based IRC client from the command line, you would type the following instruction:

Compile irssi

Depending on the speed of your computer, internet connection and what packages you have installed, Irssi should download and install in a few minutes.

Compile manages the build process using GoboLinux recipes. Each recipe contains a list of build directives and supplemental control files for compiling a particular software library.

Finding recipes

Typically, you can just try the name of the recipe you want from the command line. There is also an online recipe viewer, listing the most recently uploaded recipes first.

Command-line options

Compile has a number of command-line options, which are listed here. The following are especially useful.

When using the --batch or -b automatically attempts to process all dependencies of the requested program.

Separating download and compile phases

The next two options are useful when working with intermittent internet access, or if you’d like to run your compiling jobs at night when you’re asleep.

Calling Compile with the --no-build flag downloads sources only.

Later, in the event that you wish to use the --no-web flag, this will direct Compile to search to your system’s own download cache and build the sources found there instead. This commandline switch is obviously very useful if you do not have a working internet connection for the time being.

Writing recipes

Main article: Writing recipes

Getting the latest Compile

To use the version of Compile, run

cd /Programs/Compile/Current
git pull && UpdateSettings --auto Compile

Installing binary packages

We do not maintain a binary package repository at this time!

Please build your packages from source using Compile!

Binary packages in GoboLinux are precompiled software packages built for the GoboLinux directory tree and made available through the GoboLinux software repository (recipe store). Since these packages are already compiled, you can save the many hours needed to build larger applications. On the other hand, with binary packages you don’t have the ability to set compile flags for optimization or specific architectures.

Installing packages

InstallPackage is the GoboLinux script for installing binary packages. If you want InstallPackage to look for the most recent Gimp package available, you can run

InstallPackage Gimp

The script will check if the package is available in the GoboLinux repositories. (See /System/Settings/GetAvailable.conf for the specific URLs scanned. You may add your own repositories if you desire.)

If you want to select a specific version, you can pass it as the second parameter:

InstallPackage Gimp 3.2.2

If you downloaded the package and want to install it, run:

InstallPackage Gimp--3.2.2--x86_64.tar.bz2

The script normally runs interactively, asking about each dependency of the requested package before installing it. You can avoid these queries by adding the --batch or -b flag. This is particularly useful with large packages such as Gimp or Xorg, which have many dependencies.

InstallPackage -b Gimp

Dependencies

InstallPackage will warn you if dependencies of a package you are trying to install are unavailable and ask if you want to continue. This is valuable, because some software may still work satisfactorily even if a particular plug-in or other dependency is missing.

Installing packages from the LiveCD

See Installing Packages from the LiveCD.

Removing packages

See Removing programs.

Updating Programs

Overview

Use the UpdateRecipes command to refresh your local cache of the GoboLinux recipe store.

You can query available updates using the utilities SuggestUpdates and SuggestDuplicates. The output of each of these commands is suitable for piping into commands.

The FindPackage and GetAvailable commands may also be useful.

Example Update Process

Keep in mind that most operations that change the file-system state in Gobo require super user privileges:

Ensure that Scripts are up to date

cd /Programs/Scripts/Current
sudo git pull && sudo UpdateSettings --auto Scripts && sudo make

Ensure that Compile is up to date

cd /Programs/Compile/Current
sudo git pull && sudo UpdateSettings --auto Compile

UpdateRecipes - Update local copy of recipe store

cd /Data/Compile/Recipes
sudo UpdateRecipes

SuggestUpdates - List packages with an update available

cd /Data/Compile/Recipes
SuggestUpdates

Install updates

Currently, there is no way to update packages automatically. This used to be done with the Freshen script, which is currently not in working order.

Updates thus need to be installed manually via InstallPackage or Compile as appropriate.

Removing Programs

In GoboLinux, all programs, whether binary packages or user-compiled software, are installed into a single directory under the /Programs hierarchy, such as, for instance, gimp:

/Programs/Gimp/3.2.2

Removing this program can be, in theory, as simple as:

rm -rf Gimp/3.2.2 

But since this leaves behind dangling symlinks, GoboLinux offers the RemoveProgram utility, which removes the program and all links pointing to its files in /System/Index.

RemoveProgram Gimp 3.2.2

Sometimes you may want to “turn off” a program temporarily, without erasing it from your hard disk. In other words, you want to remove program’s executables from the execution path, and remove libraries and headers from the lookup path.

In GoboLinux, this can be accomplished by removing the associated symlinks for /System/Index. The DisableProgram script facilitates this:

DisableProgram gimp 3.2.2

The version parameter given here, in this case 3.2.2, is optional. If it is not provided, the Current link is used to determine the program version to disable. Also note that the program name is case insensitive, but it appears to be simpler to use a downcased variant - easier to type at the least.

DisableProgram automatically appends a -Disabled tag to the version name, so in our case folder 3.2.2 has been renamed to 3.2.2-Disabled. This way, you can easily distinuish disabled from enabled programs via the file system alone.

To re-enable the program, all you need to do is recreate the symbolic links:

SymlinkProgram gimp 3.2.2-Disabled

GoboLinux has a script called RemoveBroken. that removes dangling symlinks from /System/Index tree. It can be useful to run after manipulating directories under /Programs.

RemoveBroken takes a list of files, and removes those that are dangling symlinks. If no arguments are provided, the script takes filenames from standard input (typically through a pipe).

The usual procedure to clean up dangling links, is

cd /System/Index
find | RemoveBroken
Info

GoboLinux actually performs this task automatically on any file system changes inside /System/Index. This is done via a Listener hook. Check out it’s configuration file at /System/Settings/listener.conf for more insight.

Managing Alien Packages

Introduction

For an introduction to Alien packages please refer to Alien Packaging Subsystem.

How to install and update Alien packages

In order to install a foreign package we can use the following syntax:

sudo Alien --install <package_manager>:<package_name>

For instance, in order to install or update meson you would type:

sudo Alien --install pip3:meson