Spring on MacOSX
Because all needed libraries are available for OSX as well, you can compile a working version of Spring for Mac. But Unitsync will only work between Intel Macs and PCs, but not between those and PPC, and due to Apple's switch from PPC to Intel and due to the astronomical amount of effort it would take to to make them sync, there is no PPC port under development.
There's also a working lobby client for Mac OSX, follow the instruction below to compile it.
Install Sping from source on an Intel Mac
The following guide was created and tested in a 2,53 Ghz 13" MacBook Pro, 4 GB RAM Nvidia GeForce 9400M and a MacPro Xenon Quadcore ATI Radeon HD 4870, both with Snow Leopard (10.6).
Dependencies:
U will need the following dependencies to compile:
Programs necessary to build * Xcode Tools * cmake (included in Xcode tools) * zip
Libraries * SDL * boost (version 1.35 or later recommended) * DeviL (IL, ILU) * OpenAL (comes with Xcode tools) * OpenGL headers (mesa, glew, etc.) (comes with Xcode tools) * zlib * freetype * ogg,vorbis and vorbisfile * Python (2.5)
Installing the Dependencies
Firstly, download the Xcode Development Tools from Apple or install them from your OsX DVD: http://developer.apple.com/technology/xcode.html (u will need to register, but its free of charge)
Then download and install Macports (http://www.macports.org) You need to be administrator to complete the following. Open the Terminal and copy and paste the first command and wait until it is completed, continue one-by-one with the others (you will be asked for the admin passwort each time).
sudo port install cmake sudo port install libsdl sudo port install libsdl-framework sudo port install boost sudo port install boost-jam sudo port install libpng sudo port install jpeg sudo port install tiff sudo port install libogg sudo port install libvorbis sudo port install python25 sudo port install libdevil
This will take some time and disk space, but should complete without problems. If you experience any errors, download the dependencies' source and compile it.
Fixes
Download the latest spring source from the download page. If you try to compile now, you will experience some errors, and therefor you will have to apply 2 fixes:
Firstly, there is an assembler code in Until.cpp you need to change. Original Source code in Util.cpp:
#else
__asm__ __volatile__(
"pushl %%ebx\n\t"
"cpuid\n\t"
"movl %%ebx, %1\n\t"
"popl %%ebx"
: "=a" (*a), "=r" (*b), "=c" (*c), "=d" (*d)
: "0" (*a)
);
- endif
Alter it like this:
#else __asm__ __volatile__( "pushq %%rbx\n\t" "cpuid\n\t" "movl %%ebx, %1\n\t" "popq %%rbx" : "=a" (*a), "=r" (*b), "=c" (*c), "=d" (*d) : "0" (*a) ); #endif
Secondly, there is just a placeholder command specified to create an error window during the game, so the compiler with complain about an unknown function.
DELETE this part of the code in ErrorHandler.cpp:
#elsif defined(__APPLE__)
MacMessageBox(msg, caption, flags);
Now Spring will use the X Window system (x11) for displaying error windows, that might look ugly because its not using Apple's Aqua GUI style but it works and you wont experience much errors during gameplay anyway ;)
Compiling:
Open the Terminal, change into the Spring source folder (e.g.: "cd Desktop/spring_0_80_5_2/") and follow the instructions below: (You will be asked for the admin passwort)
type "sudo cmake ." (the dot and the gap is important) type "sudo make" (this will take some time) type "sumo make install"
Result
Now, you have a a Unix Executalbe File called "spring" in your source directory and a "spring" directory in "usr/local/share/games/" (you need to make hidden folders visible to see it). Create a folder called "maps" and a folder called "mods" there. (This is where Spring will check for maps/mods). You can double click on the spring file (mod+map needed) and test if everything is allright.
Compiling the Lobby
You will need to get a lobby client (e.g.: SpringLobby: http://springlobby.info) and the dependencies to compile it from source following this guide: http://springlobby.info/projects/springlobby/wiki/InstallFromSource This Chapter will be extended soon.
--Grapefruit 11:08, 4 December 2009 (UTC)