Difference between revisions of "Compile ECWolf on Mac OS X"

From ECWolf Wiki
(Created page with "This guide will demonstrate how to compile the Mercurial version of ECWolf on Mac OS X. == Dependencies == The following programs/libraries are used by ECWolf. The versions...")
 
 
Line 7: Line 7:
 
* [http://gcc.gnu.org/ GCC] 4.4.1
 
* [http://gcc.gnu.org/ GCC] 4.4.1
 
* [http://www.libsdl.org/ libsdl] 1.2
 
* [http://www.libsdl.org/ libsdl] 1.2
* [http://www.libsdl.org/projects/SDL_mixer/ SDL_mixer] 1.2.11
+
* [http://maniacsvault.net/ecwolf/files/tools/dev/ SDL_mixer for ECWolf] (Standard [http://www.libsdl.org/projects/SDL_mixer/release-1.2.html SDL_mixer] 1.2 will also work, but features will be disabled.)
 
In addition to the above, the following are optional dependencies.
 
In addition to the above, the following are optional dependencies.
 
* [http://www.zlib.net/ zlib] 1.2.3
 
* [http://www.zlib.net/ zlib] 1.2.3

Latest revision as of 06:31, 8 January 2015

This guide will demonstrate how to compile the Mercurial version of ECWolf on Mac OS X.

Dependencies

The following programs/libraries are used by ECWolf. The versions listed below are known to work, however other versions may work.

In addition to the above, the following are optional dependencies.

Mercurial is also needed to checkout a copy of the latest source.

Retrieving the Source

Use Mercurial to retrieve the latest version of the source.

hg clone https://bitbucket.org/Blzut3/ecwolf

Compiling

It is recommended that you create a build directory in the newly created ecwolf directory.

cd ecwolf
mkdir build
cd build

Run CMake to generate a Makefile. Assuming there were no errors, you should be able to run make to compile.

cmake ..
make

An ecwolf binary should be produced.

./ecwolf

Debugging

In most cases it is good idea to generate a back trace when ECWolf crashes. To make a debug build of ecwolf simply replace the cmake command with the following.

cmake -DCMAKE_BUILD_TYPE=Debug
make

You should now be able to use gdb to generate a back trace.

gdb ecwolf

GDB has it's own command prompt. Use "run" to start ecwolf and use "bt" to get the back trace after a crash.

(gdb) run
(gdb) bt

Building an App Bundle

While the CMake is configured such that it can build an app bundle (at times), the official bundles are built by hand. Simply replace the Contents/MacOS/ecwolf binary and respective pk3 with your own.