I downloaded the version of Dwarf Fortress for Linux onto my computer, but when I click on the df file, it doesn't do anything. When I run it in a terminal, it gives me this message:

error while loading shared libraries: libSDL_ttf-2.0.so.0: cannot open shared object file: No such file or directory
  • Self-explanatory No such file or directory,install SDL libraries – Uri Herrera Oct 8 '11 at 3:34
  • See this thread at this forum: bay12forums.com/smf/index.php?topic=66142.315 – Uri Herrera Oct 8 '11 at 3:35
  • I've had tons of trouble with getting DF to run because I'm on a 64-bit system, and getting the 32-bit dynamic library binaries to cooperate was quite a pain. There are workarounds, but I didn't find it worth my time. – Tom Thorogood Jun 17 '12 at 15:00

The Dwarf Fortress archive you downloaded features no dependency resolution, and that error indicates you haven't installed the necessary libraries to play.

Open a terminal and enter the following:

sudo apt-get install libsdl1.2debian libsdl-image1.2 libsdl-ttf2.0-0

That should allow Dwarf Fortress to run correctly unless you are on a 64-bit installation. On 64-bit installations, you may need to add ":i386" as seen here:

sudo apt-get install libsdl-image1.2:i386 libsdl-ttf2.0-0:i386 libgtk2.0-0:i386 libjpeg62:i386 libglu1-mesa:i386 libopenal1:i386

You may also run into problems with sound. If so, you can follow the directions on the dwarf fortress wiki, which suggest the following:

$ cd df_linux/libs
$ ln -s /usr/lib/i386-linux-gnu/libopenal.so.1 ./libopenal.so
$ ln -s /usr/lib/i386-linux-gnu/libsndfile.so.1 ./libsndfile.so
  • NOTE: If DF or Desura (which handles dependency resolution) ever lands in the Software Center, instructions to install that way should supersede these. – Jjed Nov 11 '11 at 5:14
  • 1
    Seems to be an incomplete answer, at least on a 64 bit system. – Kzqai Mar 26 '13 at 15:49
  • 1
    @Kzqai - I updated the answer to show the proper packages to get the game running on a 64-bit installation (at least in 14.04). – Aibara Sep 13 '14 at 18:52
  • On Linux Mint 17.3 (64-bit), the command sudo apt-get install libsdl1.2debian libsdl-image1.2 libsdl-ttf2.0-0 sufficed without the need for the :i386 counterparts – gilbertohasnofb Sep 7 '16 at 15:50

I was having the same issue and found a very easy workaround. Install Wine using software center and download the windows version of Dwarf Fortress.

After Dwarf Fortress is downloaded and wine is installed, go in dwarf fortress folder and right click Dwarf Fortress.exe and select Open With and then wine program loader. It just works. I thought it was easier than playing around with the libraries.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.