aarch64: drop hardcoding start.o in favor of having a text section

This resolves the current compiling issue of multiple definitions,
since arch/built-in.o is included in makefile.
This commit is contained in:
Ivaylo Ivanov committed 2025-07-09 11:42:19 +03:00
1 parent 850ba48539
commit 4763355d48
1 file changed
+21 -9
+21 -9
View File
@@ -3,6 +3,8 @@
* Copyright (c) 2022, Ivaylo Ivanov <ivo.ivanov.ivanov1@gmail.com>
*/
ENTRY(_start);
OUTPUT_FORMAT("elf64-littleaarch64")
OUTPUT_ARCH(aarch64)
TARGET(binary)
@@ -13,18 +15,28 @@ INPUT(RAMDISK_PATH)
SECTIONS
{
.boot : {
arch/aarch64/start.o
}
.text ALIGN(4096) : {
.text : {
KEEP(*(.text.start))
*(.text)
*(.text.*)
}
.bss ALIGN(4096) : {
_bss_start = .;
. = . + 4096;
_bss_end = .;
.rodata ALIGN(4) : {
*(.rodata)
*(.rodata.*)
}
.data ALIGN(4) : {
*(.data)
*(.data.*)
}
.bss ALIGN(4) : {
__bss_start = .;
*(.bss)
*(.bss.*)
*(COMMON)
__bss_end = .;
}
.stack ALIGN(4096) : {