* fork-child.c (fork_inferior): Fork instead of vfork if
[deliverable/binutils-gdb.git] / gdb / pa64solib.h
1 /* HP PA64 ELF Shared library declarations for GDB, the GNU Debugger.
2 Copyright 1999, 2000 Free Software Foundation, Inc.
3
4 This file is part of GDB.
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA. */
20
21 /* Forward decl's for prototypes */
22 struct target_ops;
23 struct objfile;
24 struct section_offsets;
25 struct so_list;
26
27 /* Called to add symbols from a shared library to gdb's symbol table. */
28
29 #define SOLIB_ADD(filename, from_tty, targ, readsyms) \
30 pa64_solib_add (filename, from_tty, targ, readsyms)
31
32 extern void pa64_solib_add (char *, int, struct target_ops *, int);
33
34 extern CORE_ADDR pa64_solib_get_got_by_pc (CORE_ADDR);
35
36 /* Function to be called when the inferior starts up, to discover the names
37 of shared libraries that are dynamically linked, the base addresses to
38 which they are linked, and sufficient information to read in their symbols
39 at a later time. */
40
41 #define SOLIB_CREATE_INFERIOR_HOOK(PID) pa64_solib_create_inferior_hook()
42
43 extern void pa64_solib_create_inferior_hook (void);
44
45 /* Function to be called to remove the connection between debugger and
46 dynamic linker that was established by SOLIB_CREATE_INFERIOR_HOOK.
47 (This operation does not remove shared library information from
48 the debugger, as CLEAR_SOLIB does.) */
49 #define SOLIB_REMOVE_INFERIOR_HOOK(PID) pa64_solib_remove_inferior_hook(PID)
50
51 extern void pa64_solib_remove_inferior_hook (int);
52
53 /* This function is called by the "catch load" command. It allows
54 the debugger to be notified by the dynamic linker when a specified
55 library file (or any library file, if filename is NULL) is loaded. */
56 #define SOLIB_CREATE_CATCH_LOAD_HOOK(pid,tempflag, filename,cond_string) \
57 pa64_solib_create_catch_load_hook (pid, tempflag, filename, cond_string)
58
59 extern void pa64_solib_create_catch_load_hook (int, int, char *, char *);
60
61 /* This function is called by the "catch unload" command. It allows
62 the debugger to be notified by the dynamic linker when a specified
63 library file (or any library file, if filename is NULL) is unloaded. */
64 #define SOLIB_CREATE_CATCH_UNLOAD_HOOK(pid,tempflag,filename, cond_string) \
65 pa64_solib_create_catch_unload_hook (pid, tempflag, filename, cond_string)
66
67 extern void pa64_solib_create_catch_unload_hook (int, int, char *, char *);
68
69 /* This function returns TRUE if the dynamic linker has just reported
70 a load of a library.
71
72 This function must be used only when the inferior has stopped in
73 the dynamic linker hook, or undefined results are guaranteed. */
74 #define SOLIB_HAVE_LOAD_EVENT(pid) \
75 pa64_solib_have_load_event (pid)
76
77 extern int pa64_solib_have_load_event (int);
78
79 /* This function returns a pointer to the string representation of the
80 pathname of the dynamically-linked library that has just been loaded.
81
82 This function must be used only when SOLIB_HAVE_LOAD_EVENT is TRUE,
83 or undefined results are guaranteed.
84
85 This string's contents are only valid immediately after the inferior
86 has stopped in the dynamic linker hook, and becomes invalid as soon
87 as the inferior is continued. Clients should make a copy of this
88 string if they wish to continue the inferior and then access the string. */
89 #define SOLIB_LOADED_LIBRARY_PATHNAME(pid) \
90 pa64_solib_loaded_library_pathname (pid)
91
92 extern char *pa64_solib_loaded_library_pathname (int);
93
94 /* This function returns TRUE if the dynamic linker has just reported
95 an unload of a library.
96
97 This function must be used only when the inferior has stopped in
98 the dynamic linker hook, or undefined results are guaranteed. */
99 #define SOLIB_HAVE_UNLOAD_EVENT(pid) \
100 pa64_solib_have_unload_event (pid)
101
102 extern int pa64_solib_have_unload_event (int);
103
104 /* This function returns a pointer to the string representation of the
105 pathname of the dynamically-linked library that has just been unloaded.
106
107 This function must be used only when SOLIB_HAVE_UNLOAD_EVENT is TRUE,
108 or undefined results are guaranteed.
109
110 This string's contents are only valid immediately after the inferior
111 has stopped in the dynamic linker hook, and becomes invalid as soon
112 as the inferior is continued. Clients should make a copy of this
113 string if they wish to continue the inferior and then access the string. */
114 #define SOLIB_UNLOADED_LIBRARY_PATHNAME(pid) \
115 pa64_solib_unloaded_library_pathname (pid)
116
117 extern char *pa64_solib_unloaded_library_pathname (int);
118
119 /* This function returns TRUE if pc is the address of an instruction that
120 lies within the dynamic linker (such as the event hook, or the dld
121 itself).
122
123 This function must be used only when a dynamic linker event has been
124 caught, and the inferior is being stepped out of the hook, or undefined
125 results are guaranteed. */
126 #define SOLIB_IN_DYNAMIC_LINKER(pid,pc) \
127 pa64_solib_in_dynamic_linker (pid, pc)
128
129 extern int pa64_solib_in_dynamic_linker (int, CORE_ADDR);
130
131 /* This function must be called when the inferior is killed, and the program
132 restarted. This is not the same as CLEAR_SOLIB, in that it doesn't discard
133 any symbol tables.
134
135 Presently, this functionality is not implemented. */
136 #define SOLIB_RESTART() \
137 pa64_solib_restart ()
138
139 extern void pa64_solib_restart (void);
140
141 /* If we can't set a breakpoint, and it's in a shared library, just
142 disable it. */
143
144 #define DISABLE_UNSETTABLE_BREAK(addr) (pa64_solib_address(addr) != NULL)
145
146 extern char *pa64_solib_address (CORE_ADDR); /* somsolib.c */
147
148 /* If ADDR lies in a shared library, return its name. */
149
150 #define PC_SOLIB(addr) pa64_solib_address (addr)
151
152 CORE_ADDR pa64_solib_thread_start_addr (struct so_list *so);
This page took 0.031764 seconds and 4 git commands to generate.