Aug 12

Descent Tutorial

Today I present a tutorial on compiling Descent for your Raspberry Pi running Raspbian.  At the end of this tutorial you should have binaries ready to go and and a playable version of the game Descent.  If you don’t want to wait for the compile, I have the binaries ready for you.  Just skip to the end.

  1. Install the required dependancies
    1. sudo apt-get install libsdl1.2debian libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl-image1.2 libsdl-image1.2-dev libsdl-ttf2.0-0 libsdl-ttf2.0-dev libsdl-net1.2 libsdl-net1.2-dev gcc-4.7 scons libphysfs-dev
  2. cd ~/
  3. mkdir descent
  4. cd descent
  5. Download the needed source code:
    1. wget http://sourceforge.net/projects/dxx-rebirth/files/dxx-rebirth/0.57.3/d1x-rebirth_v0.57.3-src.tar.gz
    2. wget http://sourceforge.net/projects/dxx-rebirth/files/dxx-rebirth/0.57.3/d2x-rebirth_v0.57.3-src.tar.gz
  6. Download the needed patches:
    1. wget http://www-user.tu-chemnitz.de/~heinm/tmp/d1x-rebirth-rpi.diff.gz
    2. wget http://www-user.tu-chemnitz.de/~heinm/tmp/d2x-rebirth-rpi.diff.gz
  7. Unzip the source files and the patches:
    1. tar xvfz d2x-rebirth_v0.57.3-src.tar.gz
    2. tar xvfz d1x-rebirth_v0.57.3-src.tar.gz
    3. gunzip d1x-rebirth-rpi.diff.gz
    4. gunzip d2x-rebirth-rpi.diff.gz
  8. You now have to patch the source code with the diff files.
    1. cd into the source code directories.
      1. Descent 1
        1. cd ~/descent/d1x-rebirth_v0.57.3-src/
        2. patch -p1 < ../d1x-rebirth-rpi.diff
      2. Descent 2
        1. cd ~/descent/d2x-rebirth_v0.57.3-src/
        2. patch -p1 < ../d2x-rebirth-rpi.diff
  9. We are now ready to compile!
  10. On the command line enter these two commands:
    1. export CC=gcc-4.7
    2. export CXX=g++-4.7
  11. Descent 1
    1. cd ~/descent/d1x-rebirth_v0.57.3-src/
    2. scons raspberrypi=1
      1. Wait around 30 – 40 minutes.
      2. If there are no errors you should now have a d1x-rebirth executable file in your directory!
  12. Descent 2
    1. cd ~/descent/d2x-rebirth_v0.57.3-src/
    2. scons raspberrypi=1
      1. Wait around 30 – 40 minutes.
      2. If there are no errors you should now have a d2x-rebirth executable file in your directory!
  13. You now need the data files that holds the actual game levels, sounds, artwork, etc.  These are in .hog, .pig, and .ham (descent 2 only) files.  You can get the game content from dxx-rebirth, the creators of this port.  They also have links to the shareware files:
    1. http://www.dxx-rebirth.com/game-content/
    2. http://www.dxx-rebirth.com/download/dxx/content/descent-pc-shareware.zip
    3. http://www.dxx-rebirth.com/download/dxx/content/descent2-pc-demo.zip
  14. Unzip those files by running unzip filename
  15. copy descent.hog and descent.pig to ~/descent/d1x-rebirth_v0.57.3-src/
  16. copy D2DEMO.HAM, D2DEMO.HOG and D2DEMO.PIG  to ~/descent/d2x-rebirth_v0.57.3-src/
  17. You are now ready to play!
    1. Descent 1
      1. cd ~/descent/d1x-rebirth_v0.57.3-src/
      2. ./d1x-rebirth -hogdir . (yes, thats a period at the end that must be there)
    2. Descent 2
      1. cd ~/descent/d2x-rebirth_v0.57.3-src/
      2. ./d2x-rebirth -hogdir .
  18. ENJOY!!


I realize these are a lot of instructions, but I wanted to make them as verbose as possible.
Below are the precompiled binaries with shareware data files already copied over.

Descent 1 Binaries | Descent 2 Binaries

Please let me know if any of this doesn’t work for you.  I wrote down every single step I did when I compiled it, but I’m afraid I may have missed something.  Let me know and I’ll correct it!

-Shea