Mercurial > hg > easyhg
diff deploy/linux/debian-dependencies.sh @ 728:1d0a0fce4021
Include dependencies for all targets
author | Chris Cannam |
---|---|
date | Mon, 17 Dec 2018 09:45:34 +0000 |
parents | 665da28f1da8 |
children |
line wrap: on
line diff
--- a/deploy/linux/debian-dependencies.sh Mon Dec 17 09:35:14 2018 +0000 +++ b/deploy/linux/debian-dependencies.sh Mon Dec 17 09:45:34 2018 +0000 @@ -1,12 +1,19 @@ #!/bin/bash -target=$1 +targets="$@" -if [ ! -f "$target" ]; then +if [ t"$targets" = "" ]; then echo "Usage: $0 target-executable" - exit 1 + exit 2 fi +for target in $targets ; do + if [ ! -f "$target" ]; then + echo "Error: target executable ./$target not found" + exit 1 + fi +done + set -eu pfile=/tmp/packages_$$ @@ -15,7 +22,7 @@ trap "rm -f $pfile $rfile" 0 echo 1>&2 -ldd "$target" | awk '{ print $3; }' | grep '^/' | while read lib; do +ldd $targets | awk '{ print $3; }' | grep '^/' | while read lib; do if test -n "$lib" ; then dpkg-query -S "$lib" fi