Thanks for the quick answer!!

> > Looks like the registration of file formats is somehow broken
> 
> We had this already, there was similar bug.
> Does the prob persist when you just re-install qemu-user-static
> package using dpkg (without removing it first)?  The question
> here is that update-binfmt does not refresh changed definitions
> at the first run.
Guess not - just before reporting the bug I upgraded to the latest 
experimental version, so there should've been a reinstall just before.

> > # file debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1
> >     debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1: ELF 
> > 64-bit LSB executable, 64-bit PowerPC or cisco 7500, version 1 (GNU/Linux), 
> > dynamically linked, interpreter /lib64/ld64.so.2, for GNU/Linux 2.6.32, 
> > BuildID[sha1]=3bea2777c40886422ecd521a04141dbeeb194afb, stripped
> > # objdump -f debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1
> >     
> >     debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1:     
> > file format elf64-little
> >     architecture: UNKNOWN!, flags 0x00000112:
> >     EXEC_P, HAS_SYMS, D_PAGED
> >     start address 0x0000000010117ec8
> 
> Please dump first 64 bytes of the executable using hexdump -C --
> hexdump -C -l 64 
> debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1
> 
> (64bytes is a bit more than needed, but I don't have elf header layout
> handy and don't remember the size needed).  Interesting is that it says
> architecture is unknown.
Needed "-n" instead of "-l", but I guess that's what you want:

# hexdump -C -n 64 
debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1.debian-bug
00000000  7f 45 4c 46 02 01 01 03  00 00 00 00 00 00 00 00  |.ELF............|
00000010  02 00 15 00 01 00 00 00  c8 7e 11 10 00 00 00 00  |.........~......|
00000020  40 00 00 00 00 00 00 00  50 05 06 01 00 00 00 00  |@.......P.......|
00000030  02 00 00 00 40 00 38 00  09 00 40 00 1f 00 1e 00  |....@.8...@.....|
00000040


I worked around that for now via
    # cat debian-jessie-ppc64el/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1
    #!/bin/bash

    shift
    /usr/bin/qemu-ppc64le-static 
/usr/lib/gcc/powerpc64le-linux-gnu/4.9/cc1.debian-bug "$@"

Reply via email to