Table of Contents

Building Openbox

Compiling

The following is what you will need to compile Openbox:

Once you have the above dependancies installed, you are ready to build Openbox. Untar the Openbox archive and from inside the source tree, run:

% ./configure
  ...configure detects the build evironment...
% make
  ...openbox builds...
% make install
  ...openbox installs...

If the configure command fails and the reason is not obvious, you should look in the config.log file to discover the cause of the problem.

Installing

You can install Openbox by compiling from source or via binary packages. It is recommended that you get a package from your distribution if possible.

Once you have Openbox on your system, you will need to set things up to use it. What to set up depends on how you run X.

If you run the GNOME desktop environment:

The default window manager for the GNOME environment is metacity. To switch from metacity to Openbox, do the following:

% openbox --replace

Choose to save your session the next time you log out so that Openbox will be started for you when you log in again.

Note: As of GNOME 2.4, gnome-panel no longer manages its own key bindings, and requires that the window manager provide its own key bindings for showing the Main Menu and Run dialog. Openbox does this through the bundled gnome-panel-control tool, which can be used in keybindings to access the gnome-panel. Use the --main-menu option to display gnome-panel's menu, and the --run-dialog to display its Run dialog.

If you run the K desktop environment:

The default window manager for the KDE environment is kwin. To switch from kwin to Openbox, set the following environment variable in your startup scripts:

% export KDEWM=openbox

When the KDEWM environment variable is set, Openbox will be used in place of kwin.

Note: The current release of KDE is still using a non-standard, deprecated protocol for its system tray. This protocol requires interaction from the window manager. In place of that, Openbox includes the kdetrayproxy application. Once you run it, KDE system tray apps will work with window managers that don't support the legacy protocol, like Openbox.

To run kdetrayproxy before running KDE, and if you are using the KDE login manager, it may be easiest to use the display manager method, and make a startup script something like:

# Startup stuff for X

# Make openbox the KDE window manager
export KDEWM=openbox

# Make KDE system tray apps work
kdetrayproxy &

# Start the KDE environment
startkde

If you run X via the startx command:

You need to edit your $HOME/.xinitrc file. This file is simply a shell script, so to lauch Openbox just make a file something like this:

# Startup stuff for X

exec openbox

If you run X via a display manager (xdm, gdm, kdm, ...):

You may consult the documentation for your specific display manager regarding adding entries to it. Alternately, you can edit a $HOME/.xsession file. The file is a shell script and can be made identical to the .xinitrc example above. With this method, you would choose default as the login target in your display manager.

Table of Contents