This is the mail archive of the gdb@sourceware.cygnus.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gdbarch.c problem building for cygwin


Chris Faylor wrote:
> 
> i686-pc-cygwin-gcc -c -g -O2    -I. -I/cygnus/src/sourceware/gdb -I/cygnus/src/sourceware/gdb/config -DHAVE_CONFIG_H -I/cygnus/src/sourceware/gdb/../include/opcode -I/cygnus/src/sourceware/gdb/../readline/.. -I../bfd -I/cygnus/src/sourceware/gdb/../bfd  -I/cygnus/src/sourceware/gdb/../include -I../intl -I/cygnus/src/sourceware/gdb/../intl -DGDBTK -Wimplicit -Wreturn-type -Wcomment -Wtrigraphs -Wformat -Wparentheses -Wpointer-arith -Wuninitialized  /cygnus/src/sourceware/gdb/gdbarch.c
> /cygnus/src/sourceware/gdb/gdbarch.c:926: macro `STRINGX' used with too many (4) args
> 
> Here is the offending line:
> 
> #ifdef FIX_CALL_DUMMY
>   fprintf_unfiltered (file,
>                       "gdbarch_dump: %s # %s\n",
>                       "FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p)",
>                       XSTRING (FIX_CALL_DUMMY (dummy, pc, fun, nargs, args, type, gcc_p)));
>                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> #endif
> 
> FIX_CALL_DUMMY expands to a { .. } block on i386 so this doesn't work too well.
> Changing the line to this:
> 
>                       XSTRING ((FIX_CALL_DUMMY (dummy, pc, fun, nargs, args, type, gcc_p))));
>                                ^                                                          ^
> 
> "fixes" the problem but I fear that we would just be using a gcc
> specific extension by doing this.

Very gcc specific.  I'll go through and see which ones can't be
expanded, sigh.

	sorry,
		Andrew

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]