1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
Author: Ludwin Janvier <lud.janvier@gmail.com>
Description: When using the GPGKEY option, aptitude don't trust the repository
and apt-get simply ignore the repo. Sounds that because the master Release
doesn't contain the md5 for uncompressed "Packages" file.
Bug-Debian: http://bugs.debian.org/439341
Index: apt-move/apt-move
===================================================================
--- apt-move.orig/apt-move 2012-01-08 02:43:20.581649493 +0800
+++ apt-move/apt-move 2012-01-08 02:45:29.269077804 +0800
@@ -1246,14 +1246,25 @@
}
get_checksum() {
- for l; do
- [ -f $l ] || continue
- size=$(perl -le 'print ((stat($ARGV[0]))[7]);' $l)
- printf ' %32s%.s %16d %s\n' \
- $(md5sum $l) $size $j/$k/$l
- printf ' %40s%.s %16d %s\n' \
- $(sha1sum $l) $size $j/$k/$l >&3
- done
+ local cont
+ for l; do
+ if [ -f $l ]; then
+ cont='cat '$l
+ else
+ if [ -f $l'.gz' ]; then
+ cont='zcat '$l'.gz'
+ elif [ -f $1'.bz' ]; then
+ cont='bzcat '$1'.bz'
+ else
+ continue
+ fi
+ fi
+ size=$($cont | wc -c)
+ printf ' %32s%.s %16d %s\n' \
+ $($cont|md5sum) $size $j/$k/$l
+ printf ' %40s%.s %16d %s\n' \
+ $($cont|sha1sum) $size $j/$k/$l >&3
+ done
}
make_release() {
|