diff options
author | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-03-02 03:01:34 +0000 |
---|---|---|
committer | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-03-02 03:01:34 +0000 |
commit | 25200748a2ad772bb72958902dd18b314ec4e6c9 (patch) | |
tree | 01a1e4e75536ec6fc99cca358f17d3224a87f49c /gdb/symfile.c | |
parent | 6e2194f0772c505e0ee872611664188c8513a0b1 (diff) | |
download | gdb-25200748a2ad772bb72958902dd18b314ec4e6c9.zip gdb-25200748a2ad772bb72958902dd18b314ec4e6c9.tar.gz gdb-25200748a2ad772bb72958902dd18b314ec4e6c9.tar.bz2 |
* os9kread.c (os9k_process_one_symbol): Rename
VARIABLES_INSIDE_BLOCK to OS9K_VARIABLES_INSIDE_BLOCK.
* symfile.c (symbol_file_command): Check for (CORE_ADDR)-1, not
(CORE_ADDR)0, from target_link, since that is what it uses.
Process name at end, not during parsing (like we did before Kung's
change), so that -readnow and -mapped can appear anywhere.
Make text_relocation a local variable.
* config/i386/i386os9k.mt: Fix comment.
* Makefile.in (ALLDEPFILES): Add remote-os9k.c.
* os9kread.c: Put "comments" after #endif inside /* */.
* stabsread.h: Add os9k_stabs variable.
* stabsread.c (start_stabs), os9kread.c (os9k_process_one_symbol):
Set it.
* stabsread.c (define_symbol): If os9k_stabs, put a 'V' symbol
descriptor in global_symbols not local_symbols.
(read_type): If os9k_stabs, accept 'c', 'i', and 'b' type
descriptors.
(read_type): If os9k_stabs, accept function parameters after 'f'
type descriptor.
(read_array_type): If os9k_stabs, don't expect index type and
expect lower and upper to be separated by ',' not ';'.
(read_enum_type): If os9k_stabs, read a number before the first
enumeration constant.
(os9k_init_type_vector): New function.
(dbx_lookup_type): Call it when starting new type vector.
* config/i386/tm-i386os9k.h: Define BELIEVE_PCC_PROMOTION.
* (os9k_process_one_symbol): Call define_symbol not os9k_define_symbol.
* os9kstab.c: Removed.
* Makefile.in: Update accordingly.
* objfiles.c (objfile_relocate_data): Removed.
* remote-os9k.c (rombug_wait): Call objfile_relocate
not objfile_relocate_data.
* objfiles.h, objfiles.c: Remove find_pc_objfile.
* remote-os9k.c (rombug_wait): Call find_pc_section not
find_pc_objfile.
* main.c (quit_command): Check inferior_pid; revert Kung change.
* remote-os9k.c (rombug_create_inferior): Set inferior_pid.
Diffstat (limited to 'gdb/symfile.c')
-rw-r--r-- | gdb/symfile.c | 37 |
1 files changed, 20 insertions, 17 deletions
diff --git a/gdb/symfile.c b/gdb/symfile.c index cb998bf..98c5c45 100644 --- a/gdb/symfile.c +++ b/gdb/symfile.c @@ -48,7 +48,6 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #endif /* Global variables owned by this file */ -CORE_ADDR text_relocation = 0; /* text_relocation */ int readnow_symbol_files; /* Read full symbols immediately */ struct complaint oldsyms_complaint = { @@ -632,6 +631,7 @@ symbol_file_command (args, from_tty) { char **argv; char *name = NULL; + CORE_ADDR text_relocation = 0; /* text_relocation */ struct cleanup *cleanups; int mapped = 0; int readnow = 0; @@ -675,23 +675,7 @@ symbol_file_command (args, from_tty) } else { - 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) - symbol_file_add (name, from_tty, (CORE_ADDR)text_relocation, 0, mapped, readnow); - else - symbol_file_add (name, from_tty, (CORE_ADDR)0, 1, mapped, readnow); - set_initial_language (); } argv++; } @@ -700,6 +684,25 @@ 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); } } |