GUSTO

From Elite Wiki

Grand Unified Source Tree for Oolite

Oolite was originally developed for Mac OS X by Giles Williams, and it was approximately one year after Oolite going public that a Linux port was started. The Linux port was essentially started as a fork - in a separate Subversion repository. The original Mac OS X repository is at thor.acedragon.co.uk, and the new Linux work was to be done at BerliOS.de, in the Subversion repository provided by Berlios. The reason for using a separate repository (and essentially forking the project) was because thor.acedragon.co.uk is a machine under Giles's stairs and possibly did not have the bandwidth to support a great deal of multiple access to the repo. BerliOS also supplies infrastructure to easily manage open source projects, being based on SourceForge. Work was carried out on both repositories simultaneously, with new features being merged in from Giles's repository as he developed the game.

Foundation work

The BerliOS fork essentially drifted a little from the Mac OS X implementation (not in features - but certain files became heavy with GNUstep and SDLisms). OS X gained some features that weren't available on Linux and other platforms, and the Linux version gained features only available with SDL. The foundations for GUSTO were laid by Jens Ayton on 25th November 2005, with a branch in the BerliOS svn tree to reduce the differences between the SDL and OS X releases. This resulted in an SDL build that would build with Mac OS X + SDL (rather than the Mac's normal OpenGL access methods). It also made many of the files in the thor.acedragon.co.uk repository and the BerliOS repository identical. It was branch merged back into the BerliOS trunk just under one month later.

As well as this cleanup, it was also desirable to make the source tree a bit easier to navigate - it had grown very significantly in size since the early days of Oolite, and could benefit from a conversion from a single flat directory to a set of subdirectories for each distinct component.

The reorganization of the tree was carried out by Dylan Smith, starting on 31st January 2006 in the 'cocoa-merge' branch (the term GUSTO hadn't actually been yet coined). It was quickly nicknamed GUSTO by Rxke. It is important to note that this is not a bacronym! The branch became the SVN trunk on the 5th March 2006.

Result

The result is a source tree from which Oolite can be built for all platforms - the GNUstep/SDL platforms such as Linux, FreeBSD, IRIX and Windows, as well as the vanilla Mac OS X + Cocoa build. Ifdef hell has largely been avoided by putting files that are highly architecture specific into a source subdirectory which is only built for the architecture in question. Additionally, for non-OS X platforms, a generic tarball installer has been created which examines the build system and automatically packages the correct dependencies.

Anonymous checkouts can be made as follows:

svn checkout http://svn.berlios.de/svnroot/repos/oolite-linux/trunk

The GUSTO tree is organized as follows:

trunk
   autopackage          Files for building Linux autopackage distributions
   Asset Source         Files for building textures, sounds and images
   deps                 Dependencies, which currently contains:
       Cocoa-deps       Dependencies for OS X + Cocoa (Growl and Ogg Vorbis)
       Linux-x86-deps   Prebuilt GNUstep, SDL etc. for Linux on x86 processors
   Doc                  Documentation (apart from the top level README)
   FreeDesktop          Desktop files for GNOME and KDE
   GNUmakefile          Makefile for building GNUstep + SDL version
   Oolite-importer      Importer project for OS X
   Oolite.xcodeproj     XCode IDE project for building Oolite on Mac OS X
   OSX-SDL              Project files for the SDL version on OS X
   Resources            Textures, AI, config plists, images etc.
   src                  Objective-C source code:
      Core              Files that are built on all platforms
      SDL               Files that are only built for SDL platforms
      Cocoa             Files that are only built on OS X + Cocoa
      BSDCompat         Support for BSD features (strl* functions) - mainly Linux
   tools                Various tools for preparing files and builds, releases

Building Oolite with GUSTO

If you're using Mac OS X, use the Finder to navigate to where you checked out the svn repository, double click on the XCode Project and then use XCode to build. You will need to be running Mac OS X 10.4 (Tiger) with the latest version of XCode; if you don't have it already, it is a free download from the Apple Developer Connection. All you need to do is click Build, and when it has built, you can run/debug with the Run icon.

If you are using Linux, FreeBSD, IRIX or any other platform that supports GNUstep and SDL, make sure you have the development files (libraries and headers) for GNUstep and SDL. Ensure you have not only the base SDL libraries, but also SDL_image and SDL_mixer. In the case of Linux, most distributions contain all the necessary libraries and headers as part of their package repository (which is the easiest way of installing these files). Just run 'make' in the top level directory - when the build is complete, you should be able to enter 'openapp oolite' to start. You can also run tools/mktarballs which will build the project and make a tarball installer. Or if you are running Linux and have the autopackage development tools, you can run 'makeinstaller' to make an Autopackage.

Links