How to compile OpenTTD for a Synology DS212+

This guide explains how to compile and install an OpenTTD server on your Synology DS212+ NAS.

Installing dependencies

Compiler packages

sudo ipkg install optware-devel


tar zxvf zlib-1.2.7.tar.gz
cd zlib-1.2.7
./configure --prefix=/opt --static
sudo make install


tar zxvf lzo-2.06.tar.gz
cd lzo-2.06
./configure --prefix=/opt
sudo make install


tar zxvf xz-5.0.4.tar.gz
cd xz-5.0.4
./configure --prefix=/opt
sudo make install

Create a symlink to the to prevent start up errors later on.

sudo ln -s /opt/lib/ /usr/lib/

Last thing you need to do is patch the pc file since the installed pkg-config version doesnt understand the URL entry.

sudo nano /opt/lib/pkgconfig/liblzma.pc


Save the file

Compiling OpenTTD

cd ~
mkdir games
cd games
tar zxvf openttd-1.2.2-source.tar.gz
cd openttd-1.2.2
./configure --enable-dedicated --with-zlib=/opt/lib/libz.a --with-liblzo2=/opt/lib/liblzo2.a

Now you can compile OpenTTD (this might take a while…)



Launching OpenTTD

  • Install a base graphics set (or install OpenGFX). Copy the files to:
  • Change to the bin directory
    cd bin
  • Launch openttd in server mode:
    ./openttd -D

7 Comment


    I have try to follow you tutorial but
    I have the following error when I do make :

    DiskStation> make
    make[1]: Entering directory `/root/games/openttd-1.3.0-RC1/openttd-1.2.3/objs/lang’
    [LANG] Compiling and Linking endian_check
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__adddf3@GLIBC_2.3.3′
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__muldf3@GLIBC_2.3.3′
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__fixunsdfsi@GLIBC_2.3.3′
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__floatsidf@GLIBC_2.3.3′
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__extendsfdf2@GLIBC_2.3.3′
    /opt/lib/gcc/powerpc-linux-gnuspe/3.4.6/../../../../powerpc-linux-gnuspe/lib/ undefined reference to `__subdf3@GLIBC_2.3.3′
    collect2: ld returned 1 exit status
    make[1]: *** [endian_check] Error 1
    make[1]: Leaving directory `/root/games/openttd-1.3.0-RC1/openttd-1.2.3/objs/lang’
    make: *** [all] Error 1

    do you know why I have this error ?

    Thanks a lot for you response

    11 Mar 2013 | Reply

    • Strange, not sure why this is happening (seems like a missing lib). Are you trying to compile 1.3.0-RC1 or 1.2.3? Your path name is a bit confusing. Perhaps try to install the package “optware-devel” and try again?

      14 Mar 2013 | Reply

      • Greg

        I have try to compile the version 1.3.0 (last stable version) and the 1.2.3. I have the same issue with both.
        The strange path is because I have try first with 1.3.0 and then with 1.2.3 (downloaded in the directory of 1.3.0).
        The first line of the tuto is “sudo ipkg install optware-devel” so I have already install this package.

        I’m completely loss I don’t know why it doesn’t works

        16 Mar 2013 | Reply

  1. Greg

    I forgot to specified that I try on a DS413

    11 Mar 2013 | Reply

  2. Jeffrey


    I am able to make a server and run it without LZMA but without it I can’t save the map.

    So now I want to make a server with LZMA installed but I keep getting the following error:

    you supplied ‘/usr/lib/’, but it seems invalid

    I am using the following command:

    ./configure –enable-dedicated –with-zlib=/opt/lib/ –with-
    liblzo2=/opt/lib/liblzo2.a –with-lzma=/opt/lib/

    I have installed all libs and updated them.

    28 May 2013 | Reply

  3. KeithWM

    So far, the very first command line is proving tricky enough. It seems, however, that this link: was of great help, so I will share it here for others.

    02 Aug 2017 | Reply

  4. Keith

    I keep running into this `/opt/lib/gcc/arm-none-linux-gnueabi/4.2.3/../../../../arm-none-linux-gnueabi/bin/ld: ERROR: /lib/ uses VFP register arguments, endian_check does not` error message when make. All the packages we succesfully installed using iplg, and `./configure` successfully, but not to libz. Could this be the (root of the) problem?

    Thanks in advance for any help.

    03 Aug 2017 | Reply

    Leave a reply