Commit f432a2da24749a1c2bcddd9ff71e90fda2311640

Authored by Peter Zhigalov
1 parent 0555c550

Доработал деплой-скрипты для OS X

buildscripts/osx_qt4.8.7_clang64.sh 0 → 100755
  1 +#!/bin/bash
  2 +V_PROJECT=fem_draw_qt
  3 +V_BUILDDIR=build_osx_qt4.8.7_clang64
  4 +V_APPNAME="FEM Draw"
  5 +V_DMGNAME="fem_draw_qt"
  6 +V_INFO_PLIST="resources/Info.plist"
  7 +V_ICON="resources/fem_draw.icns"
  8 +
  9 +CMD_QMAKE="qmake"
  10 +CMD_DEPLOY="macdeployqt"
  11 +
  12 +cd "$(dirname $0)"/..
  13 +rm -rf "${V_BUILDDIR}"
  14 +mkdir -p "${V_BUILDDIR}"
  15 +cd "${V_BUILDDIR}"
  16 +${CMD_QMAKE} CONFIG+="release" CONFIG+="x86_64" -r -spec unsupported/macx-clang QMAKE_MACOSX_DEPLOYMENT_TARGET=10.5 "../${V_PROJECT}.pro"
  17 +make
  18 +cp -a "../${V_INFO_PLIST}" "${V_APPNAME}.app/Contents/Info.plist"
  19 +sed -e 's/10.7/10.5/' -i "" "${V_APPNAME}.app/Contents/Info.plist"
  20 +cp -a "../${V_ICON}" "${V_APPNAME}.app/Contents/Resources/"
  21 +${CMD_DEPLOY} "${V_APPNAME}.app" -dmg -verbose=2
  22 +
  23 +hdiutil convert -format UDRW -o "${V_APPNAME}_rw.dmg" "${V_APPNAME}.dmg"
  24 +mkdir "${V_APPNAME}_rw_mount"
  25 +hdiutil attach -mountpoint "${V_APPNAME}_rw_mount" -noautoopen "${V_APPNAME}_rw.dmg"
  26 +cd "${V_APPNAME}_rw_mount"
  27 +ln -s /Applications ./Applications
  28 +cd ..
  29 +hdiutil detach "${V_APPNAME}_rw_mount"
  30 +hdiutil convert -format UDRO -o "${V_APPNAME}_ro.dmg" "${V_APPNAME}_rw.dmg"
  31 +cp "${V_APPNAME}_ro.dmg" ../"${V_DMGNAME}.dmg"
  32 +
... ...
buildscripts/osx_qt5.3.2_clang64.sh 0 → 100755
  1 +#!/bin/bash
  2 +V_PROJECT=fem_draw_qt
  3 +V_BUILDDIR=build_osx_qt5.3.0_clang64
  4 +V_APPNAME="FEM Draw"
  5 +V_DMGNAME="fem_draw_qt"
  6 +
  7 +QTDIR="${HOME}/Qt/5.3/clang_64"
  8 +CMD_QMAKE="${QTDIR}/bin/qmake"
  9 +CMD_DEPLOY="${QTDIR}/bin/macdeployqt"
  10 +
  11 +cd "$(dirname $0)"/..
  12 +rm -rf "${V_BUILDDIR}"
  13 +mkdir -p "${V_BUILDDIR}"
  14 +cd "${V_BUILDDIR}"
  15 +${CMD_QMAKE} CONFIG+="release" QMAKE_MACOSX_DEPLOYMENT_TARGET=10.6 "../${V_PROJECT}.pro"
  16 +make
  17 +sed -e 's/10.7/10.6/' -i "" "${V_APPNAME}.app/Contents/Info.plist"
  18 +${CMD_DEPLOY} "${V_APPNAME}.app" -dmg -verbose=2
  19 +
  20 +hdiutil convert -format UDRW -o "${V_APPNAME}_rw.dmg" "${V_APPNAME}.dmg"
  21 +mkdir "${V_APPNAME}_rw_mount"
  22 +hdiutil attach -mountpoint "${V_APPNAME}_rw_mount" -noautoopen "${V_APPNAME}_rw.dmg"
  23 +cd "${V_APPNAME}_rw_mount"
  24 +ln -s /Applications ./Applications
  25 +cd ..
  26 +hdiutil detach "${V_APPNAME}_rw_mount"
  27 +hdiutil convert -format UDRO -o "${V_APPNAME}_ro.dmg" "${V_APPNAME}_rw.dmg"
  28 +cp "${V_APPNAME}_ro.dmg" ../"${V_DMGNAME}.dmg"
  29 +
