From: DeaDDooMER Date: Sat, 26 Oct 2019 17:53:48 +0000 (+0300) Subject: add build instructions for macosx X-Git-Url: http://deadsoftware.ru/gitweb?a=commitdiff_plain;h=7ab10b287772f08db9bac64513165821e6f637a1;p=d2df-sdl.git add build instructions for macosx --- diff --git a/macosx/Doom2DF.app.base/Contents/Info.plist b/macosx/Doom2DF.app.base/Contents/Info.plist new file mode 100644 index 0000000..e2cc06a --- /dev/null +++ b/macosx/Doom2DF.app.base/Contents/Info.plist @@ -0,0 +1,30 @@ + + + + + CFBundleGetInfoString + Copyleft 2003-2019 Doom 2D: Forever Developers + NSHumanReadableCopyright + Copyleft 2003-2019 Doom 2D: Forever Developers + CFBundleExecutable + Doom2DF + CFBundleIdentifier + org.doom2df + CFBundleName + Doom 2D: Forever + CFBundleDisplayName + Doom 2D: Forever + CFBundleIconFile + Doom2DF + CFBundleShortVersionString + 0.667 + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + APPL + IFmajorVersion + 0 + IFMinorVersion + 667 + + diff --git a/macosx/Doom2DF.app.base/Contents/MacOS/.keep b/macosx/Doom2DF.app.base/Contents/MacOS/.keep new file mode 100644 index 0000000..e69de29 diff --git a/macosx/Doom2DF.app.base/Contents/Resources/Doom2DF.icns b/macosx/Doom2DF.app.base/Contents/Resources/Doom2DF.icns new file mode 100644 index 0000000..597c95a Binary files /dev/null and b/macosx/Doom2DF.app.base/Contents/Resources/Doom2DF.icns differ diff --git a/macosx/README b/macosx/README new file mode 100644 index 0000000..a4eddb5 --- /dev/null +++ b/macosx/README @@ -0,0 +1,71 @@ +D2DF-SDL for MAC OS X +--------------------- + +Doom 2D Forever ported to Mac OS X 10.4+. + +Building +-------- + +Requirements: +* Prebuilded libaries (you can get it from d2df-binlib.git) +* OpenDarwin cctools and fpc crosscompiler (if you want to cross compile) +* Mac OS X SDK >= 10.4u +* genisoimage from cdrkit (if you want to package to dmg) + +Copy Doom2DF.app.base to Doom2DF.app +Copy dynamic libraries to Doom2DF.app/Contents/MacOS +Copy game resources to Doom2DF.app/Contents/Resources + +Build on target machine: +``` +rm -rf tmp +mkdir -p tmp +cd ../src/game +fpc -g -gl -gs -O3 -dUSE_SDL -dUSE_OPENAL -dUSE_MODPLUG -dUSE_MPG123 \ + -FU../../macosx/tmp \ + -FE../../macosx/Doom2DF.app/Contents/MacOS \ + -Fl../../macosx/Doom2DF.app/Contents/MacOS \ + -oDoom2DF \ + Doom2DF.lpr +``` + +Or cross compile: +``` +rm -rf tmp +mkdir -p tmp +cd ../src/game +ppcrossppc -g -gl -gs -O3 -dUSE_SDL -dUSE_OPENAL -dUSE_MODPLUG -dUSE_MPG123 \ + -Tdarwin -Xd -XPpowerpc-apple-darwin- \ + -XR${MACOS_SDK} \ + -Fu${MACOS_SDK}/usr/lib \ + -Fu"${MACOSX_BINLIB_STATIC}" \ + -Fu"${MACOSX_BINLIB_DYNAMIC}" \ + -FE../../macosx/Doom2DF.app/Contents/MacOS \ + -FU../../macosx/tmp \ + -oDoom2DF \ + Doom2DF.lpr +``` + +Than fix library paths: +``` +powerpc-apple-darwin-install_name_tool -change \ + /usr/local/lib/libSDL-1.2.0.dylib @executable_path/libSDL-1.2.0.dylib \ + ../../macosx/Doom2DF.app/Contents/MacOS/Doom2DF +powerpc-apple-darwin-install_name_tool -change \ + /usr/local/lib/libmodplug.1.dylib @executable_path/libmodplug.1.dylib \ + ../../macosx/Doom2DF.app/Contents/MacOS/Doom2DF +powerpc-apple-darwin-install_name_tool -change \ + /usr/local/lib/libmpg123.0.dylib @executable_path/libmpg123.0.dylib \ + ../../macosx/Doom2DF.app/Contents/MacOS/Doom2DF +powerpc-apple-darwin-install_name_tool -change \ + /usr/local/lib/libenet.7.dylib @executable_path/libenet.7.dylib \ + ../../macosx/Doom2DF.app/Contents/MacOS/Doom2DF +``` + +Make Apple DMG: +``` +mkdir -p Doom2DF.root +cp -r Doom2DF.app Doom2DF.root +genisoimage -D -V "Doom 2D Forever" -no-pad -r -apple -file-mode 0555 \ + -o Doom2DF.dmg Doom2DF.root +```