summaryrefslogtreecommitdiff
path: root/config/kernel.ld
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2025-04-08 10:39:48 -0400
committerFreya Murphy <freya@freyacat.org>2025-04-08 10:39:48 -0400
commit8a19547957a86bed3f58c9abc1ac218d04698faf (patch)
treeed7ccc6f3a8902915dfe6c9bf763fc45d752b3c4 /config/kernel.ld
parentfmt (diff)
downloadcomus-8a19547957a86bed3f58c9abc1ac218d04698faf.tar.gz
comus-8a19547957a86bed3f58c9abc1ac218d04698faf.tar.bz2
comus-8a19547957a86bed3f58c9abc1ac218d04698faf.zip
break apart c libaray
Diffstat (limited to 'config/kernel.ld')
-rw-r--r--config/kernel.ld36
1 files changed, 36 insertions, 0 deletions
diff --git a/config/kernel.ld b/config/kernel.ld
new file mode 100644
index 0000000..0806257
--- /dev/null
+++ b/config/kernel.ld
@@ -0,0 +1,36 @@
+ENTRY(_start)
+
+SECTIONS
+{
+ . = 1M;
+
+ kernel_start = .;
+
+ . = ALIGN(0x1000);
+
+ .text : {
+ *(.multiboot)
+ *(.text)
+ }
+
+ . = ALIGN(0x1000);
+
+ .rodata : {
+ *(.rodata)
+ }
+
+ . = ALIGN(0x1000);
+
+ .data : {
+ *(.data)
+ }
+
+ . = ALIGN(0x1000);
+
+ .bss : {
+ *(COMMON)
+ *(.bss)
+ }
+
+ kernel_end = .;
+}