Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* Patch for building gdb on arm-netbsd
@ 2002-01-09  5:34 Richard Earnshaw
  2002-01-09  6:15 ` Eli Zaretskii
  0 siblings, 1 reply; 8+ messages in thread
From: Richard Earnshaw @ 2002-01-09  5:34 UTC (permalink / raw)
  To: gdb-patches; +Cc: Richard.Earnshaw

[-- Attachment #1: Type: text/plain, Size: 557 bytes --]

Following the rules for converting to multi-arch, step one says we must 
get it all to compile...  So:

The following patch is needed to enable building of gdb on arm-netbsd.  
The definition of IN_SIGTRAMP tests NAME for being NULL and if not calls 
STREQ to compare the strings.  However, STREQ dereferences the pointers 
directly and this causes a compile time error for the NULL pointer (since 
*(0) is not defined).

<date>  Richard Earnshaw (rearnsha@arm.com)

	* arm-tdep.c (arm_init_extra_frame_info): Cast NULL argument of
	IN_SIGTRAMP to char *.


[-- Attachment #2: sigtramp.patch --]
[-- Type: text/x-patch , Size: 879 bytes --]

Index: arm-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/arm-tdep.c,v
retrieving revision 1.25
diff -p -r1.25 arm-tdep.c
*** arm-tdep.c	2002/01/05 04:30:15	1.25
--- arm-tdep.c	2002/01/09 13:24:50
*************** arm_init_extra_frame_info (int fromleaf,
*** 1060,1066 ****
       to IN_SIGTRAMP.  */
  
    if (SIGCONTEXT_REGISTER_ADDRESS_P () 
!       && (fi->signal_handler_caller || IN_SIGTRAMP (fi->pc, 0)))
      {
        for (reg = 0; reg < NUM_REGS; reg++)
  	fi->fsr.regs[reg] = SIGCONTEXT_REGISTER_ADDRESS (sp, fi->pc, reg);
--- 1060,1066 ----
       to IN_SIGTRAMP.  */
  
    if (SIGCONTEXT_REGISTER_ADDRESS_P () 
!       && (fi->signal_handler_caller || IN_SIGTRAMP (fi->pc, (char *)0)))
      {
        for (reg = 0; reg < NUM_REGS; reg++)
  	fi->fsr.regs[reg] = SIGCONTEXT_REGISTER_ADDRESS (sp, fi->pc, reg);

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2002-01-13 16:28 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-01-09  5:34 Patch for building gdb on arm-netbsd Richard Earnshaw
2002-01-09  6:15 ` Eli Zaretskii
2002-01-09  6:25   ` Richard Earnshaw
2002-01-09  9:21   ` Andrew Cagney
2002-01-09  9:29     ` Richard Earnshaw
2002-01-09  9:54       ` Andrew Cagney
2002-01-09 10:45     ` Elena Zannoni
2002-01-13  8:28       ` Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox