unleashed-firmware/firmware/targets/f7/application-ext.ld
David Coles a6b98ccbbe
Preliminary Rust support (#1781)
* Add support for R_ARM_THM_MOVW_ABS_NC/THM_MOVT_ABS

These are sometimes emitted by the Rust LLVM compiler.

Ref: https://github.com/ARM-software/abi-aa/blob/main/aaelf32/aaelf32.rst#56relocation

* Discard LLVM bitcode from extension applications

LLVM-based compilers may include uncompressed bitcode in object files
to help with link-time optimization. However this can bloat binary sizes
from KB to MB.

* Expose alligned_malloc/free functions to applications

This is required to implement a global allocator in Rust.
2022-09-26 07:06:46 +10:00

54 lines
502 B
Text

FORCE_COMMON_ALLOCATION
SECTIONS
{
.text 0x00000000 : ALIGN(4)
{
*(.text)
*(.stub)
*(.text*)
*(.text.*)
*(.text._*)
KEEP (*(.init))
KEEP (*(.fini))
}
.rodata :
{
*(.rodata)
*(.rodata1)
*(.rodata.*)
}
.data :
{
*(.data)
*(.data1)
*(.data.*)
}
.bss :
{
*(.bss)
*(.bss*)
*(.sbss)
*(.sbss*)
*(COMMON)
}
.ARM.attributes :
{
*(.ARM.attributes)
*(.ARM.attributes.*)
}
/DISCARD/ :
{
*(.comment)
*(.comment.*)
*(.llvmbc)
*(.llvmcmd)
}
}