diff options
author | ian <ian@FreeBSD.org> | 2015-05-08 19:43:53 +0000 |
---|---|---|
committer | ian <ian@FreeBSD.org> | 2015-05-08 19:43:53 +0000 |
commit | f872d0ea6f6c341713a7edeac25647390eece4cb (patch) | |
tree | 460a75048e0065081dda84c3c59bf7fb3821e535 /sys | |
parent | 0bf260e595825c4554b498bea4d9398ca220fae6 (diff) | |
download | FreeBSD-src-f872d0ea6f6c341713a7edeac25647390eece4cb.zip FreeBSD-src-f872d0ea6f6c341713a7edeac25647390eece4cb.tar.gz |
Move the text section to the start of the output file, so that when you
create a stripped .bin file from it the entry point is the first byte of
the file. (Will allow "load $addr $file ; go $addr" in u-boot.)
Diffstat (limited to 'sys')
-rw-r--r-- | sys/boot/arm/uboot/ldscript.arm | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/sys/boot/arm/uboot/ldscript.arm b/sys/boot/arm/uboot/ldscript.arm index b3be119..1eb10a8 100644 --- a/sys/boot/arm/uboot/ldscript.arm +++ b/sys/boot/arm/uboot/ldscript.arm @@ -6,6 +6,15 @@ SECTIONS { /* Read-only sections, merged into text segment: */ . = UBLDR_LOADADDR + SIZEOF_HEADERS; + .text : + { + *(.text) + /* .gnu.warning sections are handled specially by elf32.em. */ + *(.gnu.warning) + *(.gnu.linkonce.t*) + } =0 + _etext = .; + PROVIDE (etext = .); .interp : { *(.interp) } .hash : { *(.hash) } .dynsym : { *(.dynsym) } @@ -32,15 +41,6 @@ SECTIONS .rela.sbss : { *(.rela.sbss) } .rela.sdata2 : { *(.rela.sdata2) } .rela.sbss2 : { *(.rela.sbss2) } - .text : - { - *(.text) - /* .gnu.warning sections are handled specially by elf32.em. */ - *(.gnu.warning) - *(.gnu.linkonce.t*) - } =0 - _etext = .; - PROVIDE (etext = .); .init : { *(.init) } =0 .fini : { *(.fini) } =0 .rodata : { *(.rodata) *(.gnu.linkonce.r*) } |