No arch is using this anymore, and we want all new ports using the
hardware framework instead. Punt WITH_DEVICES and the two callbacks
device_io_{read,write}_buffer.
We can also punt the tconfig.h file as no port is using it anymore.
This fixes in-tree builds that get confused by picking up the wrong
one (common/ vs <port>/) caused by commit ae7d0cac8c.
Any port that needs to set up a global define can use their own
sim-main.h file that they must provide regardless.
Rather than manually include tconfig.h when we think we'll need it (which
is error prone as it can define symbols we expect from config.h), have it
be included directly by config.h. Since we know we have to include that
header everywhere already, this will make sure tconfig.h isn't missed.
It should also be fine as tconfig.h is supposed to be simple and only set
up a few core defines for the target.
This allows us to stop symlinking it in place all the time and just use
it straight out of the respective source directory.
This should fix a build failure reported on x86_64-mingw32 by Daniel
Calcoen due to conflicting declarations of "open". This patch just
renames the static global in sim/rx/gdb-if.c into "rx_sim_is_open".
sim/rx/ChangeLog:
* gdb-if.c (open): Rename to...
(rx_sim_is_open): This. Replace all uses of "open" by uses of
"rx_sim_is_open" throughout.
Tested by rebuilding on x86_64-linux.
Directories that don't use libtool need to add -ldl (on most *nix
hosts) to provide dlopen for libbfd.
config/
* plugins.m4 (AC_PLUGINS): If plugins are enabled, add -ldl to
LIBS via AC_SEARCH_LIBS.
gdb/
* acinclude.m4 (GDB_AC_CHECK_BFD): Don't add -ldl.
* config.in: Regenerate.
sim/ppc/
* configure.ac: Invoke AC_PLUGINS.
* config.in: Regenerate.
and regen lots of configure files.
It is rare for people to want to modify the cmd arg. In general, they
really shouldn't be, but a few still do. For those who misbehave, dupe
the string locally so they can bang on it.
sim/rx/gdb-if.c had a function named `rx_signal_to_host'. This
function mapped signal numbers used by the BSP to host signal
numbers which, at one time a while back, were used by GDB
as target signal numbers. This change updates the signal
numbers returned to be those names prefixed with "GDB_SIGNAL_"
as defined in include/gdb/signals.h.
It also changes the name of the function somewhat to better
match what the function currently does. I noticed that this
function is not static - and there's no reason for it not
to be - so I made it static too.
* gdb-if.c (rx_signal_to_host): Rename to
`rx_signal_to_gdb_signal'. Make static. Update all callers
to use new name. Use signal names from include/gdb/signals.h.
I noticed the sim code is using an old implementation of the maintainer logic.
I cut it over to the new macro (like gdb has been doing). In practice, it
makes no difference currently as nothing in the sim tree uses it, but I have a
follow up commit for the Blackfin tree that needs it.
Two modifications:
1. The addition of 2013 to the copyright year range for every file;
2. The use of a single year range, instead of potentially multiple
year ranges, as approved by the FSF.
Before POSIX standardized strsignal(), old systems would hide the
prototype unless the normal extension defines were enabled. So use
the AC_USE_SYSTEM_EXTENSIONS helper for that.
Then make sure we include string.h ourselves in nrun.c rather than
relying on implicit includes via other sim headers.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Lift the code that GDB is using to generate dependencies on the fly and
port it over to the sim. Now people shouldn't have to manually maintain
these in their Makefile's.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Automake likes to dump macros automatically used into the aclocal.m4
file, but the common/aclocal.m4 naming prevents that. So rename it
to the more normal "acinclude.m4" so the aclocal tool can work.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Now that the sourceware tree generally requires autoconf-2.64, update
the sim tree to require that too.
This allows us to drop the long standing SIM_AC_COMMON/common.m4
workaround as autoconf 2.64+ seems to work for me.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
The sim dir has 30 configure.ac files and 2 configure.in files.
So rename the minority to be consistent.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
For the ports that don't use the common/ subdir, we need to add stub funcs
to them to avoid build failures with gdb and command completion. These do
not implement the actual completion functionality ... any port that wants
that can either convert to the common/ subdir, or fill out the function on
their own time.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
gdb/ChangeLog
* remote-sim.c (gdbsim_store_register): Update API to
sim_store_register to check more error conditions.
include/gdb/ChangeLog
* remote-sim.h (sim_store_register): Update the API
documentation for this function.
sim/erc32/ChangeLog
sim/h8300/ChangeLog
sim/m32c/ChangeLog
sim/mn10300/ChangeLog
sim/ppc/ChangeLog
sim/rx/ChangeLog
sim/v850/ChangeLog
* ???.c (sim_store_register): Update return value to
match new API.