diff options
author | Stan Shebs <shebs@codesourcery.com> | 1994-04-27 00:31:11 +0000 |
---|---|---|
committer | Stan Shebs <shebs@codesourcery.com> | 1994-04-27 00:31:11 +0000 |
commit | 028f88721998a18e317360487e3a9109a3b866df (patch) | |
tree | 5c7fd8bfb7b005141477311f1d54726322db388d | |
parent | 68ba2fa550a437a3de1e15b681b40ecc21d03399 (diff) | |
download | gdb-028f88721998a18e317360487e3a9109a3b866df.zip gdb-028f88721998a18e317360487e3a9109a3b866df.tar.gz gdb-028f88721998a18e317360487e3a9109a3b866df.tar.bz2 |
Tue Apr 26 17:20:03 1994 Stan Shebs (shebs@andros.cygnus.com)
* Makefile.in (em_m68klynx.c, em_i386lynx.c, em_sparclynx.c): Use
Lynx-specific script templates.
* configure.in (sparclite*-*-coff): Use coff-sparc.
* emulparams/i386lynx.sh (SCRIPT_NAME): Set to i386lynx.
* emulparams/sparclynx.sh (SCRIPT_NAME): Set to sparclynx.
(ENTRY): Set to __main.
* scripttempl/i386lynx.sc: New file, script for I386 Lynx.
* scripttempl/m68klynx.sc: Add insertion of ctor/dtor sections.
* scripttempl/sparclynx.sc: New file, script for uSparc Lynx.
-rw-r--r-- | ld/ChangeLog | 12 | ||||
-rw-r--r-- | ld/Makefile.in | 10 | ||||
-rw-r--r-- | ld/configure.in | 1 | ||||
-rw-r--r-- | ld/emulparams/sparclynx.sh | 4 | ||||
-rw-r--r-- | ld/scripttempl/i386lynx.sc | 46 | ||||
-rw-r--r-- | ld/scripttempl/sparclynx.sc | 47 |
6 files changed, 113 insertions, 7 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index 0db0052..c6b16c1 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,15 @@ +Tue Apr 26 17:20:03 1994 Stan Shebs (shebs@andros.cygnus.com) + + * Makefile.in (em_m68klynx.c, em_i386lynx.c, em_sparclynx.c): Use + Lynx-specific script templates. + * configure.in (sparclite*-*-coff): Use coff-sparc. + * emulparams/i386lynx.sh (SCRIPT_NAME): Set to i386lynx. + * emulparams/sparclynx.sh (SCRIPT_NAME): Set to sparclynx. + (ENTRY): Set to __main. + * scripttempl/i386lynx.sc: New file, script for I386 Lynx. + * scripttempl/m68klynx.sc: Add insertion of ctor/dtor sections. + * scripttempl/sparclynx.sc: New file, script for uSparc Lynx. + Tue Apr 26 12:41:03 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) * scripttempl/mips.sc: Force _gp and .lit8 to be aligned to a 16 diff --git a/ld/Makefile.in b/ld/Makefile.in index 64fdab4..bb3246b 100644 --- a/ld/Makefile.in +++ b/ld/Makefile.in @@ -342,17 +342,14 @@ em_delta68.c: $(srcdir)/emulparams/delta68.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/delta68.sc ${GEN_DEPENDS} ${GENSCRIPTS} delta68 em_m68klynx.c: $(srcdir)/emulparams/m68klynx.sh \ - $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/m68kcoff.sc ${GEN_DEPENDS} + $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/m68klynx.sc ${GEN_DEPENDS} ${GENSCRIPTS} m68klynx em_i386coff.c: $(srcdir)/emulparams/i386coff.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i386coff.sc ${GEN_DEPENDS} ${GENSCRIPTS} i386coff em_i386lynx.c: $(srcdir)/emulparams/i386lynx.sh \ - $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i386coff.sc ${GEN_DEPENDS} + $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i386lynx.sc ${GEN_DEPENDS} ${GENSCRIPTS} i386lynx -em_sparclynx.c: $(srcdir)/emulparams/sparclynx.sh \ - $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/sparccoff.sc ${GEN_DEPENDS} - ${GENSCRIPTS} sparclynx em_mipslit.c: $(srcdir)/emulparams/mipslit.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/mips.sc ${GEN_DEPENDS} ${GENSCRIPTS} mipslit @@ -383,6 +380,9 @@ em_alpha.c: $(srcdir)/emulparams/alpha.sh \ em_coff_sparc.c: $(srcdir)/emulparams/coff_sparc.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/sparccoff.sc ${GEN_DEPENDS} ${GENSCRIPTS} coff_sparc +em_sparclynx.c: $(srcdir)/emulparams/sparclynx.sh \ + $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/sparclynx.sc ${GEN_DEPENDS} + ${GENSCRIPTS} sparclynx em_elf32ppc.c: $(srcdir)/emulparams/elf32ppc.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} ${GENSCRIPTS} elf32ppc diff --git a/ld/configure.in b/ld/configure.in index b657e8e..14f138b 100644 --- a/ld/configure.in +++ b/ld/configure.in @@ -41,6 +41,7 @@ do case "${targ}" in sparc-sun-sunos4*) ld_target=sun4 ;; + sparclite*-*-coff) ld_target=coff-sparc ;; sparclite*-fujitsu-*) ld_target=sun4 ;; sparc*-*-aout) ld_target=sun4 ;; sparc*-*-coff) ld_target=coff-sparc ;; diff --git a/ld/emulparams/sparclynx.sh b/ld/emulparams/sparclynx.sh index dd67413..c85c8d5 100644 --- a/ld/emulparams/sparclynx.sh +++ b/ld/emulparams/sparclynx.sh @@ -1,7 +1,7 @@ -SCRIPT_NAME=sparccoff +SCRIPT_NAME=sparclynx OUTPUT_FORMAT="coff-sparc-lynx" # This is what LynxOS /lib/init1.o wants. -ENTRY=_main +ENTRY=__main # following are dubious PAGE_SIZE=0x1000 TEXT_START_ADDR=0 diff --git a/ld/scripttempl/i386lynx.sc b/ld/scripttempl/i386lynx.sc new file mode 100644 index 0000000..b1bfdb7 --- /dev/null +++ b/ld/scripttempl/i386lynx.sc @@ -0,0 +1,46 @@ +test -z "$ENTRY" && ENTRY=_start +cat <<EOF +OUTPUT_FORMAT("${OUTPUT_FORMAT}") +${LIB_SEARCH_DIRS} + +ENTRY(${ENTRY}) + +SECTIONS +{ + .text ${RELOCATING+ SIZEOF_HEADERS} : { + *(.init) + *(.text) + ${RELOCATING+ etext = .;} + ${CONSTRUCTING+ __CTOR_LIST__ = .;} + ${CONSTRUCTING+ LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2)} + *(.ctors) + ${CONSTRUCTING+ LONG(0)} + ${CONSTRUCTING+ __CTOR_END__ = .;} + ${CONSTRUCTING+ __DTOR_LIST__ = .;} + ${CONSTRUCTING+ LONG((__DTOR_END__ - __DTOR_LIST__) / 4 - 2)} + *(.dtors) + ${CONSTRUCTING+ LONG(0)} + ${CONSTRUCTING+ __DTOR_END__ = .;} + *(.fini) + ${RELOCATING+ etext = .}; + } + .data ${RELOCATING+ 0x400000 + (. & 0xffc00fff)} : { + *(.data) + ${RELOCATING+ edata = .}; + } + .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} : + { + *(.bss) + *(COMMON) + ${RELOCATING+ end = .}; + } + .stab . (NOLOAD) : + { + [ .stab ] + } + .stabstr . (NOLOAD) : + { + [ .stabstr ] + } +} +EOF diff --git a/ld/scripttempl/sparclynx.sc b/ld/scripttempl/sparclynx.sc new file mode 100644 index 0000000..d6b02e4 --- /dev/null +++ b/ld/scripttempl/sparclynx.sc @@ -0,0 +1,47 @@ +# Linker script for Sparc LynxOS. +test -z "$ENTRY" && ENTRY=_start +cat <<EOF +OUTPUT_FORMAT("${OUTPUT_FORMAT}") +${LIB_SEARCH_DIRS} + +ENTRY(${ENTRY}) + +SECTIONS +{ + .text ${RELOCATING+ SIZEOF_HEADERS} : { + *(.init) + *(.text) + ${RELOCATING+ etext = .;} + ${CONSTRUCTING+ ___CTOR_LIST__ = .;} + ${CONSTRUCTING+ LONG((___CTOR_END__ - ___CTOR_LIST__) / 4 - 2)} + *(.ctors) + ${CONSTRUCTING+ LONG(0)} + ${CONSTRUCTING+ ___CTOR_END__ = .;} + ${CONSTRUCTING+ ___DTOR_LIST__ = .;} + ${CONSTRUCTING+ LONG((___DTOR_END__ - ___DTOR_LIST__) / 4 - 2)} + *(.dtors) + ${CONSTRUCTING+ LONG(0)} + ${CONSTRUCTING+ ___DTOR_END__ = .;} + *(.fini) + ${RELOCATING+ etext = .}; + } + .data ${RELOCATING+ 0x400000 + (. & 0xffc00fff)} : { + *(.data) + ${RELOCATING+ edata = .}; + } + .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} : + { + *(.bss) + *(COMMON) + ${RELOCATING+ end = .}; + } + .stab . (NOLOAD) : + { + [ .stab ] + } + .stabstr . (NOLOAD) : + { + [ .stabstr ] + } +} +EOF |