Build Rocrail from Source


Get Rocrail Sources

Git Clone

Request access to the sources in the Rocrail Forum.

git clone <granted link> Rocrail

Updating the local tree

Only the first time a clone is downloaded, afterward only the changes:

cd Rocrail
git pull


Resolve conflicts

Sometimes local changes can conflict with a pull from the repository like:

error: Your local changes to 'rocs/rocs-gen.tar.gz' would be overwritten by merge.  Aborting.
Please, commit your changes or stash them before you can merge.

Solution 1:

git reset --hard
git pull

Solution 2:

git stash
git pull
git stash pop


Build Rocrail from source (Linux)

Use the following commands as a normal user, not as root:

  • Install git, libusb-dev and the wxGTK (libwxgtk3.0-0, wxGTK-devel) including develop package (build-essential)
  • check out the Rocrail sources
  • cd Rocrail
  • make all
  • sudo make install

On certain Linux distributions a 'make fromtar” may be required.


Build Rocrail from source (Windows)

Get the sources as desribed earlier.

  • Install MinGW. (add the mingw\bin to your path environment)
  • Install and compile wxWidgets.
  • Change the wxroot variable in the Rocrail\rocgui\makefile-mingw to match your wxWidgets directory.
  • Install Inno Setup if you want to create the setup.
  • cd Rocrail
  • make -f makefile-mingw unicode (use ansi for Windows 9x)
  • start Inno Setup in Rocrail\rocrail\package and open the rocrail.iss; compile.


Problems

  • Many header and source files are generated in the build process and are not in the repository!
  • If you have problems compiling the rocs library, the object generator binary does not fit to your Linux system. Try make fromtar.
  • After changing the rocs.xml you must also commit the rocs-gen.tar.gz in svn!!!


Main Build Targets

Target Description
all Server and Client.
fromtar Same as all but with pre generated files.
server Server only.


Fedora Core 10

To install wxwidgets on fedora core you have to type this in a shell window:

sudo yum install wxGTK 2.8.* 

followed by

sudo yum install wxGTK-devel 

Afterwards continue with the make process.


OpenSuSE 12

Instal the wxWidgets-ansi-devel package if an error like this is reported compiling Rocview:

error: invalid use of incomplete type 'wxNode {aka struct wxObjectListNode}'



Gentoo Linux

To install wxwidgets on Gentoo Linux you have to “emerge” it first. “emerge” is the command under Gentoo that will compile and install a package. So after a

emerge x11-libs/wxGTK

and some screens full of compiling messages, you will have a RAW wxlib on your system. Then, there is a configuration utility “eselect” which can choose various profiles for various packages. The whole trick is, that you (just) have to type

eselect wxwidgets set 1

after emerging the lib. That way, you have selected “profile 1” (the only one there is) and wxwidgets is configured for usage when compiling apps that rely on it (which is the case for Rocrail). Perhaps when future generations read this, there are more than one profiles for wxwidgets.

eselect wxwidgets list

Gives you a list of available profiles, like this

Available wxWidgets profiles:
  [1]   gtk2-unicode-release-2.8

and after you have selected the profile, an asterisk marks it as active:

Available wxWidgets profiles:
  [1]   gtk2-unicode-release-2.8 *

After this is finished you may continue with the standard make process described at the top of the page.


None Intel 32 Bit OS

The binary utilities to generate objects and wrappers are in the source repository only available for i386 CPUs.
Error messages like this are mostly related to none 32bit Intel:

/bin/sh: ../../rocs/bin/ogen: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
...
impl/attr.c:23:33: fatal error: rocs/impl/attr_impl.h: No such file or directory


To build Rocrail on other platforms use the make target fromtar.
Use the following command in the Rocrail main directory:

make PLATFORM=LINUX fromtar

Presupposed utilities

  1. gzip
  2. tar

PLATFORM

The default platform is Linux.
Supported are:

  • LINUX
  • MACOSX
  • HP
  • SOLARIS
  • OPENBSD
  • WIN32 (cross compile)
  • WIN64 (experimental cross compile)

Personal Tools