Build FieldWorks

From LSDevLinux
Revision as of 12:54, 21 May 2009 by Mayhewn (talk | contribs) (pure-swf Branch Instructions: Add note about not doing tools-clean)

Jump to: navigation, search

These are instructions to build the currently-working parts of FieldWorks on Linux.

Check out from VCS

Make a working directory somewhere on your system and cd to it. Check out the FieldWorks and COM repositories into this directory using these commands:

$ svn co
$ svn co{COM,Win32Base,Win32More}

If you structure it differently than the above, you will need to modify the build configuration.

Unless specified otherwise, all following commands are to be executed from the FieldWorks directory that was checked out above. To go there now, immediately after executing the commands above:

$ cd FieldWorks

Install and build build dependencies

Install build dependency packages

In Ubuntu or Debian, install these dependencies:

$ sudo apt-get install build-essential tofrodos unixodbc-dev libgtkmm-2.4-dev \
  uuid-dev libmagick++9-dev mono-1.0-devel libmono-winforms1.0-cil \
  libgraphite-dev mono-gmcs libmono-winforms2.0-cil firebird2.0-dev \
  g++ automake mono-2.0-devel gawk libtool gtk-sharp2 libmono-cairo2.0-cil \
  libenchant-dev subversion xutils-dev libmono-dev

Automake 1.10 works. You may also need a Java runtime installed, e.g. openjdk-6-jre

Also if running Intrepid there is bug in the firebird package that creates an incorrect link. To fix this, sudo ln -sf /usr/lib/

Currently, you need a very recent version of mono (2.5 or later) to be able to run FieldWorks. If your distro doesn't have this you will need to obtain a specially-built package or build mono from source.

Set up our customized ICU

$ pushd Lib/src/icu/source
$ mkdir -p build$(uname -m) && cd build$(uname -m)
$ ../configure --prefix="$(cd ../..&&pwd)/install$(uname -m)" && make && make install
$ popd

Create a user-specific configuration file

$ cp -p Bld/_user.mak.lnx{.example,}

Then edit the resulting Bld/_user.mak.lnx to specify any system-specific build information you may have. However just creating it is usually sufficient and doing an edit is not usually necessary.


Optionally clean everything out

$ make tools-clean clean

Build everything

$ make tools all

Later update from VCS

$ svn up . ../COM ../Win32{Base,More}

Edit code

Open FieldWorks.mds in MonoDevelop to open the FieldWorks solution.

Run WorldPad

$ make -C Src/WorldPadGTK run

To start WorldPad in the gdb debugger:

$ make -C Src/WorldPadGTK run MONO='gdb --args mono'

pure-swf Branch Instructions

To work with the pure-swf branch, check out FieldWorks by typing

$ svn co

or switch an existing FieldWorks directory using:

$ svn switch

Then build using

$ make Unit++-package TE

Building Unit++-package only has to be done the first time, or each time you do a clean checkout. This replaces the make tools TE step in the main instructions above. If you wish to clean your build, use make Unit++-clean clean since tools-clean removes things that currently we can't rebuild easily and which instead have been checked into the repo.

Before running TE for the first time, run

$ make setup

Edit the resulting environ file and modify the line


to contain the IP or name of a remote Windows machine running a FieldWorks SQL database.

You can also edit the resulting environ file and modify the line


to contain the name of the database you want to open in TE. To change the database you use, just edit this line again.

Run Translation Editor using

$ make TE-run