DEADSOFTWARE

add build instructions for macosx
authorDeaDDooMER <deaddoomer@deadsoftware.ru>
Sat, 26 Oct 2019 17:53:48 +0000 (20:53 +0300)
committerDeaDDooMER <deaddoomer@deadsoftware.ru>
Sat, 26 Oct 2019 17:53:48 +0000 (20:53 +0300)
macosx/Doom2DF.app.base/Contents/Info.plist [new file with mode: 0644]
macosx/Doom2DF.app.base/Contents/MacOS/.keep [new file with mode: 0644]
macosx/Doom2DF.app.base/Contents/Resources/Doom2DF.icns [new file with mode: 0644]
macosx/README [new file with mode: 0644]

diff --git a/macosx/Doom2DF.app.base/Contents/Info.plist b/macosx/Doom2DF.app.base/Contents/Info.plist
new file mode 100644 (file)
index 0000000..e2cc06a
--- /dev/null
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+       <dict>
+               <key>CFBundleGetInfoString</key>
+               <string>Copyleft 2003-2019 Doom 2D: Forever Developers</string>
+               <key>NSHumanReadableCopyright</key>
+               <string>Copyleft 2003-2019 Doom 2D: Forever Developers</string>
+               <key>CFBundleExecutable</key>
+               <string>Doom2DF</string>
+               <key>CFBundleIdentifier</key>
+               <string>org.doom2df</string>
+               <key>CFBundleName</key>
+               <string>Doom 2D: Forever</string>
+               <key>CFBundleDisplayName</key>
+               <string>Doom 2D: Forever</string>
+               <key>CFBundleIconFile</key>
+               <string>Doom2DF</string>
+               <key>CFBundleShortVersionString</key>
+               <string>0.667</string>
+               <key>CFBundleInfoDictionaryVersion</key>
+               <string>6.0</string>
+               <key>CFBundlePackageType</key>
+               <string>APPL</string>
+               <key>IFmajorVersion</key>
+               <integer>0</integer>
+               <key>IFMinorVersion</key>
+               <integer>667</integer>
+       </dict>
+</plist>
diff --git a/macosx/Doom2DF.app.base/Contents/MacOS/.keep b/macosx/Doom2DF.app.base/Contents/MacOS/.keep
new file mode 100644 (file)
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 (file)
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 (file)
index 0000000..a4eddb5
--- /dev/null
@@ -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
+```