Build FieldWorks

From LSDevLinux
Revision as of 14:07, 5 November 2008 by Mayhewn (talk | contribs) (Set up our customized ICU: Fix typo)

Jump to: navigation, search

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

Check out from VCS

Check out the FieldWorks and COM repositories into a repo directory using these commands:

$ mkdir .../repo && cd .../repo
$ svn co http://linux.lsdev.sil.org/svn/FieldWorks/trunk/FieldWorks
$ svn co http://linux.lsdev.sil.org/svn/COM/trunk/{COM,Win32Base,Win32More}

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

Install and build build dependencies

Install build dependency packages

In Ubuntu Hardy, install these dependencies:

$ sudo apt-get install build-essential sysutils 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

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


You will need to update mono if using mono version 1 with the appropriate packages from: http://linux.lsdev.sil.org/downloads/mono/

Set up our customized ICU

$ cd .../repo/FieldWorks/Lib/src/icu/source
$ ./configure --prefix="$(cd ..&&pwd)/install" && make && make install

To use an architecture specific path instead, you can do:

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

Create a user-specific configuration file

$ cd .../repo/FieldWorks/Bld
$ cp _user.mak.lnx.example _user.mak.lnx

Run the above commands and then edit the resulting .../repo/FieldWorks/Bld/_user.mak.lnx to specify any system-specific build information you may have, if any.

Build

Optionally clean everything out

$ cd .../repo/FieldWorks && make clean && make tools-clean

Build everything

$ cd repo/FieldWorks && make tools && make

Later update from VCS

$ cd .../repo
$ svn up *

If you have other files in .../repo and svn complains about them, then instead of $ svn up *, you could do

$ svn up FieldWorks COM Win32Base Win32More

to be more specific.

Edit code

Open .../repo/FieldWorks/FieldWorks.mds in Monodevelop to open the FieldWorks solution.

Run WorldPad

$ cd .../repo/FieldWorks && make -C Src/WorldPadGTK run

To start WorldPad in debugger:

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