summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc
diff options
context:
space:
mode:
authorNiklas Hallqvist <niklas@cvs.openbsd.org>1996-11-23 04:12:06 +0000
committerNiklas Hallqvist <niklas@cvs.openbsd.org>1996-11-23 04:12:06 +0000
commit37d4621bd4a912b6a032bc21906f7032e602cbf2 (patch)
tree6e6f3dad18baebc5f90abdcbbf4a8ba242555627 /gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc
parentfb7c7a778840ea235dd0bb550cfd2e2ac8ccb37c (diff)
Merge to Cygnus 961112 + add some support (not ready) for shared libs
Diffstat (limited to 'gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc')
-rw-r--r--gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc17
1 files changed, 11 insertions, 6 deletions
diff --git a/gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc b/gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc
index e4bfd0db814..f8a3f687030 100644
--- a/gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc
+++ b/gnu/usr.bin/binutils/ld/scripttempl/armcoff.sc
@@ -1,6 +1,11 @@
# Linker script for ARM COFF.
# Based on i386coff.sc by Ian Taylor <ian@cygnus.com>.
test -z "$ENTRY" && ENTRY=_start
+if test -z "${DATA_ADDR}"; then
+ if test "$LD_FLAG" = "N" || test "$LD_FLAG" = "n"; then
+ DATA_ADDR=.
+ fi
+fi
cat <<EOF
OUTPUT_FORMAT("${OUTPUT_FORMAT}")
${LIB_SEARCH_DIRS}
@@ -23,21 +28,21 @@ SECTIONS
*(.fini)
${RELOCATING+ etext = .};
}
- .data ${RELOCATING+ 0x40000 + (. & 0xffc00fff)} : {
- __data_start__ = . ;
+ .data ${RELOCATING+${DATA_ADDR-0x40000 + (. & 0xffc00fff)}} : {
+ ${RELOCATING+ __data_start__ = . ;}
*(.data)
- __data_end__ = . ;
+ ${RELOCATING+ __data_end__ = . ;}
${RELOCATING+ edata = .};
}
.bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
{
- __bss_start__ = . ;
+ ${RELOCATING+ __bss_start__ = . ;}
*(.bss)
*(COMMON)
- __bss_end__ = . ;
+ ${RELOCATING+ __bss_end__ = . ;}
}
- ${RELOCATING+ __end__ = .};
+ ${RELOCATING+ __end__ = .;}
.stab 0 ${RELOCATING+(NOLOAD)} :
{