From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6694 invoked by alias); 3 Jan 2003 22:06:06 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 6682 invoked from network); 3 Jan 2003 22:06:05 -0000 Received: from unknown (63.119.183.65) by 209.249.29.67 with QMTP; 3 Jan 2003 22:06:05 -0000 Received: (qmail 11369 invoked from network); 3 Jan 2003 22:04:09 -0000 Received: from cpe-24-221-209-215.co.sprintbbd.net (HELO doc.com) (24.221.209.215) by external1 with SMTP; 3 Jan 2003 22:04:09 -0000 Message-ID: <3E16093D.3070907@doc.com> Date: Fri, 03 Jan 2003 22:06:00 -0000 From: Adam Fedor User-Agent: Mozilla/5.0 (X11; U; Linux ppc; en-US; rv:1.1) Gecko/20020905 X-Accept-Language: en-us, en MIME-Version: 1.0 To: GDB Patches Subject: [RFA] Compile objc-lang.c, objc-exp.tab.c [1/5] Content-Type: multipart/mixed; boundary="------------090407090003000101070909" X-SW-Source: 2003-01/txt/msg00101.txt.bz2 This is a multi-part message in MIME format. --------------090407090003000101070909 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-length: 744 Now that I'm almost done, I finally understand the patch lingo (Thanks Michael)! This is a repost of the first of five final patches for ObjC suppport: http://sources.redhat.com/ml/gdb-patches/2003-01/msg00049.html The other two that I also need approval for are: http://sources.redhat.com/ml/gdb-patches/2003-01/msg00050.html http://sources.redhat.com/ml/gdb-patches/2003-01/msg00080.html and two more (symtab.c, and linespec.c) will be coming soon. --- A new year brings a final push to get Objective-C support in gdb. This patch enables compilation and linking of the Objective-C files. I need this now since the remaining patches require so many of the Objective-C functions that it would be pointless to submit them otherwise. --------------090407090003000101070909 Content-Type: text/plain; name="objc18.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="objc18.patch" Content-length: 4638 2003-01-02 Adam Fedor * Makefile.in (COMMON_OBS): Add objc-lang.o (YYOBJ): Add objc-exp.tab.o (maint.o, utils.o): Add $(objc_lang_h) * maint.c (maintenance_demangle): Uncomment language_objc case. * utils.c (fprintf_symbol_filtered): Likewise. * parser-defs.h (start_msglist, add_msglist, end_msglist): Declare Objective-C parsing functions (from objc-lang.c). Index: Makefile.in =================================================================== RCS file: /cvs/src/src/gdb/Makefile.in,v retrieving revision 1.302 diff -u -p -r1.302 Makefile.in --- Makefile.in 2 Jan 2003 20:29:15 -0000 1.302 +++ Makefile.in 3 Jan 2003 03:06:24 -0000 @@ -820,7 +820,7 @@ COMMON_OBS = version.o blockframe.o brea exec.o bcache.o objfiles.o minsyms.o maint.o demangle.o \ dbxread.o coffread.o elfread.o \ dwarfread.o dwarf2read.o mipsread.o stabsread.o corefile.o \ - c-lang.o f-lang.o \ + c-lang.o objc-lang.o f-lang.o \ ui-out.o cli-out.o \ varobj.o wrapper.o \ jv-lang.o jv-valprint.o jv-typeprint.o \ @@ -847,6 +847,7 @@ YYFILES = c-exp.tab.c \ jv-exp.tab.c \ f-exp.tab.c m2-exp.tab.c p-exp.tab.c YYOBJ = c-exp.tab.o \ + objc-exp.tab.o \ jv-exp.tab.o \ f-exp.tab.o m2-exp.tab.o p-exp.tab.o @@ -1878,7 +1879,8 @@ main.o: main.c $(defs_h) $(top_h) $(targ $(event_loop_h) $(ui_out_h) $(main_h) maint.o: maint.c $(defs_h) $(command_h) $(gdbcmd_h) $(symtab_h) \ $(gdbtypes_h) $(demangle_h) $(gdbcore_h) $(expression_h) \ - $(language_h) $(symfile_h) $(objfiles_h) $(value_h) $(cli_decode_h) + $(language_h) $(symfile_h) $(objfiles_h) $(value_h) $(cli_decode_h) \ + $(objc_lang_h) mcore-rom.o: mcore-rom.c $(defs_h) $(gdbcore_h) $(target_h) $(monitor_h) \ $(gdb_string_h) $(regcache_h) $(serial_h) mcore-tdep.o: mcore-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(value_h) \ @@ -2240,7 +2242,8 @@ ui-out.o: ui-out.c $(defs_h) $(gdb_strin utils.o: utils.c $(config_h) $(defs_h) $(gdb_assert_h) $(gdb_string_h) \ $(event_top_h) $(gdbcmd_h) $(serial_h) $(bfd_h) $(target_h) \ $(demangle_h) $(expression_h) $(language_h) $(annotate_h) \ - $(filenames_h) $(inferior_h) $(mmalloc_h) $(charset_h) $(readline_h) + $(filenames_h) $(inferior_h) $(mmalloc_h) $(charset_h) $(readline_h) \ + $(objc_lang_h) uw-thread.o: uw-thread.c $(defs_h) $(gdbthread_h) $(target_h) $(inferior_h) \ $(regcache_h) $(gregset_h) v850-tdep.o: v850-tdep.c $(defs_h) $(frame_h) $(inferior_h) $(target_h) \ Index: maint.c =================================================================== RCS file: /cvs/src/src/gdb/maint.c,v retrieving revision 1.30 diff -u -p -r1.30 maint.c --- maint.c 24 Dec 2002 03:57:58 -0000 1.30 +++ maint.c 3 Jan 2003 03:06:25 -0000 @@ -35,6 +35,7 @@ #include "symfile.h" #include "objfiles.h" #include "value.h" +#include "objc-lang.h" #include "cli/cli-decode.h" @@ -154,9 +155,8 @@ maintenance_demangle (char *args, int fr switch (current_language->la_language) { case language_objc: - /* Commented out until ObjC handling is enabled. */ - /* demangled = objc_demangle (args); */ - /* break; */ + demangled = objc_demangle (args); + break; case language_cplus: default: demangled = cplus_demangle (args, DMGL_ANSI | DMGL_PARAMS); Index: parser-defs.h =================================================================== RCS file: /cvs/src/src/gdb/parser-defs.h,v retrieving revision 1.15 diff -u -p -r1.15 parser-defs.h --- parser-defs.h 19 Nov 2002 03:15:01 -0000 1.15 +++ parser-defs.h 3 Jan 2003 03:06:25 -0000 @@ -223,4 +223,9 @@ struct op_print extern void parser_fprintf (FILE *, const char *, ...) ATTR_FORMAT (printf, 2 ,3); +/* for parsing Objective C */ +extern void start_msglist (void); +extern void add_msglist (struct stoken *str, int addcolon); +extern int end_msglist (void); + #endif /* PARSER_DEFS_H */ Index: utils.c =================================================================== RCS file: /cvs/src/src/gdb/utils.c,v retrieving revision 1.88 diff -u -p -r1.88 utils.c --- utils.c 2 Jan 2003 14:27:27 -0000 1.88 +++ utils.c 3 Jan 2003 03:06:35 -0000 @@ -46,6 +46,7 @@ #include "charset.h" #include "annotate.h" #include "filenames.h" +#include "objc-lang.h" #include "inferior.h" /* for signed_pointer_to_address */ @@ -2310,9 +2311,8 @@ fprintf_symbol_filtered (struct ui_file demangled = cplus_demangle (name, arg_mode | DMGL_JAVA); break; case language_objc: - /* Commented out until ObjC handling is enabled. */ - /*demangled = objc_demangle (name);*/ - /*break;*/ + demangled = objc_demangle (name); + break; default: demangled = NULL; break; --------------090407090003000101070909--