Building RKWard from Source

Note: These instructions are targetted at Linux/FreeBSD, where most required tools for compilation from source are readily available. Instructions for building on Windows, and building on MacOS, are available on the respective platform specific pages.

Getting the source code

Refer to Available source packages or Getting the source from git.

Installing required dependencies

RKWard requires:

Finding the appropriate naming of the required packages to install is the hardest part. Often it is easiest to look at the list of build dependencies for older versions of rkward contained in your distribution. Don’t shy away from asking for help.

At the time of this writing, on Debian based systems (such as Ubuntu) the following will get all the dependencies installed (and hopefully the package names will be similar on other distributions):

apt-get install r-base-dev cmake extra-cmake-modules libkf5archive-dev libkf5config-dev libkf5coreaddons-dev libkf5crash-dev libkf5doctools-dev libkf5i18n-dev libkf5notifications-dev libkf5parts-dev libkf5texteditor-dev libkf5xmlgui-dev libkf5widgetsaddons-dev libkf5windowsystem-dev qtwebengine5-dev qtbase5-dev qtscript5-dev qtdeclarative5-dev r-base-dev

On Arch linux: pacman -S qt5-webengine qt5-script qt5-declarative ktexteditor r extra-cmake-modules kdoctools

(Consider contributing the corresponding list for your distribution of choice as a merge request for this website).


IMPORTANT: You will need to have the R shared library installed. This is typically located in a place like /usr/lib/R/lib/ Unfortunately, some distributions do not yet ship their R binary with the shared library. In those (rare) cases, you’ll have to compile and install R on your own with the option –enable-R-shlib.

Suppose the source is obtained as rkward-0.7.2.tar.gz (here, version 0.7.2 is used as an example, change it accordingly). Then, the recommended steps to build from source are:

tar xzf rkward-0.7.2.tar.gz    # extracts to "rkward-0.7.0" directory
cd rkward-0.7.2
mkdir build                    # dedicated build directory is recommended, but not required
cd build
cmake .. [options]             # see *CMake options* below
make -j 5                      # the j parameter specifies the number of parallel units to compile;
                               # on systems with many cores, a higher value will speed up the build
sudo make install

CMake options (configuring)

The first paramter to cmake is the path to the rkward sources. In the example above, the build directory was created inside the extracted source directory, CMakeLists.txt exists in the directory immediately above; hence “..” is the appropriate path in this setup.

A number of parameters may be specified to control the build process. Some commonly needed are:

In some cases you may want to set the following options:

Further generic options are listed on .


As a last step, you have to run make install. Otherwise RKWard will be missing important menu-options, may behave strangely, or may not run at all. As this will require admin permissions, use: sudo make install

Make sure you have set the correct path in cmake (the -DCMAKE_INSTALL_PREFIX option).


For now it’s recommended to run RKWard from the command-line for debug-output. For the few available command-line options see

rkward --help


The most common source of problems are

  1. Missing some of the build requirements
  2. Wrong / missing parameters to cmake

So please re-read the corresponding sections, first. If you’re still in trouble, let us know, we’ll be happy to help you.

For some systems, Binaries_and_Build_Scripts has more information.