On 3/11/06, Andreas Schwab <[EMAIL PROTECTED]> wrote:
> "Anderson Lizardo" <[EMAIL PROTECTED]> writes:
>
> > Any reason why the magic numbers from qemu-binfmt-conf.sh are not just
> > 16 bytes long as those reported by "readelf --file-header"? For
> > example:
> >
> > $ readelf --file-header /bin/true | grep Magic:
> >   Magic:   7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
> >
> > Using only the first 16 bytes avoids the need to have separate entries
> > for i386 and i486, given that they are emulated by the same program
> > (qemu-i386).
>
> How would you distinguish it from an arm or mipsel binary?
Now I realize my mistake, sorry for the noise :/

To not make this thread completely useless: I find
/usr/share/misc/file/magic very useful to get machine patterns (as
detected by "file"). Search there for "magic for ELF executables" and
you will find a fairly complete list of machine magic numbers.

Regards,
--
Anderson Lizardo
Embedded Linux Lab - 10LE
Nokia Institute of Technology - INdT
Manaus - Brazil


_______________________________________________
Qemu-devel mailing list
Qemu-devel@nongnu.org
http://lists.nongnu.org/mailman/listinfo/qemu-devel

Reply via email to