Build OpenClonk: Difference between revisions

Newton (talk | contribs)
Created page with 'Windows users can check out this tutorial: Building with Visual C++ Otherwise, here is how you can build OpenClonk in three easy steps: : '''1. Get th…'
 
Marky (talk | contribs)
m Added link to the "building with linux" page.
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Windows users can check out this tutorial: [[Building_with_Windows|Building with Visual C++]]
Windows users can check out these tutorials:
 
[[Building_with_Windows|Building with Visual C++]]
 
[[Building_with_MinGW|Building with MinGW]]
 
[[Building_with_Linux|Building with Linux]]


Otherwise, here is how you can build OpenClonk in three easy steps:
Otherwise, here is how you can build OpenClonk in three easy steps:


: '''1. Get the source code'''
== 1. Get the source code ==
: See [[Mercurial Guide]]
See [[Git Workflow]]
: '''2. Install Build tools and libraries'''
 
: OpenClonk has a couple of dependencies on other libraries. Please refer to the Readme.*.txt in the freshly checked out source tree. You need to download and install the [http://www.fmod.org/index.php/release/version/fmodapi375win.zip FMOD SDK] and the [http://www.microsoft.com/downloads/details.aspx?FamilyID=24a541d6-0486-4453-8641-1eee9e21b282&displaylang=en DirectX SDK]. For windows, we provide prebuilt packages of libraries:
== 2. Install Build tools and libraries ==
OpenClonk has a couple of dependencies on other libraries. Please refer to the Readme.*.txt in the freshly checked out source tree.
: For Windows, we provide prebuilt packages of libraries:
:* [http://www.openclonk.org/openclonk-deps-vc90.zip for Microsoft C++ users]
:* [http://www.openclonk.org/openclonk-deps-vc90.zip for Microsoft C++ users]
:* [http://www.openclonk.org/mingwlibs2.zip for GNU Compiler Collection users]
:* [http://www.openclonk.org/mingwlibs2.zip for GNU Compiler Collection users]
: '''3. Compile the game'''
== 3. Compile the game ==
: Again, the Readme.*.txt has the details, as this step is highly platform dependent. But it's also comparatively uncomplicated: If you installed everything that's listed, and it doesn't build, you found a bug.
Again, the Readme.*.txt has the details, as this step is highly platform dependent. But it's also comparatively uncomplicated: If you installed everything that's listed, and it doesn't build, you found a bug.
 
= Building a debug engine =
 
The Clonk source code contains lots of little pieces of code that check that the engine works correctly. They can often help finding or preventing bugs, but slow the game down, so they are skipped in normal builds. To enable them, pass -DCMAKE_BUILD_TYPE=Debug to cmake, choose the Debug build in the IDE, or pass --enable-debug to configure. If you are using the GNU Compiler Collection, you can also enable [http://gcc.gnu.org/onlinedocs/libstdc++/manual/debug_mode.html the libstdc++ debug mode] by passing CPPFLAGS=-D_GLIBCXX_DEBUG to configure.

Latest revision as of 21:36, 19 December 2018

Windows users can check out these tutorials:

Building with Visual C++

Building with MinGW

Building with Linux

Otherwise, here is how you can build OpenClonk in three easy steps:

1. Get the source code

See Git Workflow

2. Install Build tools and libraries

OpenClonk has a couple of dependencies on other libraries. Please refer to the Readme.*.txt in the freshly checked out source tree.

For Windows, we provide prebuilt packages of libraries:

3. Compile the game

Again, the Readme.*.txt has the details, as this step is highly platform dependent. But it's also comparatively uncomplicated: If you installed everything that's listed, and it doesn't build, you found a bug.

Building a debug engine

The Clonk source code contains lots of little pieces of code that check that the engine works correctly. They can often help finding or preventing bugs, but slow the game down, so they are skipped in normal builds. To enable them, pass -DCMAKE_BUILD_TYPE=Debug to cmake, choose the Debug build in the IDE, or pass --enable-debug to configure. If you are using the GNU Compiler Collection, you can also enable the libstdc++ debug mode by passing CPPFLAGS=-D_GLIBCXX_DEBUG to configure.