Skip to content

Commit

Permalink
Mac OS X|Builder: Added a new build for OS X Mountain Lion (10.8)
Browse files Browse the repository at this point in the history
It turned out to be quite difficult to get Qt 4.8.4 in the Snow Leopard
build, so now there is a OS X 10.8 build with Qt 4.8.4 (64-bit only).
  • Loading branch information
skyjake committed Mar 26, 2013
1 parent 4d6072d commit 6dc057e
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 17 deletions.
5 changes: 3 additions & 2 deletions distrib/platform_release.py
Expand Up @@ -100,7 +100,8 @@ def mac_os_version():


def mac_target_ext():
if mac_os_version() == '10.6': return '.dmg'
if mac_os_version() == '10.8': return '.dmg'
if mac_os_version() == '10.6': return '_mac10_6.dmg'
return '_32bit.dmg'


Expand Down Expand Up @@ -337,7 +338,7 @@ def main():

try:
if sys.platform == "darwin":
print "Mac OS X"
print "Mac OS X (%s)" % mac_os_version()
mac_release()
elif sys.platform == "win32":
print "Windows"
Expand Down
1 change: 1 addition & 0 deletions doomsday/config.pri
Expand Up @@ -25,6 +25,7 @@
# - deng_nosnowberry (Unix) Exclude Snowberry from installation
# - deng_notools Do not build and deploy the tools
# - deng_openal Build the OpenAL sound driver
# - deng_qtautoselect (Mac) Select OS X SDK based on Qt version
# - deng_nopackres Do not package the Doomsday resources
# - deng_rangecheck Parameter range checking/value assertions
# - deng_snowberry (Unix) Include Snowberry in installation
Expand Down
22 changes: 12 additions & 10 deletions doomsday/config_macx.pri
Expand Up @@ -9,7 +9,7 @@ DEFINES += MACOSX
CONFIG += deng_nofixedasm deng_embedfluidsynth

# The native SDK option assumes the build is not for distribution.
!deng_nativesdk {
deng_qtautoselect:!deng_nativesdk {
contains(QT_VERSION, ^4\\.[0-6]\\..*) {
# 4.6 or earlier, assume Tiger with 32-bit Universal Intel/PowerPC binaries.
CONFIG += deng_macx4u_32bit
Expand All @@ -31,11 +31,7 @@ CONFIG += deng_nofixedasm deng_embedfluidsynth

# Apply deng_* Configuration -------------------------------------------------

deng_nativesdk {
echo(Using native SDK.)
DEFINES += MACOSX_NATIVESDK
}
else:deng_macx8_64bit {
deng_macx8_64bit {
echo(Using Mac OS 10.8 SDK.)
CONFIG -= x86
CONFIG += x86_64
Expand Down Expand Up @@ -75,15 +71,21 @@ else:deng_macx4u_32bit {

QMAKE_CFLAGS_WARN_ON -= -fdiagnostics-show-option
}
else:deng_nativesdk {
echo(Using native SDK.)
DEFINES += MACOSX_NATIVESDK
}
else {
error(Unspecified SDK configuration.)
}

# Adjust Qt paths as needed.
qtbase = $$(QTDIR)
isEmpty(qtbase):!isEmpty(QMAKE_MAC_SDK) {
QMAKE_INCDIR_QT = $${QMAKE_MAC_SDK}$$QMAKE_INCDIR_QT
QMAKE_LIBDIR_QT = $${QMAKE_MAC_SDK}$$QMAKE_LIBDIR_QT
!deng_macx8_64bit {
qtbase = $$(QTDIR)
isEmpty(qtbase):!isEmpty(QMAKE_MAC_SDK) {
QMAKE_INCDIR_QT = $${QMAKE_MAC_SDK}$$QMAKE_INCDIR_QT
QMAKE_LIBDIR_QT = $${QMAKE_MAC_SDK}$$QMAKE_LIBDIR_QT
}
}

# What's our arch?
Expand Down
21 changes: 16 additions & 5 deletions doomsday/postbuild/bundleapp.sh
Expand Up @@ -55,11 +55,16 @@ $CP tools/md2tool/md2tool $APPDIR/Resources
if [ -e plugins/fluidsynth/audio_fluidsynth.bundle ]; then
$CP plugins/fluidsynth/audio_fluidsynth.bundle $PLUGDIR/

GLIB_VER=`pkg-config --modversion glib-2.0`
GETTEXT_VER=`ls /usr/local/Cellar/gettext`

echo "Installing deps for audio_fluidsynth..."
echo "- glib version: $GLIB_VER"
echo "- gettext version: $GETTEXT_VER"
FWDIR=$BUILDDIR/Doomsday.app/Contents/Frameworks
cp /usr/local/lib/libglib-2.0.0.dylib $FWDIR
cp /usr/local/lib/libgthread-2.0.0.dylib $FWDIR
cp /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib $FWDIR
cp /usr/local/Cellar/gettext/$GETTEXT_VER/lib/libintl.8.dylib $FWDIR
chmod u+w $FWDIR/libglib-2.0.0.dylib $FWDIR/libgthread-2.0.0.dylib $FWDIR/libintl.8.dylib

# IDs
Expand All @@ -68,13 +73,17 @@ if [ -e plugins/fluidsynth/audio_fluidsynth.bundle ]; then
install_name_tool -id @executable_path/../Frameworks/libintl.8.dylib $FWDIR/libintl.8.dylib

# glib-2.0.0
install_name_tool -change /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib \
install_name_tool -change /usr/local/Cellar/gettext/$GETTEXT_VER/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $FWDIR/libglib-2.0.0.dylib
install_name_tool -change /usr/local/opt/gettext/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $FWDIR/libglib-2.0.0.dylib

# gthread-2.0.0
install_name_tool -change /usr/local/Cellar/glib/2.32.3/lib/libglib-2.0.0.dylib \
install_name_tool -change /usr/local/Cellar/glib/$GLIB_VER/lib/libglib-2.0.0.dylib \
@executable_path/../Frameworks/libglib-2.0.0.dylib $FWDIR/libgthread-2.0.0.dylib
install_name_tool -change /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib \
install_name_tool -change /usr/local/Cellar/gettext/$GETTEXT_VER/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $FWDIR/libgthread-2.0.0.dylib
install_name_tool -change /usr/local/opt/gettext/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $FWDIR/libgthread-2.0.0.dylib

# audio_fluidsynth
Expand All @@ -83,7 +92,9 @@ if [ -e plugins/fluidsynth/audio_fluidsynth.bundle ]; then
@executable_path/../Frameworks/libglib-2.0.0.dylib $DSFS
install_name_tool -change /usr/local/lib/libgthread-2.0.0.dylib \
@executable_path/../Frameworks/libgthread-2.0.0.dylib $DSFS
install_name_tool -change /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib \
install_name_tool -change /usr/local/Cellar/gettext/$GETTEXT_VER/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $DSFS
install_name_tool -change /usr/local/opt/gettext/lib/libintl.8.dylib \
@executable_path/../Frameworks/libintl.8.dylib $DSFS
fi

Expand Down

0 comments on commit 6dc057e

Please sign in to comment.