source: target downloads with corresponding version

Prefer downloading the version of the source package that actually
corresponds to the version of the binary. Should apt-update be
run and a package updated, we do not really want to fetch a newer
copy of the source than that of the binary, we want the exact
corresponding version (kinda the whole point of compiling a source
disc that they correspond). If the exact version is no longer
available then it is surely preferable to list it in the missing
list than end up with a newer version.

Gbp-Dch: Short
Closes: #952932
This commit is contained in:
jnqnfe 2014-12-02 01:48:28 +00:00 committed by Luca Boccassi
parent f1647f0dac
commit 87e9543c98
1 changed files with 9 additions and 1 deletions

View File

@ -46,7 +46,15 @@ then
fi
# Download sources
Chroot chroot "dpkg --get-selections" | awk '{ print $1 }' > source-selection.txt
cat >> chroot/source-selection.sh << EOF
#!/bin/sh
dpkg-query -W -f='\${binary:Package}=\${Version}\n' > source-selection.txt
EOF
Chroot chroot "sh source-selection.sh"
rm -f chroot/source-selection.sh
mv chroot/source-selection.txt ./
echo "${LB_BOOTLOADERS}" | \
while IFS="," read -r BOOTLOADER