README.md 2.65 KB
Newer Older
1
2
3
4
Cannonball - OutRun Engine
==========================

See [Reassembler Blog](http://reassembler.blogspot.co.uk/).
5
6
7
8

Credits
-------

9
10
* Chris White - Project creator.
* Arun Horne  - Cross platform work.
11

12
13
Getting Started
---------------
reassembler's avatar
reassembler committed
14
15
16

Cannonball has been successfully built for Windows, Mac OS X, Linux, Open Pandora and the Raspberry Pi. 

17
18
* Install your favourite C++ environment (e.g. GCC, Visual Studio, Xcode, MingGW etc.)
* Install [CMake](http://www.cmake.org/). This generates your platform and compiler build files. 
reassembler's avatar
reassembler committed
19
20
* Extract the [Boost Library](http://www.boost.org/) somewhere, for example: c:\coding\lib\boost_1_51_0
* Extract the [SDL Library](http://www.libsdl.org/download-1.2.php) somewhere, for example: c:\coding\lib\SDL-1.2.15
21
* Read the SDL documentation & compile the SDL Library for your system.
djyt's avatar
djyt committed
22
* Windows only, download and install the [Direct 8.1 SDK](http://stackoverflow.com/questions/5192384/looking-for-the-old-directx-8-1-sdk)
djyt's avatar
djyt committed
23
24
* Extract the Cannonball code somewhere, for example: c:\coding\cannonball
* You may need to create a .cmake file for your system to configure specific options. See the cmake subdirectory for more details. If not, the default.cmake file will be used.
25

26
27
Build
-----
28

djyt's avatar
djyt committed
29
* Run CMake to generate the relevant build files for your compiler. You can optionally pass -DTARGET=filename to pass a custom .cmake file
30
31
32
* Compile using your chosen compiler. Further details below.

###
33

34
35
    mkdir build
    cd build
36

37
38
39
40
### Non-IDE (e.g. straight GCC)
    
    cmake -G "Insert Generator Name Here" ../cmake
    make
41

djyt's avatar
djyt committed
42
### MinGW
43

44
    cmake -G "MinGW Makefiles" -DTARGET=mingw ../cmake
45
46
    mingw32-make
    
djyt's avatar
djyt committed
47
48
49
### Visual Studio 2010

    cmake -G "Visual Studio 10" ../cmake
50

51
52
53
54
55
### Mac OSX

    cmake -G "Unix Makefiles" -DTARGET:STRING=macosx ../cmake
    make

reassembler's avatar
reassembler committed
56
* Copy SDL.DLL and the roms subdirectory to the build directory.
djyt's avatar
djyt committed
57
* Right click the 'cannonball' project in the IDE and choose 'Set as StartUp project'. 
58
* You can then compile, debug and run from Visual Studio as expected.
59

60
61
62
63
64
65
66
67
68
69
70
71
Run
---

* Copy the OutRun revision B romset to the roms subdirectory. Rename the files if necessary.
* Copy or link the roms subdirectory to whereever your executable resides.

###

    ln -s ../roms roms
    ./outrun
    
    
djyt's avatar
djyt committed
72
73
74
75
Building SDL-1.2.15
-------------------

### Darwin
76
77
78

    ./configure --prefix=~/SDL-1.2.15/build --disable-assembly

djyt's avatar
djyt committed
79
80
### MinGW

djyt's avatar
djyt committed
81
See: [Setting up MSYS MinGW build system for compiling SDL OpenGL applications](http://blog.pantokrator.net/2006/08/08/setting-up-msysmingw-build-system-for-compiling-sdlopengl-applications/).
djyt's avatar
djyt committed
82

reassembler's avatar
reassembler committed
83
84
Execute the below commands from the msys environment.
    
djyt's avatar
djyt committed
85
86
87
    ./configure --prefix=/mingw --enable-stdio-redirect=no
    make
    make install