Mercurial > hg > sonic-visualiser
comparison deploy/linux/deploy-appimage.sh @ 1888:f8f3fa1b1286 appimage
Recursive dependencies
author | Chris Cannam |
---|---|
date | Wed, 27 Jun 2018 15:57:08 +0100 |
parents | 033fcd33e125 |
children | d8dfd30d6d41 |
comparison
equal
deleted
inserted
replaced
1887:e288e2f5914e | 1888:f8f3fa1b1286 |
---|---|
20 mkdir -p "$targetdir"/usr/bin | 20 mkdir -p "$targetdir"/usr/bin |
21 mkdir -p "$targetdir"/usr/lib | 21 mkdir -p "$targetdir"/usr/lib |
22 | 22 |
23 cp "$program" "$checker" "$piper" "$targetdir"/usr/bin/ | 23 cp "$program" "$checker" "$piper" "$targetdir"/usr/bin/ |
24 | 24 |
25 for lib in $(ldd "$program" | grep '=> /usr/lib/' | sed 's/^.*=> //' | sed 's/ .*$//'); do | 25 add_dependencies() { |
26 mkdir -p "$targetdir/$(dirname $lib)" | 26 local binary="$1" |
27 cp -L "$lib" "$targetdir/$lib" | 27 for lib in $(ldd "$binary" | grep '=> /usr/lib/' | sed 's/^.*=> //' | sed 's/ .*$//' | grep -v 'libc.so' | grep -v 'libm.so'); do |
28 done | 28 mkdir -p "$targetdir/$(dirname $lib)" |
29 if [ ! -f "$targetdir/$lib" ]; then | |
30 cp -Lv "$lib" "$targetdir/$lib" | |
31 chmod +x "$targetdir/$lib" | |
32 add_dependencies "$lib" | |
33 fi | |
34 done | |
35 } | |
36 | |
37 add_dependencies "$program" | |
29 | 38 |
30 cp "$program.desktop" "$targetdir/" | 39 cp "$program.desktop" "$targetdir/" |
31 | 40 |
32 cp "icons/sv-icon.svg" "$targetdir/" | 41 cp "icons/sv-icon.svg" "$targetdir/" |
33 | 42 |