summaryrefslogtreecommitdiffstats
path: root/gdb/symfile.c
diff options
context:
space:
mode:
authorKung Hsu <kung@cygnus>1994-03-10 03:13:52 +0000
committerKung Hsu <kung@cygnus>1994-03-10 03:13:52 +0000
commitd9389f37d5d0c895d0e3f11cdf1632dd6b458342 (patch)
tree4d1cb02e14575aec065e9243e3a9fc972d9ab455 /gdb/symfile.c
parent0906de694fd64cb2c5a203dfad9a4bf920dc9317 (diff)
downloadppe42-binutils-d9389f37d5d0c895d0e3f11cdf1632dd6b458342.tar.gz
ppe42-binutils-d9389f37d5d0c895d0e3f11cdf1632dd6b458342.zip
Modified Files:
ChangeLog os9kread.c stabsread.c remote-os9k.c symfile.c target.c * os9kread.c (fill_sym): check compiler verion number for pre- UltraC compiler. * os9kread.c (os9k_process_one_symbol): address of symbol is relative to section not module. * stabsread.c (define_symbol): add symbol type 's' as local symbol for os9k. * remote-os9k.c: add command 'set monitor_log' to turn on or off monitor logging. * remote-os9k.c: fix bug in delete breakpoint, single step trace. * remote-os9k.c: fix bug in 'set remotebaud' function. * remote-os9k.c (rombug_link): minimize checking so to improve speed. * symfile.c (symfile_command): check if failed to link, also make the command be able to accept more than one filenames. * target.c (target_link): check if failed to link with rombug.
Diffstat (limited to 'gdb/symfile.c')
-rw-r--r--gdb/symfile.c41
1 files changed, 21 insertions, 20 deletions
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 98c5c457bb..dbb84d91e6 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -675,7 +675,27 @@ symbol_file_command (args, from_tty)
}
else
{
- name = *argv;
+ char *p;
+
+ name = *argv;
+
+ /* this is for rombug remote only, to get the text relocation by
+ using link command */
+ p = strrchr(name, '/');
+ if (p != NULL) p++;
+ else p = name;
+
+ target_link(p, &text_relocation);
+
+ if (text_relocation == (CORE_ADDR)0)
+ return;
+ else if (text_relocation == (CORE_ADDR)-1)
+ symbol_file_add (name, from_tty, (CORE_ADDR)0, 1, mapped, readno
+w);
+ else
+ symbol_file_add (name, from_tty, (CORE_ADDR)text_relocation, 0,
+mapped, readnow);
+ set_initial_language ();
}
argv++;
}
@@ -684,25 +704,6 @@ symbol_file_command (args, from_tty)
{
error ("no symbol file name was specified");
}
- else
- {
- char *p;
-
- /* If target_link can find out where the file is,
- more power to it. */
- p = strrchr (name, '/');
- if (p != NULL) p++;
- else p = name;
-
- target_link (p, &text_relocation);
- if (text_relocation == (CORE_ADDR)-1)
- text_relocation = 0;
-
- symbol_file_add (name, from_tty, text_relocation, 1, mapped,
- readnow);
- set_initial_language ();
- }
-
do_cleanups (cleanups);
}
}
OpenPOWER on IntegriCloud