Fs2 open on Linux/Quickstart

From FreeSpace Wiki
Revision as of 00:24, 9 July 2009 by Galemp (talk | contribs) (Created page.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Hi, Galemp here. If, like me, you're new to Linux and have no idea how to compile code, I have a quick startup guide here. You should at least be familiar with basic file management like moving and renaming files. USERNAME should be replaced with whatever your user home folder is named, such as 'fred'. I also assume that you have an administrator account. Make sure your video card drivers are working properly; other sources can assist you with this.

This guide was written using Ubuntu Linux 9.04. Note that EVERYTHING in Linux is case sensitive, so if your folder is named Games and you enter games it won't work. Also pay close attention to SPACES and DOTS. .fs2_open is not the same as fs2_open or fs2 open!

Part 1. Getting the game running. This assumes that you have access to a Windows installation of retail or GOG FS2, or otherwise have access to the original VPs. I copied mine from a mounted secondary hard drive that I boot Windows from.

  1. Copy the game data. If you're a Freespace modder, you install mods, or just like downloading new missions, it makes sense to put it in your Home folder. Copy all .VP files in your original install folder to /home/USERNAME/Games/freespace2. If you have any mods installed, such as MediaVPs or FSPort, move those folders as well.
  2. Download the Linux binaries. This is the actual game executable. The latest stable version as of this writing (00:24, 9 July 2009 (UTC)) is 3.6.10 RC3. If you'd like a newer build, or a specific one (such as a Wanderer, XT branch, or Inferno build) please see the Cross-Platform Development forum. Unpack the executables to the same folder where you put the Freespace VPs.
  3. Initial configuration. We're going to create a file that sets essential options for starting up Freespace. Browse to your home folder and press CTRL-H to unhide system files. Create a new folder called .fs2_open and inside that, create a plaintext file called fs2_open.ini. On the first line, put [Default] and on the second line put VideocardFs2open=OGL -(1024x768)x32 bit. You can change these parameters to your native screen resolution. Save and close it.
  4. Install Dependencies. Freespace Open requires a few external libraries to get going. We're going to install them as a super user (sudo) by using the get application command (apt-get.) Open Terminal under Applications > Accessories and enter this command: sudo apt-get install libopenal-dev libvorbis-dev build-essential automake1.9 autoconf libsdl1.2-dev libtheora-dev libreadline5-dev subversion You will need to enter your password when prompted.
  5. Run a test. Still in Terminal, let's see if Freespace will run. Enter this command: cd /home/USERNAME/Games/freespace2 to change to your game directory. Now type ./ and the name of the binary you downloaded, for example ./fs2_open_3_6_10_RC3 . If you've done everything correctly, you should have Freespace 2 up and running on Linux! Congratulations! From here you should be able to experience the game just as it was when it was released, and play online using FS2Net.

Part 2. Getting mods to work. If you want to run mods, things get trickier. First, there are currently some issues with current builds not supporting mods; second, you'll want to install a launcher to switch between them. The Llinux launcher, YAL, is non-portable, so we'll have to configure SVN (a tool for updating code databases) to download the latest code, configure it to work on your system, compile the code into a working executable, then move that to your Freespace directory. This is the most frustrating part of the whole process, but bear with me and we'll get through it. The Source Code Project team is working on an installer/launcher overhaul, so go bug them in the meantime.

  1. Install the fixed binary. For now, download and unpack [this build] into your Freespace directory. Or, try a build of your choosing.
  2. Download the launcher code. From Terminal, enter cd /home/USERNAME to navigate to your home folder, and enter mkdir yal to create a new folder named yal. This is where we'll put the code. Enter cd yal to navigate to that directory, then enter svn checkout svn://vega.livecd.pl/yal/trunk to download the latest launcher code.
  3. Compile the launcher code. Enter ./autogen.sh then make and in a moment it should compile a new binary. Move this to your Freespace directory by entering mv fs2_launcher /home/USERNAME/Games/freespace2.
  4. Test the launcher. Now you can try running the FS2 Launcher app in your Freespace 2 directory, choosing the fixed binary above and the mod of your choice. In all respects this should work like the Windows launcher, except that only a few tabs will be working.

Well, that worked for me. The_E and I are working on a script to automate some of this, so stay tuned.