annotate deploy/linux/debian-dependencies.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 c977df9da61e
children a901eff2acaf
rev   line source
Chris@378 1 #!/bin/bash
Chris@378 2
Chris@378 3 target=$1
Chris@378 4
Chris@378 5 if [ ! -f "$target" ]; then
Chris@378 6 echo "Usage: $0 target-executable"
Chris@378 7 exit 1
Chris@378 8 fi
Chris@378 9
Chris@378 10 pfile=/tmp/packages_$$
Chris@378 11 rfile=/tmp/redundant_$$
Chris@378 12
Chris@378 13 trap "rm -f $pfile $rfile" 0
Chris@863 14 echo 1>&2
Chris@378 15
Chris@460 16 ldd "$target" | awk '{ print $3; }' | grep '^/' | while read lib; do
Chris@378 17 if test -n "$lib" ; then
Chris@378 18 dpkg-query -S "$lib"
Chris@378 19 fi
Chris@378 20 done | grep ': ' | awk -F: '{ print $1 }' | sort | uniq > $pfile
Chris@378 21
Chris@863 22 echo "Packages providing required libraries:" 1>&2
Chris@863 23 cat $pfile 1>&2
Chris@863 24 echo 1>&2
Chris@378 25
Chris@378 26 for p in `cat $pfile`; do
Chris@460 27 echo Looking at $p 1>&2
Chris@378 28 apt-cache showpkg "$p" | grep '^ ' | grep ',' | awk -F, '{ print $1; }' | \
Chris@378 29 while read d; do
Chris@378 30 if grep -q '^'$d'$' $pfile; then
Chris@865 31 echo $p
Chris@378 32 fi
Chris@378 33 done
Chris@378 34 done | sort | uniq > $rfile
Chris@378 35
Chris@863 36 echo "Packages that can be eliminated because other packages depend on them:" 1>&2
Chris@863 37 cat $rfile 1>&2
Chris@863 38 echo 1>&2
Chris@378 39
Chris@1081 40 cat $pfile $rfile | sort | uniq -u | sed 's/$/,/' | fmt -1000 | sed 's/^/Depends: /' | sed 's/,$/, libc6/' | sed 's/libjack0,/jackd,/'
Chris@378 41
Chris@863 42