binutils-gdb/sim/arm
Luis Machado 851c0536ca [ARM, sim] Fix build error and warnings
Newer GCC's have switched to -fno-common by default, and this breaks the build
for the ARM sim, like this:

binutils-gdb.git~gdb-8.3-release/sim/arm/maverick.c:65: multiple definition of `DSPsc'; libsim.a(wrapper.o):binutils-gdb.git~gdb-8.3-release/sim/arm/wrapper.c:134: first defined here
binutils-gdb.git~gdb-8.3-release/sim/arm/maverick.c:64: multiple definition of `DSPacc'; libsim.a(wrapper.o):binutils-gdb.git~gdb-8.3-release/sim/arm/wrapper.c:133: first defined here
binutils-gdb.git~gdb-8.3-release/sim/arm/maverick.c:63: multiple definition of `DSPregs'; libsim.a(wrapper.o):binutils-gdb.git~gdb-8.3-release/sim/arm/wrapper.c:132: first defined here

I also noticed a few warnings due to mismatching types, as follows:

../../../../repos/binutils-gdb/sim/arm/wrapper.c: In function ‘sim_create_inferior’:
../../../../repos/binutils-gdb/sim/arm/wrapper.c:335:16: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
       for (arg = argv; *arg != NULL; arg++)
                ^
../../../../repos/binutils-gdb/sim/arm/wrapper.c:342:8: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
    arg = argv;
        ^
../../../../repos/binutils-gdb/sim/arm/wrapper.c:345:13: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
    for (arg = argv; *arg != NULL; arg++)
             ^
The following patch fixes both of the above.

sim/arm/ChangeLog:

2019-12-06  Luis Machado  <luis.machado@linaro.org>

	* armemu.c (isize): Move this declaration ...
	* arminit.c (isize): ... here.
	* maverick.h: New file.
	* wrapper.c: Include "maverick.h".
	(<struct maverick_regs>, <union maverick_acc_regs>): Remove and update
	comment.
	(sim_create_inferior): Cast variables to proper type.
	* maverick.c: Include "maverick.h".
	(<struct maverick_regs>, <union maverick_acc_regs>): Move
	declarations to maverick.h and update comment.
	(DSPsc, DSPacc, DSPregs): Adjust comment.

Change-Id: I21db699d3b61b2de8c44053e47be4387285af28f
2019-12-06 18:16:20 -03:00
..
COPYING
ChangeLog [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00
Makefile.in Update copyright year range in all GDB files. 2019-01-01 10:01:51 +04:00
README
aclocal.m4
armcopro.c
armdefs.h
armemu.c [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00
armemu.h
armfpe.h
arminit.c [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00
armos.c
armos.h
armsupp.c
armvirt.c
config.in
configure
configure.ac
dbg_rdi.h
iwmmxt.c Update copyright year range in all GDB files. 2019-01-01 10:01:51 +04:00
iwmmxt.h Update copyright year range in all GDB files. 2019-01-01 10:01:51 +04:00
maverick.c [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00
maverick.h [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00
sim-main.h Update copyright year range in all GDB files. 2019-01-01 10:01:51 +04:00
thumbemu.c
wrapper.c [ARM, sim] Fix build error and warnings 2019-12-06 18:16:20 -03:00

README

This directory contains the standard release of the ARMulator from
Advanced RISC Machines, and was ftp'd from.

ftp.cl.cam.ac.uk:/arm/gnu

It likes to use TCP/IP between the simulator and the host, which is
nice, but is a pain to use under anything non-unix.

I've added created a new Makefile.in (the original in Makefile.orig)
to build a version of the simulator without the TCP/IP stuff, and a
wrapper.c to link directly into gdb and the run command.

It should be possible (barring major changes in the layout of
the armulator) to upgrade the simulator by copying all the files
out of a release into this directory and renaming the Makefile.

(Except that I changed armos.c to work more simply with our
simulator rigs)

Steve

sac@cygnus.com

Mon May 15 12:03:28 PDT 1995