--- dh_strip.orig 2010-04-26 11:15:12.000000000 +0000 +++ dh_strip 2010-08-31 16:24:55.510787197 +0000 @@ -84,15 +84,18 @@ # get set of all architecture dependent packages from debian/control packages=$( unset pkg - egrep '^(Package|Architecture):' debian/control | while read key val; do - if [ "$key" = Package: ]; then + egrep '^(Package|Architecture):' debian/control | while read line; do + key=${line%%:*}; + val1=${line##*:}; + val=${val1#"${val1%%[![:space:]]*}"} # strip leading spaces + if [ "$key" = Package ]; then [ -z "$pkg" ] || { echo "Error: Package: and Architecture: do not alternate in debian/control" >&2 exit 1 } pkg="$val" fi - if [ "$key" = Architecture: ]; then + if [ "$key" = Architecture ]; then [ -n "$pkg" ] || { echo "Error: Package: and Architecture: do not alternate in debian/control" >&2 exit 1