These instructions are based on the latest AGS 3.4.1 tag.
- Xcode
- Xcode Command Line tools
- Homebrew
brew install curl pkg-config autoconf automake libtool cmake
You will need the Mac OS X 10.11 SDK:
- Get it from: https://github.com/phracker/MacOSX-SDKs
- Place the
MacOSX10.11.sdk
folder in/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
- Edit the
OSX/buildlibs/Makefile
to point to the SDK with-sdk macos10.11
as follows:
xcodebuild -project ALLEGRO.xcodeproj -target ALL_BUILD -configuration Release -sdk macosx10.11 && \
xcodebuild -project ALLEGRO.xcodeproj -target install -configuration Release -sdk macosx10.11
cd OSX/buildlibs
make
Making the libraries doesn't work yet in 3.4.1, allegro needs to be re-patched, there were a few changes in AGS 4.x that modified how allegro is patched:
The workaround:
- Check out the source code at
git checkout v.3.4.0.13
(after the mac changes were applied) - Make the libraries
- Re-check out the code at the newest tag again
- Get the original file.c from allegro 4.4.2 and replace it in
OSX/buildlibs/build/allegro-4.4.2/src/
- Remove the allegro patching step from the
OSX/buildlibs/MakeFile
or copy the cmake andxcodebuild
commands fromOSX/buildlibs/Makefile
to the terminal to rerun the build
open OSX/xcode/ags.workspace
There are two projects in the Xcode workspace:
- AGSKit is the framework
- ags is the game executable
You will modify ags to customize it into your game:
- Name
- Save Location
- Icon
- Game Files
- etc. (not explained in this doc.)
Open ags/Resources in Xcode, notice that you need to add:
- ac2game.dat
- acsetup.cfg
- audio.vox
- speech.vox
Create OSX/xcode/ags/game_files
Copy:
- .exe file
- acsetup.cfg
- speech.vox
- audio.vox
Rename .exe file to ac2game.dat (make sure that .exe is not included)
command+r to run!
You will get some linkage error for the project AGSKit
, this means that some libraries are missing in the current 3.4.x branch.
You will most likely need to add and remove to match the folder structure of the repo:
- vssver2.scc, out.cpp, outputtarget.h no longer exits, it will need to be removed
- messagebuffer.cpp, debugmanager.cpp/.h, outputhandler.h, midi.c are missing, needs to be readded to the proper folders
- the folder
allgero-4.4.2-agspatch
needs to be added to the proper location