diff options
author | Andrew Cagney <cagney@redhat.com> | 1997-08-28 09:44:42 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 1997-08-28 09:44:42 +0000 |
commit | 18c319ae59d5d09bbb31a90b97b8dc03c1761014 (patch) | |
tree | d29718d6a31bb9ea8d7dc60b3ae94f3c255e815b /sim/common/sim-utils.c | |
parent | 88117054103306a68d7879d6f5534bb49a0cffa8 (diff) | |
download | gdb-18c319ae59d5d09bbb31a90b97b8dc03c1761014.zip gdb-18c319ae59d5d09bbb31a90b97b8dc03c1761014.tar.gz gdb-18c319ae59d5d09bbb31a90b97b8dc03c1761014.tar.bz2 |
Add --target=BFDTARGET and --architecture=MACHINE options.
Diffstat (limited to 'sim/common/sim-utils.c')
-rw-r--r-- | sim/common/sim-utils.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sim/common/sim-utils.c b/sim/common/sim-utils.c index a0b582d..b62317ce 100644 --- a/sim/common/sim-utils.c +++ b/sim/common/sim-utils.c @@ -174,7 +174,7 @@ sim_analyze_program (sd, prog_name, prog_bfd) return SIM_RC_OK; /* open a new copy of the prog_bfd */ - prog_bfd = bfd_openr (prog_name, 0); + prog_bfd = bfd_openr (prog_name, STATE_TARGET (sd)); if (prog_bfd == NULL) { sim_io_eprintf (sd, "%s: can't open \"%s\": %s\n", @@ -192,7 +192,8 @@ sim_analyze_program (sd, prog_name, prog_bfd) bfd_close (prog_bfd); return SIM_RC_FAIL; } - + if (STATE_ARCHITECTURE (sd) != NULL) + bfd_set_arch_info (prog_bfd, STATE_ARCHITECTURE (sd)); /* update the sim structure */ if (STATE_PROG_BFD (sd) != NULL) |