When calling snap-seed-parse append stdout to file, but redirect

stderr to stdout, thus unbreak autopkgtests.
sil2100/raspi-wpasupplicant
Dimitri John Ledkov 6 years ago
parent 1e1c6a8572
commit 8868522e78

5
debian/changelog vendored

@ -1,8 +1,13 @@
livecd-rootfs (2.544) UNRELEASED; urgency=medium livecd-rootfs (2.544) UNRELEASED; urgency=medium
[ Steve Langasek ]
* Properly fix the hard-linking of vmlinuz, taken astray by my misguided * Properly fix the hard-linking of vmlinuz, taken astray by my misguided
merge review. merge review.
[ Dimitri John Ledkov ]
* When calling snap-seed-parse append stdout to file, but redirect
stderr to stdout, thus unbreak autopkgtests.
-- Steve Langasek <steve.langasek@ubuntu.com> Fri, 02 Nov 2018 14:46:30 -0700 -- Steve Langasek <steve.langasek@ubuntu.com> Fri, 02 Nov 2018 14:46:30 -0700
livecd-rootfs (2.543) disco; urgency=medium livecd-rootfs (2.543) disco; urgency=medium

@ -550,8 +550,9 @@ if [ "$PROJECT" = "ubuntu-touch" ] || [ "$PROJECT" = "ubuntu-touch-custom" ]; th
fi fi
# '--initramfs none' produces different manifest names. # '--initramfs none' produces different manifest names.
# NB! we want stdout appended to the manifest, yet stderr to be printed on stdout
if [ -e "binary/$INITFS/filesystem.packages" ]; then if [ -e "binary/$INITFS/filesystem.packages" ]; then
./config/snap-seed-parse "chroot/" >> "binary/${INITFS}/filesystem.packages" ./config/snap-seed-parse "chroot/" 2>&1 >> "binary/${INITFS}/filesystem.packages"
ln "binary/$INITFS/filesystem.packages" "$PREFIX.manifest" ln "binary/$INITFS/filesystem.packages" "$PREFIX.manifest"
chmod 644 "$PREFIX.manifest" chmod 644 "$PREFIX.manifest"
fi fi

@ -43,13 +43,14 @@ create_empty_disk_image() {
dd if=/dev/zero of="$1" bs=1 count=0 seek="${imagesize}" dd if=/dev/zero of="$1" bs=1 count=0 seek="${imagesize}"
} }
# NB! we want stdout appended to the manifest, yet stderr to be printed on stdout
create_manifest() { create_manifest() {
local chroot_root=${1} local chroot_root=${1}
local target_file=${2} local target_file=${2}
echo "create_manifest chroot_root: ${chroot_root}" echo "create_manifest chroot_root: ${chroot_root}"
dpkg-query --show --admindir="${chroot_root}/var/lib/dpkg" > ${target_file} dpkg-query --show --admindir="${chroot_root}/var/lib/dpkg" > ${target_file}
echo "create_manifest call to dpkg-query finished." echo "create_manifest call to dpkg-query finished."
./config/snap-seed-parse "${chroot_root}" >> ${target_file} ./config/snap-seed-parse "${chroot_root}" 2>&1 >> ${target_file}
echo "create_manifest call to snap_seed_parse finished." echo "create_manifest call to snap_seed_parse finished."
echo "create_manifest finished" echo "create_manifest finished"
} }

Loading…
Cancel
Save