Binary packages setup guide for robotpkg

Bootstraping binary packages installation

To install binary packages, you first need to know from where to get them. The first place where you should look is on the main robotpkg server in the directory http://robotpkg.openrobots.org/packages/bsd.

This directory contains binary packages for multiple platforms. First, select your operating system version and hardware architecture.

In this directory, you find a file called bootstrap.tar.gz which contains the package management tools. Download the file and extract it in the / directory. It will create files under the directory /opt/openrobots (containing the tools for managing binary packages and the database of installed packages). Note that you only need administration privilege to create the /opt/openrobots directory. You can extract the boostrap kit as a regular user, like shown in the following example:

% sudo mkdir -p /opt/openrobots
% sudo chown `whoami` /opt/openrobots
% cd /
% wget -O /tmp/bootstrap.tar.gz http://robotpkg.openrobots.org/packages/bsd/...
% tar xvzf /tmp/bootstrap.tar.gz

For you convenience, you can setup your PATH variable to easily run robotpkg commands, as well as the manual path to access the documentation:

% export PATH=${PATH:+$PATH:}/opt/openrobots/bin:/opt/openrobots/sbin
% export MANPATH=${MANPATH:+$MANPATH:}/opt/openrobots/man

Installing binary packages

In the HTTP directory from the last section, there is a subdirectory called pub/, which contains all the binary packages that are available for the platform, excluding those that may not be publicly available.

To install packages directly from the HTTP server, you can run the robotpkg_add command with a package name:

% robotpkg_add package-name

This works because bootstrap kit installs a default /opt/openrobots/etc/robotpkg_install.conf file, which contains a default PKG_PATH setting matching the default HTTP directory for the selected architecture. You can tune this file if needed, for instance to add other sources, separated by a colon.

Read the documentation:

% man robotpkg_add

Using a binary package manager

robotpkg_add will install any prerequisite packages needed to run the package in question. However, it will not handle upgrades smoothly. For this, you need a more sophisticated package manager, called pkgin. It has to be installed first with robotpkg_add:

% robotpkg_add pkgin

Then, you need to update pkgin database at least once, by running robotpkgin update:

% robotpkgin update

Installing a package is done by running robotpkgin install:

% robotpkgin install package-name

It is advised that you read the pkgin documentation:

% man robotpkgin

Deinstalling packages

To deinstall a package, you can just run robotpkg_delete package-name. The package name can be given with or without version number. Wildcards can also be used to deinstall a set of packages, for example *package*. Be sure to include them in quotes, so that the shell does not expand them before robotpkg_delete sees them.

Alternatively, robotpkgin remove package-name is the recommended command to run if you are using the binary package manager.

Getting information about installed packages

The robotpkg_info shows information about installed packages or binary package files. Check its manual:
% man robotpkg_info