From ba8dcc887f3ece99c7ee48cc0b5400ddd180b415 Mon Sep 17 00:00:00 2001 From: Didier 'OdyX' Raboud Date: Wed, 13 Nov 2013 14:04:11 +0100 Subject: Add an INSTALL file for MacOSX --- INSTALL-MacOSX.md | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 INSTALL-MacOSX.md (limited to 'INSTALL-MacOSX.md') diff --git a/INSTALL-MacOSX.md b/INSTALL-MacOSX.md new file mode 100644 index 0000000..862fda4 --- /dev/null +++ b/INSTALL-MacOSX.md @@ -0,0 +1,60 @@ +# Compile and install instructions on MacOSX + +To compile Colobot on MacOS X, you need to first get all tools, all +building dependencies (including the recompilation of some of them), and +finally compile colobot. + +* Install git from [git-osx-installer on Google Code](https://code.google.com/p/git-osx-installer/) +* Install Xcode through the Mac AppStore +* Accept the Xcode license + + xcodebuild -license + +* Download and install Apple's Command Line Developer Tools from within Xcode (Preferences, Download, Components) +* Download and install [Mac Ports](http://www.macports.org/install.php#requirements) +* Install GCC 4.8 through MacPorts + + sudo port install gcc48 + +* Install all colobot build depends + + sudo port install cmake libsdl libsdl_image libsdl_ttf boost libsndfile glew libicns librsvg + + > [po4a](http://po4a.alioth.debian.org/) should also be installed for the translation of levels, but the [MacPorts' Portfiles have not been accepted yet](http://trac.macports.org/ticket/41227). + +* Rebuild libtiff locally + + This is needed because of the following error: + + > libtiff.5.dylib (for architecture x86_64) because larger updated load + > commands do not fit (the program must be relinked, and you may need to + > use -headerpad or -headerpad_max_install_names) + + MacPorts changed the default linker flag, a simple local rebuild suffices: + + sudo port -ns upgrade --force tiff + +* Rebuild boost with the same gcc that we want to use + + This is needed because boost is compiled against Mac's system libstdc++ + which is older than the one used by gcc-4.8 + + sudo port -ns upgrade --force boost configure.compiler=macports-gcc-4.8 + +* Build colobot with gcc-4.8 + + mkdir -p build + cd build + CC=/opt/local/bin/gcc-mp-4.8 CXX=/opt/local/bin/g++-mp-4.8 cmake .. + make + +* Build a Colobot drag-n-drop package + + make package + +* Open the package + + open colobot-*.dmg + +* Once opened, drag the Colobot application and drop it in the + Application directory. Then just launch it as any other application. -- cgit v1.2.3-1-g7c22