Page 1 of 1

GRUB

Posted: Wed Oct 19, 2005 9:08 am
by Vladaz
Hello again ;D
When I try to load my OS using GRUB, it says:

Error 13: Invalid or unsupported executable format

Does there has to be some code(multiboot header) in my kernel? If it does, what code does there has to be? I'm using NASM for my kernel.asm, and from kernel.asm I jump to C code(kernel.c).
And does my linker file(ld) will has to be changed as well?

Thanks :)

Re:GRUB

Posted: Wed Oct 19, 2005 9:09 am
by Vladaz
And there's one more question:
Can my compiled and linked kernel be kernel.bin, not ELF or anything else? Or is it better to use ELF or anything else?

Re:GRUB

Posted: Wed Oct 19, 2005 1:32 pm
by Solar
Please read the Multiboot specification, then check the FAQ Wiki, especially the page "Bare Bones".

Re:GRUB

Posted: Wed Oct 19, 2005 1:44 pm
by Warrior
You are using an executable format not accepted by grub. Try the ELF format or a.out using the aout kludge.

Re:GRUB

Posted: Thu Oct 20, 2005 2:46 am
by Candy
Nelson wrote: You are using an executable format not accepted by grub. Try the ELF format or a.out using the aout kludge.
The point of the a.out kludge (or multiboot header) is that you can boot any file type, not just those known by whatever your boot loader is.