-
Notifications
You must be signed in to change notification settings - Fork 2
/
ldscript.l
52 lines (42 loc) · 831 Bytes
/
ldscript.l
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
/*
MEMORY
{
vector : ORIGIN = 0xFFFF0000, LENGTH = 0x40
gbabios : ORIGIN = 0x4000, LENGTH = 0x4000
kernel : ORIGIN = 0x8000, LENGTH = 0x430000-0x8000
}
*/
SECTIONS
{
.text 0x00008000: {
__kernel_text_begin = .;
obj/handlers.o(.text)
*(EXCLUDE_FILE(obj/vector.o obj/bios.o obj/rom.o) .text .text.*)
. = ALIGN(0x1000);
__gbabios_begin = .;
obj/bios.o(.text)
__gbabios_end = .;
. = ALIGN(0x1000);
__gbarom_begin = .;
obj/rom.o(.text)
__gbarom_end = .;
. = ALIGN(0x1000);
__vectortable_begin = .;
obj/vector.o(.text)
__vectortable_end = .;
__kernel_text_end = .;
. = ALIGN(0x1000);
__kernel_data_begin = .;
}
.rodata __kernel_data_begin : {
*(.rodata .rodata.*)
}
.data : {
*(.data)
}
.bss : {
*(.bss)
}
__kernel_data_end = .;
__heap_begin = __kernel_data_end;
}