GDB (xrefs)
Defines | Functions | Variables
/home/stan/gdb/src/gdb/solib.c File Reference
#include "defs.h"
#include <sys/types.h>
#include <fcntl.h>
#include "gdb_string.h"
#include "symtab.h"
#include "bfd.h"
#include "symfile.h"
#include "objfiles.h"
#include "exceptions.h"
#include "gdbcore.h"
#include "command.h"
#include "target.h"
#include "frame.h"
#include "gdb_regex.h"
#include "inferior.h"
#include "environ.h"
#include "language.h"
#include "gdbcmd.h"
#include "completer.h"
#include "filenames.h"
#include "exec.h"
#include "solist.h"
#include "observer.h"
#include "readline/readline.h"
#include "remote.h"
#include "solib.h"
#include "interps.h"
#include "filesystem.h"
#include "gdb_bfd.h"
#include "filestuff.h"

Go to the source code of this file.

Defines

#define so_list_head   current_program_space->so_list
#define DOS_BASED_FILE_SYSTEM   0

Functions

static void * solib_init (struct obstack *obstack)
static struct target_so_opssolib_ops (struct gdbarch *gdbarch)
void set_solib_ops (struct gdbarch *gdbarch, const struct target_so_ops *new_ops)
static void show_solib_search_path (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
char * solib_find (char *in_pathname, int *fd)
bfd * solib_bfd_fopen (char *pathname, int fd)
bfd * solib_bfd_open (char *pathname)
static int solib_map_sections (struct so_list *so)
static void clear_so (struct so_list *so)
void free_so (struct so_list *so)
struct so_listmaster_so_list (void)
int solib_read_symbols (struct so_list *so, int flags)
static int solib_used (const struct so_list *const known)
static void update_solib_list (int from_tty, struct target_ops *target)
int libpthread_name_p (const char *name)
static int libpthread_solib_p (struct so_list *so)
void solib_add (char *pattern, int from_tty, struct target_ops *target, int readsyms)
static void info_sharedlibrary_command (char *pattern, int from_tty)
int solib_contains_address_p (const struct so_list *const solib, CORE_ADDR address)
char * solib_name_from_address (struct program_space *pspace, CORE_ADDR address)
int solib_keep_data_in_core (CORE_ADDR vaddr, unsigned long size)
void clear_solib (void)
void solib_create_inferior_hook (int from_tty)
int in_solib_dynsym_resolve_code (CORE_ADDR pc)
static void sharedlibrary_command (char *args, int from_tty)
void no_shared_libraries (char *ignored, int from_tty)
void update_solib_breakpoints (void)
void handle_solib_event (void)
static void reload_shared_libraries_1 (int from_tty)
static void reload_shared_libraries (char *ignored, int from_tty, struct cmd_list_element *e)
static void show_auto_solib_add (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
struct symbolsolib_global_lookup (const struct objfile *objfile, const char *name, const domain_enum domain)
CORE_ADDR gdb_bfd_lookup_symbol_from_symtab (bfd *abfd, int(*match_sym)(asymbol *, void *), void *data)
static CORE_ADDR bfd_lookup_symbol_from_dyn_symtab (bfd *abfd, int(*match_sym)(asymbol *, void *), void *data)
CORE_ADDR gdb_bfd_lookup_symbol (bfd *abfd, int(*match_sym)(asymbol *, void *), void *data)
void _initialize_solib (void)

Variables

static struct gdbarch_datasolib_data
struct target_so_opscurrent_target_so_ops
static char * solib_search_path = NULL
initialize_file_ftype _initialize_solib

Define Documentation

#define DOS_BASED_FILE_SYSTEM   0

Definition at line 114 of file solib.c.

Referenced by solib_find().


Function Documentation

void _initialize_solib ( void  )
static CORE_ADDR bfd_lookup_symbol_from_dyn_symtab ( bfd *  abfd,
int(*)(asymbol *, void *)  match_sym,
void *  data 
) [static]

Definition at line 1447 of file solib.c.

References do_cleanups(), make_cleanup(), xfree(), and xmalloc().

Referenced by gdb_bfd_lookup_symbol().

static void clear_so ( struct so_list so) [static]
void clear_solib ( void  )
void free_so ( struct so_list so)
CORE_ADDR gdb_bfd_lookup_symbol ( bfd *  abfd,
int(*)(asymbol *, void *)  match_sym,
void *  data 
)
CORE_ADDR gdb_bfd_lookup_symbol_from_symtab ( bfd *  abfd,
int(*)(asymbol *, void *)  match_sym,
void *  data 
)

Definition at line 1408 of file solib.c.

References do_cleanups(), make_cleanup(), xfree(), and xmalloc().

Referenced by gdb_bfd_lookup_symbol().

void handle_solib_event ( void  )

Definition at line 1197 of file solib.c.

References target_so_ops::in_dynsym_resolve_code, solib_ops(), and target_gdbarch().

Referenced by handle_inferior_event().

static void info_sharedlibrary_command ( char *  pattern,
int  from_tty 
) [static]
int libpthread_name_p ( const char *  name)
static int libpthread_solib_p ( struct so_list so) [static]

Definition at line 878 of file solib.c.

References libpthread_name_p(), and so_list::so_name.

Referenced by reload_shared_libraries_1(), and solib_add().

struct so_list* master_so_list ( void  ) [read]
void no_shared_libraries ( char *  ignored,
int  from_tty 
)
static void reload_shared_libraries ( char *  ignored,
int  from_tty,
struct cmd_list_element e 
) [static]
static void reload_shared_libraries_1 ( int  from_tty) [static]
void set_solib_ops ( struct gdbarch gdbarch,
const struct target_so_ops new_ops 
)
static void sharedlibrary_command ( char *  args,
int  from_tty 
) [static]

Definition at line 1207 of file solib.c.

References dont_repeat(), and solib_add().

Referenced by _initialize_solib().

static void show_auto_solib_add ( struct ui_file file,
int  from_tty,
struct cmd_list_element c,
const char *  value 
) [static]

Definition at line 1379 of file solib.c.

References _, and fprintf_filtered().

Referenced by _initialize_solib().

static void show_solib_search_path ( struct ui_file file,
int  from_tty,
struct cmd_list_element c,
const char *  value 
) [static]

Definition at line 102 of file solib.c.

References _, and fprintf_filtered().

Referenced by _initialize_solib().

void solib_add ( char *  pattern,
int  from_tty,
struct target_ops target,
int  readsyms 
)
bfd* solib_bfd_fopen ( char *  pathname,
int  fd 
)
bfd* solib_bfd_open ( char *  pathname)
int solib_contains_address_p ( const struct so_list *const  solib,
CORE_ADDR  address 
)
void solib_create_inferior_hook ( int  from_tty)
char* solib_find ( char *  in_pathname,
int fd 
)
struct symbol* solib_global_lookup ( const struct objfile objfile,
const char *  name,
const domain_enum  domain 
) [read]

Definition at line 1391 of file solib.c.

References target_so_ops::lookup_lib_global_symbol, solib_ops(), and target_gdbarch().

Referenced by lookup_symbol_global().

static void* solib_init ( struct obstack *  obstack) [static]

Definition at line 58 of file solib.c.

References current_target_so_ops, and OBSTACK_ZALLOC.

Referenced by _initialize_solib().

int solib_keep_data_in_core ( CORE_ADDR  vaddr,
unsigned long  size 
)

Definition at line 1126 of file solib.c.

References target_so_ops::keep_data_in_core, solib_ops(), and target_gdbarch().

Referenced by gcore_create_callback().

static int solib_map_sections ( struct so_list so) [static]
char* solib_name_from_address ( struct program_space pspace,
CORE_ADDR  address 
)
static struct target_so_ops* solib_ops ( struct gdbarch gdbarch) [static, read]
int solib_read_symbols ( struct so_list so,
int  flags 
)
static int solib_used ( const struct so_list *const  known) [static]

Definition at line 657 of file solib.c.

References so_list::next, so_list::objfile, and so_list_head.

Referenced by reload_shared_libraries_1(), and update_solib_list().

void update_solib_breakpoints ( void  )

Definition at line 1233 of file solib.c.

References solib_ops(), target_gdbarch(), and target_so_ops::update_breakpoints.

Referenced by set_stop_on_solib_events().

static void update_solib_list ( int  from_tty,
struct target_ops target 
) [static]

Variable Documentation

Referenced by initialize_all_files().

Definition at line 90 of file solib.c.

Referenced by _initialize_osf_solib(), _initialize_solib_target(), and solib_init().

struct gdbarch_data* solib_data [static]

Definition at line 55 of file solib.c.

char* solib_search_path = NULL [static]

Definition at line 100 of file solib.c.

Referenced by _initialize_solib(), and solib_find().

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines