]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - ld/scripttempl/z80.sc
Add support for the GBZ80, Z180, and eZ80 variants of the Z80 architecure. Add an...
[thirdparty/binutils-gdb.git] / ld / scripttempl / z80.sc
1 # Copyright (C) 2014-2020 Free Software Foundation, Inc.
2 #
3 # Copying and distribution of this file, with or without modification,
4 # are permitted in any medium without royalty provided the copyright
5 # notice and this notice are preserved.
6
7 if test "${OUTPUT_FORMAT}" = "elf32-z80"; then
8 NO_REL_RELOCS=1
9 NO_RELA_RELOCS=1
10 NO_SMALL_DATA=1
11 EMBEDDED=1
12 ALIGNMENT=1
13 . $srcdir/scripttempl/elf.sc
14 return 0
15 fi
16
17 cat << EOF
18 /* Copyright (C) 2014-2020 Free Software Foundation, Inc.
19
20 Copying and distribution of this script, with or without modification,
21 are permitted in any medium without royalty provided the copyright
22 notice and this notice are preserved. */
23
24 OUTPUT_FORMAT("${OUTPUT_FORMAT}")
25 OUTPUT_ARCH("${ARCH}")
26 SECTIONS
27 {
28 .isr : {
29 ${RELOCATING+ __Labs = .;}
30 *(.isr)
31 *(isr)
32 ${RELOCATING+ __Habs = .;}
33 }
34 .text : {
35 ${RELOCATING+ __Ltext = .;}
36 *(.text)
37 *(text)
38 ${RELOCATING+ __Htext = .;}
39 }
40 .data : {
41 ${RELOCATING+ __Ldata = .;}
42 *(.data)
43 *(data)
44 ${RELOCATING+ __Hdata = .;}
45 }
46 .bss : {
47 ${RELOCATING+ __Lbss = .;}
48 *(.bss)
49 *(bss)
50 ${RELOCATING+ __Hbss = .;}
51 }
52 }
53 EOF