|
|
@ -2031,11 +2031,16 @@ sub main() {
|
|
|
|
close $fh;
|
|
|
|
close $fh;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
{
|
|
|
|
{
|
|
|
|
open my $fh, '-|', '/usr/sbin/update-binfmts', '--display', "qemu-$options->{qemu}" // error "failed to fork(): $!";
|
|
|
|
if (!exists $deb2qemu->{$nativearch}) {
|
|
|
|
chomp (my $binfmts = do { local $/; <$fh> });
|
|
|
|
warning "no mapping from $nativearch to qemu-user binary";
|
|
|
|
close $fh;
|
|
|
|
} else {
|
|
|
|
if ($binfmts eq '') {
|
|
|
|
my $binfmt_identifier = 'qemu-' . $deb2qemu->{$nativearch};
|
|
|
|
warning "qemu-$options->{qemu} is not a supported binfmt name";
|
|
|
|
open my $fh, '-|', '/usr/sbin/update-binfmts', '--display', $binfmt_identifier // error "failed to fork(): $!";
|
|
|
|
|
|
|
|
chomp (my $binfmts = do { local $/; <$fh> });
|
|
|
|
|
|
|
|
close $fh;
|
|
|
|
|
|
|
|
if ($binfmts eq '') {
|
|
|
|
|
|
|
|
warning "$binfmt_identifier is not a supported binfmt name";
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
error "qemu user emulation of $nativearch using binfmt_misc failed";
|
|
|
|
error "qemu user emulation of $nativearch using binfmt_misc failed";
|
|
|
|