annotate deploy/osx/copy-qt.sh @ 1231:b4fd38b40712 spectrogram-minor-refactor

Fix threshold in spectrogram -- it wasn't working in the last release. There is a new protocol for this. Formerly the threshold parameter had a range from -50dB to 0 with the default at -50, and -50 treated internally as "no threshold". However, there was a hardcoded, hidden internal threshold for spectrogram colour mapping at -80dB with anything below this being rounded to zero. Now the threshold parameter has range -81 to -1 with the default at -80, -81 is treated internally as "no threshold", and there is no hidden internal threshold. So the default behaviour is the same as before, an effective -80dB threshold, but it is now possible to change this in both directions. Sessions reloaded from prior versions may look slightly different because, if the session says there should be no threshold, there will now actually be no threshold instead of having the hidden internal one. Still need to do something in the UI to make it apparent that the -81dB setting removes the threshold entirely. This is at least no worse than the previous, also obscured, magic -50dB setting.
author Chris Cannam
date Mon, 01 Aug 2016 16:21:01 +0100
parents 1e63105fc82d
children 2451e7bb90af
rev   line source
Chris@745 1 #!/bin/bash
Chris@745 2
Chris@1055 3 set -eu
Chris@1055 4
Chris@745 5 app="$1"
Chris@745 6 if [ -z "$app" ]; then
Chris@745 7 echo "Usage: $0 <appname>"
Chris@745 8 echo "Provide appname without the .app extension, please"
Chris@745 9 exit 2
Chris@745 10 fi
Chris@745 11
Chris@1082 12 frameworks="QtCore QtNetwork QtGui QtXml QtSvg QtWidgets QtPrintSupport QtDBus"
Chris@745 13
Chris@1153 14 plugins="dds gif icns ico jpeg tga tiff wbmp webp cocoa minimal offscreen"
Chris@745 15
Chris@745 16 qtdir=$(grep "Command:" Makefile | head -1 | awk '{ print $3; }' | sed s,/bin/.*,,)
Chris@745 17
Chris@745 18 if [ ! -d "$qtdir" ]; then
Chris@745 19 echo "Failed to discover Qt installation directory from Makefile, exiting"
Chris@745 20 exit 2
Chris@745 21 fi
Chris@745 22
Chris@745 23 fdir="$app.app/Contents/Frameworks"
Chris@745 24 pdir="$app.app/Contents/plugins"
Chris@745 25
Chris@745 26 mkdir -p "$fdir"
Chris@745 27 mkdir -p "$pdir"
Chris@745 28
Chris@745 29 echo
Chris@745 30 echo "Copying frameworks..."
Chris@745 31 for fwk in $frameworks; do
Chris@745 32 cp -v "$qtdir/lib/$fwk.framework/$fwk" "$fdir" || exit 2
Chris@745 33 done
Chris@745 34
Chris@745 35 echo "Done"
Chris@745 36
Chris@745 37 echo
Chris@745 38 echo "Copying plugins..."
Chris@745 39 for plug in $plugins; do
Chris@772 40 pfile=$(ls "$qtdir"/plugins/*/libq"$plug".dylib)
Chris@745 41 if [ ! -f "$pfile" ]; then
Chris@745 42 echo "Failed to find plugin $plug, exiting"
Chris@745 43 exit 2
Chris@745 44 fi
Chris@772 45 target="$pdir"/${pfile##?*plugins/}
Chris@772 46 tdir=`dirname "$target"`
Chris@772 47 mkdir -p "$tdir"
Chris@772 48 cp -v "$pfile" "$target" || exit 2
Chris@745 49 done
Chris@745 50
Chris@745 51 echo "Done"
Chris@745 52
Chris@772 53