Mercurial > mplayer.hg
comparison TOOLS/binary_codecs.sh @ 32399:8f3293925a93
do not create a fake 'bestsites' if neither 'fping' or 'netselect' are installed
change developed by A Mennucc <mennucc1 [at] debian [dot] org>
author | siretart |
---|---|
date | Wed, 13 Oct 2010 15:09:24 +0000 |
parents | 68722c75c922 |
children | 6d06be50007f |
comparison
equal
deleted
inserted
replaced
32398:68722c75c922 | 32399:8f3293925a93 |
---|---|
41 grep $mainsite $PREFDIR/mirrors ; done ) > bestsites | 41 grep $mainsite $PREFDIR/mirrors ; done ) > bestsites |
42 else | 42 else |
43 echo "(If you install 'netselect' or 'fping', it will select the best mirror for you" | 43 echo "(If you install 'netselect' or 'fping', it will select the best mirror for you" |
44 echo " you may wish to stop this script and rerun after installation)" | 44 echo " you may wish to stop this script and rerun after installation)" |
45 sleep 3 | 45 sleep 3 |
46 head -3 mirrors > bestsites | |
47 fi | 46 fi |
48 fi | 47 fi |
49 } | 48 } |
50 | 49 |
51 | 50 |
60 if [ -r $filename ] ; then | 59 if [ -r $filename ] ; then |
61 cp $filename $filename.bak | 60 cp $filename $filename.bak |
62 fi | 61 fi |
63 | 62 |
64 if [ "$url" = @MAINSITE@ ] ; then | 63 if [ "$url" = @MAINSITE@ ] ; then |
65 cat $PREFDIR/bestsites | while read mainsite ; do | 64 list=$PREFDIR/bestsites |
65 test -r $list || list=$PREFDIR/mirrors | |
66 cat $list | while read mainsite ; do | |
66 echo Downloading $filename from $mainsite ... | 67 echo Downloading $filename from $mainsite ... |
67 wget -c -N $mainsite/$dir/$filename || true | 68 wget -c -N $mainsite/$dir/$filename || true |
68 if [ -r "$filename" ] ; then | 69 if [ -r "$filename" ] ; then |
69 UNPACK "$filename" | 70 UNPACK "$filename" |
70 return 0 | 71 return 0 |