Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(59)

Side by Side Diff: tools/mirror-dev.sh

Issue 890613005: Land Ben's 32-bit symlink script. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 # For each installed *-dev package DEV
2 for DEV in $(dpkg --list | grep '^ii [^ ]' | cut -d ' ' -f 3 | grep '\-dev$')
3 do
4 # For each multi-arch *.so SO installed by DEV
5 for DEV_64_SO in $(dpkg -L $DEV | grep '/lib/x86_64-linux-gnu/.*\.so$')
6 do
7 # Skip if DEV_64_SO is not a symlink
8 if ! test -L $DEV_64_SO
9 then
10 echo "$DEV installed $DEV_64_SO which is real."
11 continue
12 fi
13
14 DEV_64_TARGET=$(readlink $DEV_64_SO)
15 DEV_64_TARGET_FULL=$(readlink -f $DEV_64_SO)
16
17 DEV_32_SO=$(echo $DEV_64_SO | sed -e 's@/lib/x86_64-linux-gnu/@/lib/i386 -linux-gnu/@')
18 DEV_32_TARGET=$(echo $DEV_64_TARGET | sed -e 's@/lib/x86_64-linux-gnu/@/ lib/i386-linux-gnu/@')
19 DEV_32_TARGET_FULL=$(echo $DEV_64_TARGET_FULL | sed -e 's@/lib/x86_64-li nux-gnu/@/lib/i386-linux-gnu/@')
20
21 # Error if DEV_32_TARGET does not exist.
22 if ! test -e $DEV_32_TARGET_FULL
23 then
24 DEV_64_TARGET_PKG=$(dpkg -S $DEV_64_TARGET_FULL | cut -d ':' -f 1)
25 echo "Could not find $DEV_32_TARGET_FULL, probably provided by $DEV_ 64_TARGET_PKG:i386."
26 #echo " $DEV_64_SO -> $DEV_64_TARGET ($DEV_64_TARGET_FULL)"
27 #echo " $DEV_32_SO -> $DEV_32_TARGET ($DEV_32_TARGET_FULL)"
28 continue
29 fi
30
31 # Create DEV_32_SO
32 sudo ln -s $DEV_32_TARGET $DEV_32_SO
33 done
34 done
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698