aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog31
-rw-r--r--gdb/Makefile.in150
-rw-r--r--gdb/ada-typeprint.c2
-rw-r--r--gdb/bcache.c2
-rw-r--r--gdb/buildsym.c2
-rw-r--r--gdb/c-typeprint.c2
-rw-r--r--gdb/ch-typeprint.c2
-rw-r--r--gdb/ch-valprint.c2
-rw-r--r--gdb/coffread.c2
-rw-r--r--gdb/cp-valprint.c2
-rw-r--r--gdb/dbxread.c2
-rw-r--r--gdb/dstread.c2
-rw-r--r--gdb/f-typeprint.c2
-rw-r--r--gdb/gdb_obstack.h32
-rw-r--r--gdb/macroexp.c2
-rw-r--r--gdb/macrotab.c2
-rw-r--r--gdb/mdebugread.c2
-rw-r--r--gdb/objfiles.c2
-rw-r--r--gdb/objfiles.h1
-rw-r--r--gdb/p-typeprint.c2
-rw-r--r--gdb/p-valprint.c2
-rw-r--r--gdb/stabsread.c2
-rw-r--r--gdb/symfile.c2
-rw-r--r--gdb/symmisc.c2
-rw-r--r--gdb/symtab.c2
-rw-r--r--gdb/symtab.h4
-rw-r--r--gdb/typeprint.c2
27 files changed, 174 insertions, 88 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 31f0b99..326ba48 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,34 @@
+2002-07-29 Andrew Cagney <ac131313@redhat.com>
+
+ * gdb_obstack.h: New file.
+ * symtab.h: Include "gdb_obstack.h" instead of "obstack.h".
+ (obstack_chunk_alloc, obstack_chunk_free): Delete macros.
+ * objfiles.h: Include "gdb_obstack.h".
+ * Makefile.in (gdb_obstack_h): Define.
+ (symtab_h): Add $(gdb_obstack_h).
+ (objfiles_h): Add $(gdb_obstack_h).
+
+ * objfiles.c: Include "gdb_obstack.h" instead of "obstack.h".
+ * macrotab.c, cp-valprint.c, dbxread.c: Ditto.
+ * ch-typeprint.c, ch-valprint.c, dstread.c: Ditto.
+ * macroexp.c, p-typeprint.c, stabsread.c: Ditto.
+ * symtab.c, f-typeprint.c, mdebugread.c: Ditto.
+ * p-valprint.c, symmisc.c, typeprint.c: Ditto.
+ * symfile.c, coffread.c, c-typeprint.c: Ditto.
+ * buildsym.c, bcache.c, ada-typeprint.c: Ditto.
+
+ * Makefile.in (bcache.o): Update dependencies.
+ (buildsym.o, c-typeprint.o, ch-typeprint.o): Ditto.
+ (ch-valprint.o, coffread.o, cp-valprint.o): Ditto.
+ (dbxread.o, dstread.o, f-typeprint.o): Ditto.
+ (objfiles.o, p-typeprint.o, p-valprint.o): Ditto.
+ (stabsread.o, symfile.o, symmisc.o): Ditto.
+ (symtab.o, typeprint.o, macroexp.o): Ditto.
+ (macrotab.o, mdebugread.o): Ditto.
+ (f_lang_h, coff_sym_h, coff_symconst_h): Define.
+ (coff_ecoff_h, aout_aout64_h): Define.
+ (aout_stabs_gnu_h, libaout_h): Define.
+
2002-07-29 Andrew Cagney <cagney@redhat.com>
* regcache.c (struct regcache_descr): Rename nr_registers to
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index ae3130f..c4ce708 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -567,13 +567,18 @@ LINTFILES = $(SFILES) $(YYFILES) $(CONFIG_SRCS) init.c
# (Why would we not want to depend on them? If one of these changes in a
# non-binary-compatible way, it is a real pain to remake the right stuff
# without these dependencies -kingdon, 13 Mar 1994)
+aout_aout64_h = $(INCLUDE_DIR)/aout/aout64.h
getopt_h = $(INCLUDE_DIR)/getopt.h
floatformat_h = $(INCLUDE_DIR)/floatformat.h
bfd_h = $(BFD_DIR)/bfd.h
callback_h = $(INCLUDE_DIR)/gdb/callback.h
+coff_sym_h = $(INCLUDE_DIR)/coff/sym.h
+coff_symconst_h = $(INCLUDE_DIR)/coff/symconst.h
+coff_ecoff_h = $(INCLUDE_DIR)/coff/ecoff.h
dis_asm_h = $(INCLUDE_DIR)/dis-asm.h
elf_sh_h = $(INCLUDE_DIR)/elf/sh.h
elf_bfd_h = $(BFD_SRC)/elf-bfd.h
+libaout_h = $(BFD_SRC)/libaout.h
remote_sim_h = $(INCLUDE_DIR)/gdb/remote-sim.h
demangle_h = $(INCLUDE_DIR)/demangle.h
obstack_h = $(INCLUDE_DIR)/obstack.h
@@ -624,10 +629,12 @@ dwarf2cfi_h = dwarf2cfi.h
event_loop_h = event-loop.h
event_top_h = event-top.h
expression_h = expression.h $(doublest_h) $(symtab_h)
+f_lang_h = f-lang.h
frame_h = frame.h
gdb_h = gdb.h
gdb_assert_h = gdb_assert.h
gdb_events_h = gdb-events.h
+gdb_obstack_h = $(obstack_h)
gdb_stabs_h = gdb-stabs.h
gdb_string_h = gdb_string.h
gdb_wait_h = gdb_wait.h
@@ -648,7 +655,7 @@ macrotab_h = macrotab.h
macroscope_h = macroscope.h $(macrotab_h) $(symtab_h)
memattr_h = memattr.h
monitor_h = monitor.h
-objfiles_h = objfiles.h
+objfiles_h = objfiles.h $(gdb_obstack_h)
parser_defs_h = parser-defs.h $(doublest_h)
ppc_tdep_h = ppc-tdep.h osabi.h
regcache_h = regcache.h
@@ -662,7 +669,7 @@ solist_h = solist.h
source_h = source.h
stabsread_h = stabsread.h
symfile_h = symfile.h
-symtab_h = symtab.h
+symtab_h = symtab.h $(gdb_obstack_h)
target_h = target.h $(bfd_h) $(symtab_h) $(dcache_h) $(memattr_h)
terminal_h = terminal.h
top_h = top.h
@@ -1311,7 +1318,7 @@ armnbsd-tdep.o: armnbsd-tdep.c $(defs_h) $(arm_tdep_h) solib-svr4.h \
avr-tdep.o: avr-tdep.c $(defs_h) $(gdbcmd_h) $(gdbcore_h) $(inferior_h) \
$(symfile_h) $(regcache_h) $(arch_utils_h)
-bcache.o: bcache.c $(bcache_h) $(defs_h)
+bcache.o: bcache.c $(defs_h) $(gdb_obstack_h) $(bcache_h) $(gdb_string_h)
blockframe.o: blockframe.c $(defs_h) $(gdbcore_h) $(inferior_h) \
$(objfiles_h) $(symfile_h) $(target_h) $(regcache_h)
@@ -1321,11 +1328,10 @@ breakpoint.o: breakpoint.c $(defs_h) $(gdbcmd_h) $(gdbcore_h) \
$(gdb_string_h) $(gdb_events_h) $(linespec_h) $(ui_out_h) \
$(completer_h) $(gdb_h)
-buildsym.o: buildsym.c $(bfd_h) $(buildsym_h) $(complaints_h) $(defs_h) \
- $(objfiles_h) $(symfile_h) $(symtab_h) $(gdb_string_h) \
- $(obstack_h) $(symtab_h) $(gdbtypes_h) $(expression_h) \
- $(language_h) $(bcache_h) $(filenames_h) $(stabsread_h) \
- $(macrotab_h)
+buildsym.o: buildsym.c $(defs_h) $(bfd_h) $(gdb_obstack_h) $(symtab_h) \
+ $(symfile_h) $(objfiles_h) $(gdbtypes_h) $(complaints_h) \
+ $(gdb_string_h) $(expression_h) $(language_h) $(bcache_h) \
+ $(filenames_h) $(macrotab_h) $(demangle_h) $(buildsym_h) $(stabsread_h)
builtin-regs.o: builtin-regs.c $(defs.h) $(builtin_regs_h) $(gdbtypes_h) \
$(gdb_string_h) $(value_h) $(frame_h)
@@ -1334,9 +1340,10 @@ c-lang.o: c-lang.c $(c_lang_h) $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(parser_defs_h) $(symtab_h) $(macroscope_h) \
gdb_assert.h
-c-typeprint.o: c-typeprint.c $(c_lang_h) $(defs_h) $(expression_h) \
- $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) $(language_h) $(symtab_h) \
- $(target_h) $(typeprint_h) $(value_h) $(gdb_string_h) $(cp_abi_h)
+c-typeprint.o: c-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(target_h) \
+ $(language_h) $(demangle_h) $(c_lang_h) $(typeprint_h) $(cp_abi_h) \
+ $(gdb_string_h)
c-valprint.o: c-valprint.c $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(symtab_h) $(valprint_h) $(value_h) $(cp_abi_h)
@@ -1347,9 +1354,9 @@ doublest.o: doublest.c $(defs_h) $(doublest_h) $(floatformat_h) $(gdbtypes_h) \
f-lang.o: f-lang.c f-lang.h $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(parser_defs_h) $(symtab_h) $(gdb_string_h)
-f-typeprint.o: f-typeprint.c f-lang.h $(defs_h) $(expression_h) \
- $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) $(language_h) $(symtab_h) \
- $(target_h) $(typeprint_h) $(value_h) $(gdb_string_h)
+f-typeprint.o: f-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(target_h) \
+ $(f_lang_h) $(gdb_string_h)
f-valprint.o: f-valprint.c $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(symtab_h) $(valprint_h) $(value_h) $(gdb_string_h)
@@ -1360,19 +1367,21 @@ ch-exp.o: ch-exp.c ch-lang.h $(defs_h) $(language_h) $(parser_defs_h) \
ch-lang.o: ch-lang.c ch-lang.h $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(parser_defs_h) $(symtab_h)
-ch-typeprint.o: ch-typeprint.c ch-lang.h $(defs_h) $(expression_h) \
- $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) $(language_h) $(symtab_h) \
- $(target_h) $(value_h) $(typeprint_h) $(gdb_string_h)
+ch-typeprint.o: ch-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) \
+ $(symtab_h) $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) \
+ $(target_h) $(language_h) $(ch_lang_h) $(typeprint_h) $(gdb_string_h)
-ch-valprint.o: ch-valprint.c $(defs_h) $(expression_h) $(gdbtypes_h) \
- $(language_h) $(symtab_h) $(valprint_h) $(value_h) $(c_lang_h)
+ch-valprint.o: ch-valprint.c $(defs_h) $(gdb_obstack_h) $(symtab_h) \
+ $(gdbtypes_h) $(valprint_h) $(expression_h) $(value_h) $(language_h) \
+ $(demangle_h) $(c_lang_h) $(typeprint_h) $(ch_lang_h) $(annotate_h)
coff-solib.o: coff-solib.c $(defs_h)
-coffread.o: coffread.c $(bfd_h) $(breakpoint_h) $(buildsym_h) \
- $(complaints_h) $(defs_h) $(expression_h) $(gdbtypes_h) $(objfiles_h) \
- $(symfile_h) $(symtab_h) $(gdb_stabs_h) $(stabsread_h) $(target_h) \
- $(gdb_string_h)
+coffread.o: coffread.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(demangle_h) \
+ $(breakpoint_h) $(bfd_h) $(gdb_obstack_h) $(gdb_string_h) \
+ $(coff_internal_h) $(libcoff_h) $(symfile_h) $(objfiles_h) \
+ $(buildsym_h) $(gdb_stabs_h) $(stabsread_h) $(complaints_h) \
+ $(target_h) $(gdb_assert_h)
complaints.o: complaints.c $(complaints_h) $(defs_h) $(gdbcmd_h)
@@ -1404,8 +1413,10 @@ linux-proc.o: linux-proc.c $(defs_h) $(inferior_h) $(gregset_h) \
cp-abi.o: cp-abi.c $(defs_h) $(value_h) $(cp_abi_h)
-cp-valprint.o: cp-valprint.c $(defs_h) $(expression_h) $(gdbcmd_h) \
- $(gdbtypes_h) $(symtab_h) $(value_h) $(gdb_string_h) $(cp_abi_h)
+cp-valprint.o: cp-valprint.c $(defs_h) $(gdb_obstack_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(command_h) $(gdbcmd_h) \
+ $(demangle_h) $(annotate_h) $(gdb_string_h) $(c_lang_h) $(target_h) \
+ $(cp_abi_h)
dcache.o: dcache.c $(dcache_h) $(defs_h) $(gdbcmd_h) $(gdb_string_h) \
$(gdbcore_h) $(target_h)
@@ -1415,11 +1426,11 @@ d10v-tdep.o: d10v-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(gdbtypes_h) \
$(dis_asm_h) $(symfile_h) $(objfiles_h) $(language_h) $(arch_utils_h) \
$(regcache_h) $(floatformat_h) $(sim_d10v_h) $(sim_regno_h)
-dbxread.o: dbxread.c $(breakpoint_h) $(buildsym_h) $(command_h) \
- $(complaints_h) $(defs_h) $(expression_h) $(gdb_stabs_h) $(gdbcore_h) \
- $(gdbtypes_h) $(language_h) $(objfiles_h) \
- $(stabsread_h) $(symfile_h) $(symtab_h) $(target_h) $(gdb_string_h) \
- $(cp_abi_h)
+dbxread.o: dbxread.c $(defs_h) $(gdb_string_h) $(gdb_obstack_h) $(gdb_stat_h) \
+ $(symtab_h) $(breakpoint_h) $(target_h) $(gdbcore_h) $(libaout_h) \
+ $(symfile_h) $(objfiles_h) $(buildsym_h) $(stabsread_h) \
+ $(gdb_stabs_h) $(demangle_h) $(language_h) $(complaints_h) \
+ $(cp_abi_h) $(aout_aout64_h) $(aout_stab_gnu_h)
delta68-nat.o: delta68-nat.c $(defs_h)
@@ -1431,7 +1442,9 @@ dink32-rom.o: dink32-rom.c $(monitor_h) $(bfd_h) $(gdb_wait_h) $(defs_h) \
dpx2-nat.o: dpx2-nat.c $(defs_h) $(gdbcore_h) $(gdb_string_h)
-dstread.o: dstread.c $(gdb_string_h)
+dstread.o: dstread.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(breakpoint_h) \
+ $(bfd_h) $(symfile_h) $(objfiles_h) $(buildsym_h) $(gdb_obstack_h) \
+ $(gdb_string_h) $(dst_h)
dwarf2cfi.o: dwarf2cfi.c $(defs_h) $(symtab_h) $(symfile_h) $(objfiles_h) \
$(target_h) $(inferior_h) $(regcache_h) $(dwarf2cfi_h)
@@ -1764,12 +1777,14 @@ m32r-tdep.o: m32r-tdep.c $(defs_h) $(frame_h) $(inferior_h) $(target_h) \
p-lang.o: p-lang.c p-lang.h $(defs_h) $(expression_h) $(gdbtypes_h) \
$(language_h) $(parser_defs_h) $(symtab_h) $(gdb_string_h)
-p-typeprint.o: p-typeprint.c p-lang.h $(defs_h) $(expression_h) \
- $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) $(language_h) $(symtab_h) \
- $(target_h) $(typeprint_h) $(value_h) $(gdb_string_h)
+p-typeprint.o: p-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(target_h) \
+ $(language_h) $(p_lang_h) $(typeprint_h) $(gdb_string_h)
-p-valprint.o: p-valprint.c p-lang.h $(defs_h) $(expression_h) $(gdbtypes_h) \
- $(language_h) $(symtab_h) $(valprint_h) $(value_h) $(gdb_string_h)
+p-valprint.o: p-valprint.c $(defs_h) $(gdb_obstack_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(command_h) $(gdbcmd_h) \
+ $(gdbcore_h) $(demangle_h) $(valprint_h) $(typeprint_h) $(language_h) \
+ $(target_h) $(annotate_h) $(p_lang_h) $(cp_abi_h)
m68hc11-tdep.o: m68hc11-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(gdbtypes_h) \
$(gdbcmd_h) $(gdbcore_h) $(gdb_string_h) $(value_h) $(inferior_h) \
@@ -1799,10 +1814,12 @@ mcore-tdep.o: mcore-tdep.c $(defs_h) $(frame_h) $(gdbcmd_h) $(value_h) \
mcore-rom.o: mcore-rom.c $(defs_h) $(gdbcore_h) $(target_h) $(monitor_h) \
$(gdb_string_h) $(regcache_h) $(serial_h)
-mdebugread.o: mdebugread.c $(buildsym_h) $(complaints_h) $(bfd_h) $(defs_h) \
- $(expression_h) $(gdb_stabs_h) $(gdbcore_h) $(gdbtypes_h) \
- $(language_h) $(objfiles_h) $(stabsread_h) \
- $(symfile_h) $(symtab_h) $(gdb_string_h)
+mdebugread.o: mdebugread.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(gdbcore_h) \
+ $(symfile_h) $(objfiles_h) $(gdb_obstack_h) $(buildsym_h) \
+ $(stabsread_h) $(complaints_h) $(demangle_h) $(gdb_assert_h) \
+ $(coff_sym_h) $(coff_symconst_h) $(gdb_stat_h) $(gdb_string_h) \
+ $(bfd_h) $(coff_ecoff_h) $(libaout_h) $(aout_aout64_h) \
+ $(aout_stab_gnu_h) $(expression_h) $(language_h)
mipsm3-nat.o: mipsm3-nat.c $(defs_h) $(inferior_h) $(regcache_h)
@@ -1885,8 +1902,9 @@ nindy-tdep.o: nindy-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(gdbcore_h)
ns32k-tdep.o: ns32k-tdep.c $(bfd_h) $(dis_asm_h) $(defs_h)
-objfiles.o: objfiles.c $(bfd_h) $(defs_h) $(objfiles_h) $(symfile_h) \
- $(symtab_h) $(gdb_string_h) $(breakpoint_h) $(bcache_h)
+objfiles.o: objfiles.c $(defs_h) $(bfd_h) $(symtab_h) $(symfile_h) \
+ $(objfiles_h) $(gdb_stabs_h) $(target_h) $(bcache_h) $(gdb_stat_h) \
+ $(gdb_obstack_h) $(gdb_string_h) $(breakpoint_h) $(mmalloc_h)
solib-osf.o: solib-osf.c $(defs_h) $(inferior_h) $(symtab_h) $(objfiles_h) \
$(symfile_h) $(target_h) $(gdb_string_h) $(solist_h)
@@ -2160,10 +2178,11 @@ xstormy16-tdep.o: xstormy16-tdep.c $(defs_h) $(value_h) $(inferior_h) \
dsrec.o: dsrec.c $(defs_h) srec.h
-stabsread.o: stabsread.c $(bfd_h) $(INCLUDE_DIR)/aout/stab.def \
- $(INCLUDE_DIR)/aout/stab_gnu.h $(buildsym_h) $(complaints_h) \
- $(defs_h) $(gdbtypes_h) $(objfiles_h) $(stabsread_h) $(symfile_h) \
- $(symtab_h) $(gdb_string_h) $(doublest_h)
+stabsread.o: stabsread.c $(defs_h) $(gdb_string_h) $(bfd_h) $(gdb_obstack_h) \
+ $(symtab_h) $(gdbtypes_h) $(expression_h) $(symfile_h) $(objfiles_h) \
+ $(aout_stab_gnu_h) $(libaout_h) $(aout_aout64_h) $(gdb_stabs_h) \
+ $(buildsym_h) $(complaints_h) $(demangle_h) $(language_h) \
+ $(doublest_h) $(stabsread_h)
stack.o: stack.c $(defs_h) $(gdbcmd_h) $(gdbcore_h) $(inferior_h) \
$(language_h) $(target_h) $(gdb_string_h) $(ui_out_h)
@@ -2179,32 +2198,37 @@ ax-gdb.o: ax-gdb.c $(defs_h) $(symtab_h) $(symfile_h) $(gdbtypes_h) \
sun3-nat.o: sun3-nat.c $(defs_h) $(gdbcore_h) $(inferior_h) $(regcache_h)
-symfile.o: symfile.c $(breakpoint_h) $(complaints_h) $(defs_h) \
- $(expression_h) $(gdb_stabs_h) $(gdbcmd_h) $(gdbcore_h) \
- $(gdbtypes_h) $(language_h) $(objfiles_h) $(symfile_h) $(symtab_h) \
- $(target_h) $(gdb_string_h) $(completer_h) $(bcache_h)
+symfile.o: symfile.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(gdbcore_h) \
+ $(frame_h) $(target_h) $(value_h) $(symfile_h) $(objfiles_h) \
+ $(gdbcmd_h) $(breakpoint_h) $(language_h) $(complaints_h) \
+ $(demangle_h) $(inferior_h) $(gdb_stabs_h) $(gdb_obstack_h) \
+ $(completer_h) $(bcache_h) $(gdb_string_h) $(gdb_stat_h)
symm-tdep.o: symm-tdep.c $(defs_h) $(gdbcore_h) $(inferior_h)
symm-nat.o: symm-nat.c $(defs_h) $(gdbcore_h) $(inferior_h) $(regcache_h)
-symmisc.o: symmisc.c $(bfd_h) $(breakpoint_h) $(command_h) $(defs_h) \
- $(expression_h) $(gdbtypes_h) $(language_h) $(objfiles_h) \
- $(symfile_h) $(symtab_h) $(gdb_string_h)
+symmisc.o: symmisc.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(bfd_h) \
+ $(symfile_h) $(objfiles_h) $(breakpoint_h) $(command_h) \
+ $(gdb_obstack_h) $(language_h) $(bcache_h) $(gdb_string_h)
-symtab.o: symtab.c $(call_cmds_h) $(defs_h) $(expression_h) $(frame_h) \
- $(gdbcmd_h) $(gdbcore_h) $(gdbtypes_h) $(language_h) $(objfiles_h) \
- $(gdb_regex_h) $(symfile_h) $(symtab_h) $(target_h) $(value_h) \
- $(gdb_string_h) $(linespec_h) $(cp_abi_h)
+symtab.o: symtab.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(gdbcore_h) \
+ $(frame_h) $(target_h) $(value_h) $(symfile_h) $(objfiles_h) \
+ $(gdbcmd_h) $(call_cmds_h) $(gdb_regex_h) $(expression_h) \
+ $(language_h) $(demangle_h) $(inferior_h) $(linespec_h) \
+ $(filenames_h) $(gdb_obstack_h) $(gdb_string_h) $(gdb_stat_h) \
+ $(cp_abi_h)
linespec.o: linespec.c $(linespec_h) $(defs_h) $(frame_h) $(value_h) \
$(objfiles_h) $(symfile_h) $(completer_h) $(symtab_h) \
$(demangle_h) $(command_h) $(cp_abi_h)
-macroexp.o: macroexp.c $(defs_h) $(macrotab_h)
+macroexp.o: macroexp.c $(defs_h) $(gdb_obstack_h) $(bcache_h) $(macrotab_h) \
+ $(macroexp_h) $(gdb_assert_h)
-macrotab.o: macrotab.c $(defs_h) $(obstack_h) $(objfiles_h) $(symtab_h) \
- $(macrotab_h) $(splay_tree_h) gdb_assert.h $(bcache_h)
+macrotab.o: macrotab.c $(defs_h) $(gdb_obstack_h) $(splay_tree_h) $(symtab_h) \
+ $(symfile_h) $(objfiles_h) $(macrotab_h) $(gdb_assert_h) $(bcache_h) \
+ $(complaints_h)
macroscope.o: macroscope.c $(defs_h) $(macroscope_h)
@@ -2228,9 +2252,9 @@ top.o: top.c $(top_h) $(bfd_h) $(getopt_h) $(readline_headers) $(call_cmds_h) \
$(completer_h) $(version_h) $(ui_out_h) $(doublest_h) \
$(serial_h)
-typeprint.o: typeprint.c $(defs_h) $(expression_h) $(gdbcmd_h) \
- $(gdbcore_h) $(gdbtypes_h) $(language_h) $(symtab_h) $(target_h) \
- $(value_h) $(gdb_string_h) $(cp_abi_h)
+typeprint.o: typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
+ $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(command_h) \
+ $(gdbcmd_h) $(target_h) $(language_h) $(cp_abi_h) $(gdb_string_h)
utils.o: utils.c $(bfd_h) $(defs_h) $(expression_h) $(gdbcmd_h) \
$(language_h) $(target_h) $(terminal_h) $(readline_headers) \
diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index ca123fb..d53d290 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -18,7 +18,7 @@ along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h" /* Binary File Description */
#include "symtab.h"
#include "gdbtypes.h"
diff --git a/gdb/bcache.c b/gdb/bcache.c
index c5173e1..5a310f3 100644
--- a/gdb/bcache.c
+++ b/gdb/bcache.c
@@ -22,7 +22,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bcache.h"
#include "gdb_string.h" /* For memcpy declaration */
diff --git a/gdb/buildsym.c b/gdb/buildsym.c
index f62ecad..2316e96 100644
--- a/gdb/buildsym.c
+++ b/gdb/buildsym.c
@@ -28,7 +28,7 @@
#include "defs.h"
#include "bfd.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "symtab.h"
#include "symfile.h" /* Needed for "struct complaint" */
#include "objfiles.h"
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 41eb0ad..bede194 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -21,7 +21,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h" /* Binary File Description */
#include "symtab.h"
#include "gdbtypes.h"
diff --git a/gdb/ch-typeprint.c b/gdb/ch-typeprint.c
index 011bd12..2adba4c 100644
--- a/gdb/ch-typeprint.c
+++ b/gdb/ch-typeprint.c
@@ -20,7 +20,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h" /* Binary File Description */
#include "symtab.h"
#include "gdbtypes.h"
diff --git a/gdb/ch-valprint.c b/gdb/ch-valprint.c
index 44b1c53..405e86e 100644
--- a/gdb/ch-valprint.c
+++ b/gdb/ch-valprint.c
@@ -21,7 +21,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "valprint.h"
diff --git a/gdb/coffread.c b/gdb/coffread.c
index bd18b4a..52b36c8 100644
--- a/gdb/coffread.c
+++ b/gdb/coffread.c
@@ -28,7 +28,7 @@
#include "breakpoint.h"
#include "bfd.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "gdb_string.h"
#include <ctype.h>
diff --git a/gdb/cp-valprint.c b/gdb/cp-valprint.c
index 7ea9f3f..b7922da 100644
--- a/gdb/cp-valprint.c
+++ b/gdb/cp-valprint.c
@@ -21,7 +21,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "expression.h"
diff --git a/gdb/dbxread.c b/gdb/dbxread.c
index 430e3f5..1d6024a 100644
--- a/gdb/dbxread.c
+++ b/gdb/dbxread.c
@@ -42,7 +42,7 @@
#include <fcntl.h>
#endif
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "gdb_stat.h"
#include "symtab.h"
#include "breakpoint.h"
diff --git a/gdb/dstread.c b/gdb/dstread.c
index 82e5e9c..544d7dd 100644
--- a/gdb/dstread.c
+++ b/gdb/dstread.c
@@ -28,7 +28,7 @@
#include "symfile.h"
#include "objfiles.h"
#include "buildsym.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "gdb_string.h"
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 2beae0f..2eba391 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -23,7 +23,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h"
#include "symtab.h"
#include "gdbtypes.h"
diff --git a/gdb/gdb_obstack.h b/gdb/gdb_obstack.h
new file mode 100644
index 0000000..237830e
--- /dev/null
+++ b/gdb/gdb_obstack.h
@@ -0,0 +1,32 @@
+/* Obstack wrapper for GDB.
+
+ Copyright 2002 Free Software Foundation, Inc.
+
+ This file is part of GDB.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+#if !defined (GDB_OBSTACK_H)
+#define GDB_OBSTACK_H 1
+
+#include "obstack.h"
+
+/* Unless explicitly specified, GDB obstacks always use xmalloc() and
+ xfree(). */
+#define obstack_chunk_alloc xmalloc
+#define obstack_chunk_free xfree
+
+#endif
diff --git a/gdb/macroexp.c b/gdb/macroexp.c
index 061c63a..992c466 100644
--- a/gdb/macroexp.c
+++ b/gdb/macroexp.c
@@ -20,7 +20,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bcache.h"
#include "macrotab.h"
#include "macroexp.h"
diff --git a/gdb/macrotab.c b/gdb/macrotab.c
index bb615a5..accaa7d 100644
--- a/gdb/macrotab.c
+++ b/gdb/macrotab.c
@@ -20,7 +20,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "splay-tree.h"
#include "symtab.h"
#include "symfile.h"
diff --git a/gdb/mdebugread.c b/gdb/mdebugread.c
index 3f32e4c..d920f8d 100644
--- a/gdb/mdebugread.c
+++ b/gdb/mdebugread.c
@@ -47,7 +47,7 @@
#include "gdbcore.h"
#include "symfile.h"
#include "objfiles.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "buildsym.h"
#include "stabsread.h"
#include "complaints.h"
diff --git a/gdb/objfiles.c b/gdb/objfiles.c
index ba55bbb..9c5e49f 100644
--- a/gdb/objfiles.c
+++ b/gdb/objfiles.c
@@ -37,7 +37,7 @@
#include <sys/types.h>
#include "gdb_stat.h"
#include <fcntl.h>
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "gdb_string.h"
#include "breakpoint.h"
diff --git a/gdb/objfiles.h b/gdb/objfiles.h
index 8e2c81b..d319491 100644
--- a/gdb/objfiles.h
+++ b/gdb/objfiles.h
@@ -23,6 +23,7 @@
#if !defined (OBJFILES_H)
#define OBJFILES_H
+#include "gdb_obstack.h" /* For obstack internals. */
struct bcache;
/* This structure maintains information on a per-objfile basis about the
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index e8de788..293de70 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -21,7 +21,7 @@
/* This file is derived from p-typeprint.c */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h" /* Binary File Description */
#include "symtab.h"
#include "gdbtypes.h"
diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c
index c8060a2..06a8216 100644
--- a/gdb/p-valprint.c
+++ b/gdb/p-valprint.c
@@ -21,7 +21,7 @@
/* This file is derived from c-valprint.c */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "expression.h"
diff --git a/gdb/stabsread.c b/gdb/stabsread.c
index 902c5e0..7e6647c 100644
--- a/gdb/stabsread.c
+++ b/gdb/stabsread.c
@@ -29,7 +29,7 @@
#include "defs.h"
#include "gdb_string.h"
#include "bfd.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "symtab.h"
#include "gdbtypes.h"
#include "expression.h"
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 2a68201..9e9435d 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -38,7 +38,7 @@
#include "demangle.h"
#include "inferior.h" /* for write_pc */
#include "gdb-stabs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "completer.h"
#include "bcache.h"
diff --git a/gdb/symmisc.c b/gdb/symmisc.c
index 55f6926..198b2d6 100644
--- a/gdb/symmisc.c
+++ b/gdb/symmisc.c
@@ -29,7 +29,7 @@
#include "objfiles.h"
#include "breakpoint.h"
#include "command.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "language.h"
#include "bcache.h"
diff --git a/gdb/symtab.c b/gdb/symtab.c
index 8973091..c72de44 100644
--- a/gdb/symtab.c
+++ b/gdb/symtab.c
@@ -40,7 +40,7 @@
#include "linespec.h"
#include "filenames.h" /* for FILENAME_CMP */
-#include "obstack.h"
+#include "gdb_obstack.h"
#include <sys/types.h>
#include <fcntl.h>
diff --git a/gdb/symtab.h b/gdb/symtab.h
index 6ea5538..c6da736 100644
--- a/gdb/symtab.h
+++ b/gdb/symtab.h
@@ -25,9 +25,7 @@
/* Some definitions and declarations to go with use of obstacks. */
-#include "obstack.h"
-#define obstack_chunk_alloc xmalloc
-#define obstack_chunk_free xfree
+#include "gdb_obstack.h"
/* Don't do this; it means that if some .o's are compiled with GNU C
and some are not (easy to do accidentally the way we configure
diff --git a/gdb/typeprint.c b/gdb/typeprint.c
index b56610d..f974b7f 100644
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -20,7 +20,7 @@
Boston, MA 02111-1307, USA. */
#include "defs.h"
-#include "obstack.h"
+#include "gdb_obstack.h"
#include "bfd.h" /* Binary File Description */
#include "symtab.h"
#include "gdbtypes.h"