rootstock hangs at "I: Extracting zlib1g..."
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
RootStock |
Fix Released
|
Undecided
|
Unassigned | ||
rootstock (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: rootstock
I am trying to build an ubuntu lucid beagleboard image, using the command:
sudo ../project-
it hangs with the last line of out put being
I: Extracting zlib1g...
if i control+c i get:
I: Extracting zlib1g...
^C../project-
I: Cleaning up...
if i run with "bash -x" i get
+ read line
+ echo I: Extracting zlib1g...
+ '[' '!' '' ']'
+ echo 'I: Extracting zlib1g...'
I: Extracting zlib1g...
+ read line
+ '[' 1 ']'
+ mkdir -p /var/cache/
+ cp /tmp/tmp.
++ which qemu-arm-static
+ '[' '!' ']'
+ SECOND_
+ echo 3975
^C../project-
++ cleanup
++ echo 'I: Cleaning up...'
I: Cleaning up...
++ echo 'I: Killed ... '
++ '[' -e /tmp/tmp.
+++ cat /tmp/tmp.
++ DPID=3975
++ kill -9 3975
i have seen this discussed in IRC, but can't find a resolution or bug report. I am running the latest rootstock via bzr, and up to date lucid on amd64.
Changed in project-rootstock: | |
status: | New → Fix Committed |
i think the following code is responsible:
if [ ! $(which qemu-arm-static) ];then
SECOND_ STAGE=" /debootstrap/ debootstrap --second-stage" usr/bin/ usr/bin/ debootstrap --second-stage >$DBFIFO 2>&1 &
SECOND_ STAGE=" "
else
mkdir -p $MOUNTPOINT/
cp $(which qemu-arm-static) $MOUNTPOINT/
chroot $MOUNTPOINT debootstrap/
fi
if i install qemu-kvm- extras- static to have qemu-arm-static, then i can get past the hang. the difference between the 2 paths is that only the second sets something to feed into the FIFO. after the if statement is a loop to read from the FIFO. if the fist path is followed then the read loop waits for ever.
the simplest fix is to move the read loop inside the else block. i shall attach a patch
i am not sure why the FIFO is used instead of tee.