debug/gdb: fix from upstream with newer glibc(siginfo vs siginfo_t, Gentoo gdb-7.4.1 patch)
This is for when you failed to build gdb-native with the error:
gdb-7.4.1/gdb/linux-nat.h:79:18: error: field 'siginfo' has incomplete type"
This is from mirror://gentoo/distfiles/gdb-7.4.1-patches-2.tar.xz
Signed-off-by: "Jang, Bongseo" <graycells@gmail.com>
[yann.morin.1998@free.fr: refresh ptrace_setsiginfo patch]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Message-ID: <4eef2edec3201c50b420.1348370891@localhost.localdomain>
PatchWork-ID: 186179
1 If gcc is configured to generate i686 code or better by default (like
2 when using the --with-arch=pentium3 configure option), then the __i686
3 macro will always be defined automatically and thus screw up the
4 compilation of some .S files.
6 http://bugs.gentoo.org/131108
7 http://sourceware.org/ml/libc-alpha/2006-04/msg00090.html
9 2006-04-25 Mike Frysinger <vapier@gentoo.org>
11 * sysdeps/i386/sysdep.h (__i686): Undefine.
13 Index: glibc-2.4/sysdeps/unix/sysv/linux/i386/sysdep.h
14 ===================================================================
15 --- glibc-2.4/sysdeps/unix/sysv/linux/i386/sysdep.h (revision 1469)
16 +++ glibc-2.4/sysdeps/unix/sysv/linux/i386/sysdep.h (working copy)
18 #include <dl-sysdep.h>
21 +#if defined __i686 && defined __ASSEMBLER__
23 +#define __i686 __i686
26 /* For Linux we can use the system call table in the header file
27 /usr/include/asm/unistd.h
28 Index: glibc-2.4/nptl/sysdeps/pthread/pt-initfini.c
29 ===================================================================
30 --- glibc-2.4/nptl/sysdeps/pthread/pt-initfini.c (revision 1469)
31 +++ glibc-2.4/nptl/sysdeps/pthread/pt-initfini.c (working copy)
33 /* Embed an #include to pull in the alignment and .end directives. */
34 asm ("\n#include \"defs.h\"");
36 +asm ("\n#if defined __i686 && defined __ASSEMBLER__");
37 +asm ("\n#undef __i686");
38 +asm ("\n#define __i686 __i686");
41 /* The initial common code ends here. */
42 asm ("\n/*@HEADER_ENDS*/");