RFA: osabi.c correctness patch (Was: new build failure)

Elena Zannoni ezannoni@redhat.com
Tue Aug 27 15:32:00 GMT 2002


Oh, right. I hope Joel doesn't mind.
I think your patch is ok, and fairly obvious.

Elena


Tom Tromey writes:
 > >>>>> "Elena" == Elena Zannoni <ezannoni@redhat.com> writes:
 > 
 > >> ../../src/gdb/breakpoint.c:2732: warning: implicit declaration of function `copy_command_lines'
 > 
 > Elena> I am checking in a fix... hold on.
 > 
 > FYI, it looks like the problem was caused by an incomplete commit of
 > this patch:
 > 
 >     2002-08-26  Joel Brobecker  <brobecker@gnat.com>
 > 
 >             * cli/cli-script.c (copy_command_lines): New function.
 >             * defs.h (copy_command_lines): Export.
 > 
 > Your fix is fine by me, but the original author(s) may disagree.
 > 
 > I'm still working on getting gdb to build with -Werror.
 > I started by turning off the TUI; even with a patch for the readline
 > problem I ran into another warning.  I don't actually use the TUI, and
 > I want to use a new gdb today, so disabling it was expedient.
 > 
 > After this I got an error building osabi.c.  strcmp was implicitly
 > defined.  Patch appended.  The Makefile fix also includes a minor
 > whitespace bug pointed out by the makefile mode in Emacs.
 > 
 > Ok to commit?
 > 
 > Incidentally: gdb_string.h relies on some defines brought in by
 > config.h.  But not every file includes config.h first.  For instance,
 > ada-lang.c incorrectly includes some files before defs.h (I found this
 > by accident).
 > 
 > There's another build bug after this one.
 > 
 > Tom
 > 
 > 
 > Index: ChangeLog
 > from  Tom Tromey  <tromey@redhat.com>
 > 
 > 	* Makefile.in (osabi.o): Update dependencies.
 > 	* osabi.c: Include gdb_string.h.
 > 
 > Index: Makefile.in
 > ===================================================================
 > RCS file: /cvs/src/src/gdb/Makefile.in,v
 > retrieving revision 1.250
 > diff -u -r1.250 Makefile.in
 > --- Makefile.in 27 Aug 2002 19:06:34 -0000 1.250
 > +++ Makefile.in 27 Aug 2002 20:25:40 -0000
 > @@ -1740,7 +1740,7 @@
 >  	$(gdbtypes_h) $(language_h) $(objfiles_h) $(symfile_h) $(symtab_h) \
 >  	$(target_h) $(value_h) $(gdb_string_h) $(wrapper_h) $(cp_abi_h)
 >  
 > -osabi.o: osabi.c $(defs_h) $(BFD_SRC)/elf-bfd.h
 > +osabi.o: osabi.c $(gdb_string_h) $(defs_h) $(BFD_SRC)/elf-bfd.h
 >  
 >  go32-nat.o: go32-nat.c $(defs_h) $(inferior_h) $(gdb_wait_h) $(gdbcore_h) \
 >  	$(command_h) $(floatformat_h) $(target_h) i387-tdep.h $(regcache_h)
 > @@ -1753,7 +1753,7 @@
 >  
 >  gnu-v3-abi.o: gnu-v3-abi.c $(defs_h) $(value_h) $(cp_abi_h) $(demangle_h) \
 >  	$(gdb_assert_h) $(gdb_string_h)
 > - 
 > +
 >  h8300-tdep.o: h8300-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(dis_asm_h) \
 >  	$(gdbcmd_h) $(gdbtypes_h) $(gdbcore_h) $(gdb_string_h) $(value_h) \
 >  	$(regcache_h)
 > Index: osabi.c
 > ===================================================================
 > RCS file: /cvs/src/src/gdb/osabi.c,v
 > retrieving revision 1.6
 > diff -u -r1.6 osabi.c
 > --- osabi.c 18 Aug 2002 17:59:57 -0000 1.6
 > +++ osabi.c 27 Aug 2002 20:25:41 -0000
 > @@ -19,6 +19,7 @@
 >     Boston, MA 02111-1307, USA.  */
 >  
 >  #include "defs.h"
 > +#include "gdb_string.h"
 >  #include "osabi.h"
 >  
 >  #include "elf-bfd.h"



More information about the Gdb-patches mailing list