binutils-gdb/ld/scripttempl
Pedro Alves 4b05e0a74b Fix v850 bfd arch info printable names
Currently, it's not possible to manually set some of the v850 archs in
gdb:

 (gdb) set architecture v850<TAB>
 v850 (using old gcc ABI)
 v850-rh850
 v850e
 v850e (using old gcc ABI)
 v850e1
 [...]
 (gdb) set architecture v850 (using old gcc ABI)
 Ambiguous item "v850 (using old gcc ABI)".

The problem is that "set architecture" is a GDB "enum command", and
GDB only considers an enum value to be the string up until the first
space.  So writing "v850 (using old gcc ABI)" is the same as writing
"v850", and then that's not an unambiguous arch printable name prefix.

v850 is actually the only arch that has spaces in its printable name.
One can conveniently see that with e.g.:

 (gdb) set max-completions unlimited
 (gdb) complete set architecture
 ...

Rather than hack GDB into accepting this somehow, make v850 arch
printable names more like the printable names of the other archs, and
put the abi variant in the "machine" part, after a ':'.

We now get:

 (gdb) set architecture v850<TAB>
 v850:old-gcc-abi
 v850:rh850
 v850e
 v850e1
 v850e1:old-gcc-abi
 v850e2
 v850e2:old-gcc-abi
 [...]

And now "set architecture v850:old-gcc-abi" works as expected.

I ran the binutils/gas/ld testsuites, and found no regressions.  I
don't have a cross compiler handy, but I ran the gdb tests anyway,
which covers at least some snoke testing.

I think that the OUTPUT_ARCH in ld/scripttempl/v850.sc may have got
broken with the previous 2012 change, since I hacked v850_rh850.sc to
output "v850" and ld failed to grok it.  I think it only works if the
old GCC ABI is the configured v850 default ABI.  That's now fixed by
changing to use explicit v850:old-gcc-abi.

Also, this actually "fixes" an existing GDB test, which isn't likewise
expecting spaces in arch names, when GDB is configured for
--target=v850:

  (gdb) FAIL: gdb.xml/tdesc-arch.exp: read valid architectures

bfd/ChangeLog:
2016-03-09  Pedro Alves  <palves@redhat.com>

	* cpu-v850.c (N): Append ":old-gcc-abi" instead of " (using old
	gcc ABI)" to printable name.
	* cpu-v850_rh850.c (bfd_v850_rh850_arch): Use "v850:rh850" instead
	of "v850-rh850" as printable name.

ld/ChangeLog:
2016-03-09  Pedro Alves  <palves@redhat.com>

	* scripttempl/v850.sc: Use "v850:old-gcc-abi" as OUTPUT_ARCH.
	* scripttempl/v850_rh850.sc: Use "v850:rh850" as OUTPUT_ARCH.
2016-03-09 15:43:13 +00:00
..
aix.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
alpha.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
alphavms.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
aout.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
arclinux.sc [ARC] General fixes. 2016-02-29 16:07:48 +01:00
armaout.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
armbpabi.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
armcoff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
avr.sc Prevent .noinit section from incorrect placement for AVR. 2016-01-25 22:33:25 +03:00
avrtiny.sc Prevent .noinit section from incorrect placement for AVR. 2016-01-25 22:33:25 +03:00
crisaout.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
delta68.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
dlx.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
DWARF.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32cr16.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32cr16c.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32crx.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32msp430_3.sc Fix the execution of the MSP430 simulator testsuite. 2016-01-05 16:43:58 +00:00
elf32msp430.sc Fix the execution of the MSP430 simulator testsuite. 2016-01-05 16:43:58 +00:00
elf32sh-symbian.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32xc16x.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32xc16xl.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf32xc16xs.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf64hppa.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf_chaos.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elf.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfarc.sc New ARC implementation. 2015-10-07 14:20:19 +01:00
elfarcv2.sc New ARC implementation. 2015-10-07 14:20:19 +01:00
elfd10v.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfd30v.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfi370.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfm68hc11.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfm68hc12.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfmicroblaze.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfxgate.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
elfxtensa.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
epiphany_4x4.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
epocpe.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
ft32.sc
h8300.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300h.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300hn.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300s.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300sn.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300sx.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8300sxn.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8500.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8500b.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8500c.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8500m.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
h8500s.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
hppaelf.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i386beos.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i386coff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i386go32.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i386msdos.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i860coff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
i960.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
ia64vms.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
ip2k.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
iq2000.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
m68kaux.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
m68kcoff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
m88kbcs.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
mcorepe.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
mep.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
mips.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
mipsbsd.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
mmo.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
moxie.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
nds32elf.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
nw.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
pe.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
pep.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
pj.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
ppcpe.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
psos.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
README Copyright update for binutils 2016-01-01 23:00:01 +10:30
riscix.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
sh.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
sparccoff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
st2000.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic4xcoff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic30aout.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic30coff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic54xcoff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
tic80coff.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
v850_rh850.sc Fix v850 bfd arch info printable names 2016-03-09 15:43:13 +00:00
v850.sc Fix v850 bfd arch info printable names 2016-03-09 15:43:13 +00:00
vanilla.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
visium.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
w65.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
xstormy16.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
z80.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30
z8000.sc Copyright update for binutils 2016-01-01 23:00:01 +10:30

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

The files in this directory are linker script templates.
genscripts.sh sets some shell variables, then sources
EMULATION.sc, to generate EMULATION.{x,xr,xu,xn,xbn} -- the script
files for default, -r, -Ur, -n, -N.

Copyright (C) 2012-2016 Free Software Foundation, Inc.

Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.