Code: Select all
ENTRY(start)
STARTUP(bootldr_s2.s.o)
OUTPUT_FORMAT("binary_i386?") /* Biggest isue here */
SECTIONS
{
.text.start (_KERNEL_BASE_) : { /* I change this to 0x0000, right? */
bootldr_s2.s.o( .text )
}
.text : ALIGN(0x1000) {
_TEXT_START_ = .;
*(.text)
_TEXT_END_ = .;
}
.data : ALIGN(0x1000) {
_DATA_START_ = .;
*(.data)
_DATA_END_ = .;
}
.bss : ALIGN(0x1000) {
_BSS_START_ = .;
*(.bss)
_BSS_END_ = .;
}
}
Code: Select all
ld: skipping incompatible bootldr_s2.s.o when searching for bootldr_s2.s.o
ld: cannot find bootldr_s2.s.o
Code: Select all
nasm -f elf -o bootldr_s2.s.o
Code: Select all
BITS 16
start:
mov eax, 0xBCAF ;If this is in eax, then the code loaded
jmp $