]> sigrok.org Git - sigrok-util.git/blobdiff - cross-compile/macosx/create_dmg
macosx: Hardcode the Qt version to 5.5 for now.
[sigrok-util.git] / cross-compile / macosx / create_dmg
index 7b4b12c73ca6c725339a8836f381179aad8d4451..f4b36b71c2f5fb871d37aef5c62030feee32882a 100755 (executable)
@@ -26,8 +26,11 @@ PREFIX=$HOME/sr_macosx
 # The path where to download files to and where to build packages.
 BUILDDIR=./build_app
 
+# We use Qt 5.5 in order to remain compatible with more versions of Mac OS X.
+QTVER=qt@5.5
+
 # Path to Qt5 binaries.
-QTBINDIR=`brew list qt5 | grep bin | head -n 1 | xargs dirname`
+QTBINDIR=`brew list $QTVER | grep bin | head -n 1 | xargs dirname`
 
 # Path to boost libraries.
 BOOSTLIBDIR=`brew list boost | grep libboost_system | head -n 1 | xargs dirname`
@@ -35,7 +38,7 @@ BOOSTLIBDIR=`brew list boost | grep libboost_system | head -n 1 | xargs dirname`
 # Path to Python 3 framework.
 PYTHONFRAMEWORKDIR=`brew list python3 | grep Python.framework | head -n 1 | xargs dirname`/../../../..
 
-PYVER="3.6"
+PYVER="3.7"
 
 # You usually don't need to change anything below this line.
 
@@ -92,11 +95,11 @@ rm -rf $PYDIR/lib/python$PYVER/**/__pycache__
 rm -rf $PYDIR/lib/python$PYVER/**/**/__pycache__
 rm -rf $PYDIR/Resources
 install_name_tool -change \
-       /usr/local/opt/python3/Frameworks/Python.framework/Versions/$PYVER/Python \
+       /usr/local/opt/python/Frameworks/Python.framework/Versions/$PYVER/Python \
        @executable_path/../Frameworks/Python.framework/Versions/$PYVER/Python \
        $FRAMEWORKSDIR/libsigrokdecode.*.dylib
 
-# Add PulseView wrapper script that sets PYTHONHOME and SIGROKDECODE_DIR.
+# Add PulseView wrapper (sets PYTHONHOME/SIGROK_FIRMWARE_DIR/SIGROKDECODE_DIR).
 mv $MACOSDIR/$APPNAME_BINARY $MACOSDIR/$APPNAME_BINARY.real
 cp ../contrib/pulseview $MACOSDIR
 chmod 755 $MACOSDIR/$APPNAME_BINARY