From b35528c527278f3bd7fa13a3c6094dc571beba67 Mon Sep 17 00:00:00 2001 From: Vadim Peretokin Date: Sat, 16 Nov 2013 18:40:49 +1000 Subject: [PATCH] Made build script copy mudlet-lua into the package qmake at this point copies mudlet-lua data into the .app package, and the mac-deploy.sh script successfully packages a .dmg with mudlet-lua inside it. Now all that remains is to adjust Mudlet to look for mudlet-lua when it loads wherever OS X puts it (that needs finding out). --- .gitignore | 2 ++ src/mac-deploy.sh | 3 ++- src/mac_src.pro | 13 +++++++++++-- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index f1b54f07d88..3eaa7a2c5fd 100644 --- a/.gitignore +++ b/.gitignore @@ -107,3 +107,5 @@ src/qrc_mudlet_alpha.cpp src/mac_src.pro.user* src/mudlet.app/* + +src/mudlet.dmg diff --git a/src/mac-deploy.sh b/src/mac-deploy.sh index 87af3b227ae..e162548d6d8 100755 --- a/src/mac-deploy.sh +++ b/src/mac-deploy.sh @@ -6,5 +6,6 @@ echo Copying Qt and dependent libraries... export PATH=$PATH:$HOME/Qt/5.1.1/clang_64/bin -echo $PATH +echo Using: $PATH to find macdeployqt sudo macdeployqt ./mudlet.app -dmg +echo Done! diff --git a/src/mac_src.pro b/src/mac_src.pro index 062626c1442..c9e8f6b68fb 100755 --- a/src/mac_src.pro +++ b/src/mac_src.pro @@ -15,7 +15,8 @@ QT += network opengl uitools multimedia cache() -# use pkg-config whenever possible +# use pkg-config whenever possible for linking on a mac +# the same should be done on the Linux platform as well macx { # http://stackoverflow.com/a/16972067 QT_CONFIG -= no-pkg-config @@ -23,7 +24,6 @@ macx { PKGCONFIG += hunspell lua yajl libpcre libzip } - macx:LIBS += \ # I didn't see an obvious pkg-config option for these two -lz \ @@ -254,6 +254,15 @@ unix: { fonts.files = fonts/ttf-bitstream-vera-1.10/* target.path = $$BIN_DIR } + +# Copy mudlet-lua into the .app bundle +macx: { + # the location is relative to mac_src.pro, so just use mudlet-lua + APP_MUDLET_LUA_FILES.files = mudlet-lua + APP_MUDLET_LUA_FILES.path = Contents/Resources + QMAKE_BUNDLE_DATA += APP_MUDLET_LUA_FILES +} + INSTALLS += fonts \ luaglobal \ documentation \