... ...
buildscripts/osx_qt5.6.0_clang64.sh
1 1 #!/bin/bash
2 2 V_PROJECT=fem_draw_qt
3   -QTDIR=/Applications/Qt/5.6/clang_64
4 3 V_BUILDDIR=build_osx_qt5.6.0_clang64
5 4 V_APPNAME="FEM Draw"
  5 +V_DMGNAME="fem_draw_qt"
  6 +
  7 +QTDIR="${HOME}/Qt/5.6/clang_64"
  8 +CMD_QMAKE="${QTDIR}/bin/qmake"
  9 +CMD_DEPLOY="${QTDIR}/bin/macdeployqt"
6 10  
7 11 cd "$(dirname $0)"/..
8 12 rm -rf "${V_BUILDDIR}"
9 13 mkdir -p "${V_BUILDDIR}"
10 14 cd "${V_BUILDDIR}"
11   -"${QTDIR}"/bin/qmake CONFIG+="release" QMAKE_MACOSX_DEPLOYMENT_TARGET=10.7 "../${V_PROJECT}.pro"
  15 +${CMD_QMAKE} CONFIG+="release" QMAKE_MACOSX_DEPLOYMENT_TARGET=10.7 "../${V_PROJECT}.pro"
12 16 make
13   -"${QTDIR}"/bin/macdeployqt "${V_APPNAME}.app" -dmg -verbose=2
  17 +${CMD_DEPLOY} "${V_APPNAME}.app" -dmg -verbose=2
14 18  
15 19 hdiutil convert -format UDRW -o "${V_APPNAME}_rw.dmg" "${V_APPNAME}.dmg"
16 20 mkdir "${V_APPNAME}_rw_mount"
... ... @@ -20,5 +24,5 @@ ln -s /Applications ./Applications
20 24 cd ..
21 25 hdiutil detach "${V_APPNAME}_rw_mount"
22 26 hdiutil convert -format UDRO -o "${V_APPNAME}_ro.dmg" "${V_APPNAME}_rw.dmg"
23   -cp "${V_APPNAME}_ro.dmg" ../"${V_APPNAME}.dmg"
  27 +cp "${V_APPNAME}_ro.dmg" ../"${V_DMGNAME}.dmg"
24 28  
... ...
fem_draw_qt.pro
... ... @@ -47,6 +47,7 @@ macx {
47 47 QMAKE_INFO_PLIST = resources/Info.plist
48 48 ICON = resources/fem_draw.icns
49 49 TARGET = "FEM Draw"
  50 + QMAKE_CXXFLAGS += -Wno-invalid-constexpr
50 51 }
51 52  
52 53 *g++*|*clang* {
... ...
resources/Info.plist
... ... @@ -33,7 +33,7 @@
33 33 <string>x86_64</string>
34 34 </array>
35 35 <key>LSMinimumSystemVersion</key>
36   - <string>10.7.0</string>
  36 + <string>10.7</string>
37 37 <key>NSHumanReadableCopyright</key>
38 38 <string>Copyright (c) 2014-2016, Peter Zhigalov</string>
39 39 <key>CFBundleDocumentTypes</key>
... ...