diff options
author | Chung-Lin Tang <mentor.com> | 2013-11-18 06:57:28 -0800 |
---|---|---|
committer | Chung-Lin Tang <mentor.com> | 2013-11-18 06:57:28 -0800 |
commit | baa2af86d4ca17a82a02b581ab5150587ef955f8 (patch) | |
tree | d948a7a72eff889de82984c9efd14f95e5becc7c | |
parent | d0b5971ae7b8709c28a7a1638413426d8749d976 (diff) | |
download | gdb-baa2af86d4ca17a82a02b581ab5150587ef955f8.zip gdb-baa2af86d4ca17a82a02b581ab5150587ef955f8.tar.gz gdb-baa2af86d4ca17a82a02b581ab5150587ef955f8.tar.bz2 |
Separate emulations for nios2-elf and nios2-linux.
2013-11-18 Chung-Lin Tang <cltang@codesourcery.com>
* emulparams/nios2linux.sh: New emulation file.
* configure.tgt: Add nios2*-*-linux* emulation case.
* Makefile.am (enios2linux.c): New emulation entry.
* Makefile.in: Regenerate.
-rw-r--r-- | ld/ChangeLog | 7 | ||||
-rw-r--r-- | ld/Makefile.am | 3 | ||||
-rw-r--r-- | ld/Makefile.in | 3 | ||||
-rw-r--r-- | ld/configure.tgt | 1 | ||||
-rw-r--r-- | ld/emulparams/nios2linux.sh | 20 |
5 files changed, 34 insertions, 0 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index b8ebe32..8984e66 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,10 @@ +2013-11-18 Chung-Lin Tang <cltang@codesourcery.com> + + * emulparams/nios2linux.sh: New emulation file. + * configure.tgt: Add nios2*-*-linux* emulation case. + * Makefile.am (enios2linux.c): New emulation entry. + * Makefile.in: Regenerate. + 2013-10-14 Nick Clifton <nickc@redhat.com> * emultempl/aix.em (_read_file): Close file at end of function. diff --git a/ld/Makefile.am b/ld/Makefile.am index 286b189..6790f45 100644 --- a/ld/Makefile.am +++ b/ld/Makefile.am @@ -1756,6 +1756,9 @@ enews.c: $(srcdir)/emulparams/news.sh \ enios2elf.c: $(srcdir)/emulparams/nios2elf.sh \ $(ELF_DEPS) $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} ${GENSCRIPTS} nios2elf "$(tdir_nios2elf)" +enios2linux.c: $(srcdir)/emulparams/nios2linux.sh \ + $(ELF_DEPS) $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} + ${GENSCRIPTS} nios2linux "$(tdir_nios2linux)" ens32knbsd.c: $(srcdir)/emulparams/ns32knbsd.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/emultempl/netbsd.em \ $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS} diff --git a/ld/Makefile.in b/ld/Makefile.in index 358d036..7385ef4 100644 --- a/ld/Makefile.in +++ b/ld/Makefile.in @@ -3238,6 +3238,9 @@ enews.c: $(srcdir)/emulparams/news.sh \ enios2elf.c: $(srcdir)/emulparams/nios2elf.sh \ $(ELF_DEPS) $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} ${GENSCRIPTS} nios2elf "$(tdir_nios2elf)" +enios2linux.c: $(srcdir)/emulparams/nios2linux.sh \ + $(ELF_DEPS) $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} + ${GENSCRIPTS} nios2linux "$(tdir_nios2linux)" ens32knbsd.c: $(srcdir)/emulparams/ns32knbsd.sh \ $(srcdir)/emultempl/generic.em $(srcdir)/emultempl/netbsd.em \ $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS} diff --git a/ld/configure.tgt b/ld/configure.tgt index c0291c8..eefb772 100644 --- a/ld/configure.tgt +++ b/ld/configure.tgt @@ -512,6 +512,7 @@ mt-*elf) targ_emul=elf32mt msp430-*-*) targ_emul=msp430x110 targ_extra_emuls="msp430x112 msp430x1101 msp430x1111 msp430x1121 msp430x1122 msp430x1132 msp430x122 msp430x123 msp430x1222 msp430x1232 msp430x133 msp430x135 msp430x1331 msp430x1351 msp430x147 msp430x148 msp430x149 msp430x155 msp430x156 msp430x157 msp430x167 msp430x168 msp430x169 msp430x1610 msp430x1611 msp430x1612 msp430x2101 msp430x2111 msp430x2121 msp430x2131 msp430x311 msp430x312 msp430x313 msp430x314 msp430x315 msp430x323 msp430x325 msp430x336 msp430x337 msp430x412 msp430x413 msp430x415 msp430x417 msp430xE423 msp430xE425 msp430xE427 msp430xW423 msp430xW425 msp430xW427 msp430xG437 msp430xG438 msp430xG439 msp430x435 msp430x436 msp430x437 msp430x447 msp430x448 msp430x449 msp430X" ;; +nios2*-*-linux*) targ_emul=nios2linux ;; nios2*-*-*) targ_emul=nios2elf ;; ns32k-pc532-mach* | ns32k-pc532-ux*) targ_emul=pc532macha ;; ns32k-*-netbsd* | ns32k-pc532-lites*) targ_emul=ns32knbsd diff --git a/ld/emulparams/nios2linux.sh b/ld/emulparams/nios2linux.sh new file mode 100644 index 0000000..aa409a9 --- /dev/null +++ b/ld/emulparams/nios2linux.sh @@ -0,0 +1,20 @@ +SCRIPT_NAME=elf +TEMPLATE_NAME=elf32 +EXTRA_EM_FILE= +OUTPUT_FORMAT="elf32-littlenios2" +LITTLE_OUTPUT_FORMAT="elf32-littlenios2" +BIG_OUTPUT_FORMAT="elf32-bignios2" +TEXT_START_ADDR=0x2000 +OTHER_GOT_SYMBOLS=' + _gp = ALIGN(16) + 0x7ff0; + PROVIDE(gp = _gp); +' +ARCH=nios2 +MACHINE= +MAXPAGESIZE="CONSTANT (MAXPAGESIZE)" +COMMONPAGESIZE="CONSTANT (COMMONPAGESIZE)" +ENTRY=_start +NOP=0x0001883a + +GENERATE_SHLIB_SCRIPT=yes +GENERATE_PIE_SCRIPT=yes |