Skip to content

Latest commit

 

History

History
60 lines (44 loc) · 2.17 KB

compiling_everything_mac.md

File metadata and controls

60 lines (44 loc) · 2.17 KB

Compiling Teeworlds on Mac

IMPORTANT NOTE: SDL and Freetype libs are not shipped with Teeworlds 0.7.x. You must download them separately.

Q: What is BAM?

Bam is the build system made by matricks used in Teeworlds.

Setup

  1. Install Xcode from the Appstore or install Xcode Command Line Tools xcode-select --install.
  2. Install libsdl using brew brew install sdl2
  3. Install Freetype using brew brew install freetype
  4. Download and unzip Teeworlds-source or Teeworlds-latest-source
  5. Download and unzip bam to \teeworldsSource\bam
  6. Compiling bam
    • $ cd bam
    • $ ./make_unix.sh
    • $ cd ..

Compiling

  1. cd /teeworldsSource

    • Changes to the teeworlds source directory
  2. ./bam/bam config

    • Runs bam configuration
  3. ./bam/bam conf=release -f

    • Compiles teeworlds (Client and Server)
    • Flag -f will force a recompile
    • Available targets:
      • release (for all in release mode)
      • debug (for all in debug mode)
      • server_release
      • server_debug
      • client_release
      • client_debug
    • To build the tools and master server in release mode use the following arguments:
      • conf=release tools masterserver
  4. The compiled game is located at /teeworldsSource/build/..

For Teeworlds v0.6.x and earlier

Available targets are:

  • release (for all in release mode)
  • debug (for all in debug mode)
  • server_release
  • server_debug
  • client_release
  • client_debug

E.g. to build server debug use the following arguments:

../bam/bam server_debug

Also: Teeworlds 0.5.2 and earlier requires python 2.x to compile. Python 3.x will not work. Python 3.x support is introduced with Teeworlds 0.6.0.

Also: If you are using bam 0.2.0 (needed for Teeworlds 0.5.2 and earlier) the bam binary will not be in the bam directory, but in bam/src. You will need to change the paths accordingly to that or copy/move the bam executable to the bam directory.