tags 360058 + patch fixed-upstream pending
thanks

Martin Michlmayr <[EMAIL PROTECTED]> writes:

> sbuild assumes that the ref-* file is sorted.  It would be nice if
> this wasn't the case.

The attached patch has been applied to fix this problem.


Regards,
Roger

-- 
Roger Leigh
                Printing on GNU/Linux?  http://gutenprint.sourceforge.net/
                Debian GNU/Linux        http://www.debian.org/
                GPG Public Key: 0x25BFB848.  Please sign and encrypt your mail.
Index: debian/changelog
===================================================================
--- debian/changelog	(revision 515)
+++ debian/changelog	(working copy)
@@ -3,6 +3,9 @@
   * sbuild:
     - Treat schroot chroots with a "-sbuild" suffix in the same way as
       chroots without a suffix (Closes: #360124).
+  * bin/checkchroot:
+    - Quote all variables.
+    - Sort ref-chroot file before diffing (Closes: 360058).
 
  --
 
Index: bin/checkchroot
===================================================================
--- bin/checkchroot	(revision 514)
+++ bin/checkchroot	(working copy)
@@ -13,20 +13,20 @@
 . /usr/share/sbuild/common_functions
 parse_arg $1
 
-tfile=$(tempfile)
+tfile1="$(tempfile)"
+tfile2="$(tempfile)"
 
-# NOTE: v. 1.10.x "dpkg --root" is broken, so use grep-status
-#COLUMNS=200 dpkg 2>/dev/null --list | grep ^ii | awk '{print $2}' >$tfile
+grep-status -F Status -s Package ' installed' "$CHROOT/var/lib/dpkg/status" | awk '{print $2}' | sort >"$tfile1"
 
-grep-status -F Status -s Package ' installed' $CHROOT/var/lib/dpkg/status | awk '{print $2}' | sort >$tfile
+sort "$CHROOT/../ref-$DIST" >"$tfile2"
 
 echo "DELETE             ADD"
 echo "============================"
-diff -u $tfile $CHROOT/../ref-$DIST |
+diff -u "$tfile1" "$tfile2" |
 	tail -n +3 |
 	grep ^[+-] |
 	sed -e 's/^-//' -e "s/^+/                   /" |
 	sort
 
-rm -f $tfile
+rm -f "$tfile1" "$tfile2"
 

Reply via email to