diff options
author | dzwdz | 2022-07-11 21:54:51 +0200 |
---|---|---|
committer | dzwdz | 2022-07-11 21:54:51 +0200 |
commit | 2e79a2e5af3affa7a6a3becdffb1c91d89af90af (patch) | |
tree | c253761c4ec010ad14b08f9ee8dfc1a50411b30f /src/user/linker.ld | |
parent | 6c01d9a7e34e1fccc2775b0e2187ac5e50dd4392 (diff) |
user: reorganize the userland sources
Diffstat (limited to 'src/user/linker.ld')
-rw-r--r-- | src/user/linker.ld | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/user/linker.ld b/src/user/linker.ld new file mode 100644 index 0000000..f2c9d24 --- /dev/null +++ b/src/user/linker.ld @@ -0,0 +1,31 @@ +ENTRY(main) +OUTPUT_FORMAT("binary") + +SECTIONS +{ + . = 2M; + .text BLOCK(4K) : ALIGN(4K) + { + *(.text.startup) + *(.text) + } + .rodata BLOCK(4K) : ALIGN(4K) + { + *(.rodata) + } + .data BLOCK(4K) : ALIGN(4K) + { + *(.data) + } + + _initrd = .; /* is just appended onto the end of the binary */ + . += 2M; + + _bss_start = .; + .bss BLOCK(4K) : ALIGN(4K) + { + *(COMMON) + *(.bss) + } + _bss_end = .; +} |