1
0
Fork 0
mirror of https://github.com/tailix/kernel.git synced 2024-10-30 12:03:52 -04:00
kernel/arch/linker.ld

35 lines
489 B
Text
Raw Normal View History

2017-11-03 22:22:09 -04:00
OUTPUT_ARCH("i386")
2017-11-01 00:43:42 -04:00
ENTRY(_start)
2017-11-04 06:19:53 -04:00
_kernel_offset = 0xC0000000; /* 3 GB */
2017-11-03 23:31:13 -04:00
2017-11-04 06:19:53 -04:00
_kernel_phys_base = 4M;
_kernel_virt_base = (_kernel_phys_base + _kernel_offset);
2017-11-03 23:31:13 -04:00
2017-11-01 00:43:42 -04:00
SECTIONS
{
2017-11-04 08:05:57 -04:00
. = _kernel_phys_base;
2017-11-01 00:43:42 -04:00
.text BLOCK(4K) : ALIGN(4K)
{
*(.multiboot)
2017-11-01 00:43:42 -04:00
*(.text)
}
.rodata BLOCK(4K) : ALIGN(4K)
{
*(.rodata)
}
.data BLOCK(4K) : ALIGN(4K)
{
*(.data)
}
.bss BLOCK(4K) : ALIGN(4K)
{
*(COMMON)
*(.bss)
}
}