Installing Apertium

This page explains how to install the Apertium machine translation program on your machine.

The linguistic source files are compiled in $GTHOME/langs/ and then manually copied over to the apertium folder. The tags are converted automatically during the make process. (We assume you are a Mac user. For Linux users things are slightly different. Cf. the Apertium documentation.)


You must have downloaded Apertium, either the full tree, or the relevant language pairs only. You must have installed hfst. You must also compile apertium  and lttoolbox, they are located in the catalogues apertium/trunk/apertium and apertium/trunk/lttoolbox.

The quick installation guide to apertium and lttoolbox is: Make sure these two lines are in your ~/.profile file:

export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig"

Compiling the machine translation module Apertium

Then, check out the apertium tree, or part of it:

Either all:
    svn co apertium

Or only parts:
    svn co
    svn co
    svn co
    svn co

Compile lttoolbox, apertium and apertium-lex-tools. Cf. the documentation.

Compiling apertium for the language pair

Move to the folder, and compile there:

cd apertium/incubator/apertium-sme-smn
./ --with-lang1=/path/to/sme/tools/mt/apertium --with-lang2=/path/to/smn/tools/mt/apertium

Here, the path may be e.g. /Users/USERHOME/main/langs/sme/.

configure: error: Could not find binaries dir for giella-smn (AP_LIB2="/Users/USERHOME/gtsvn/langs/tools/mt/apertium")

Then compile the langage fsts, and thereafter the MT program itself, read:

Daily compiling of Apertium files