1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/patches/glibc/2.14.1/910-asm-i686.patch Wed Dec 26 13:30:51 2012 +0100
1.3 @@ -0,0 +1,50 @@
1.4 +Submitted By: Matt Burgess <matthew_at_linuxfromscratch_dot_org>
1.5 +Date: 2010-04-18
1.6 +Initial Package Version: 2.11.1
1.7 +Upstream Status: Not Submitted
1.8 +Origin: http://www.eglibc.org/archives/patches/msg00073.html
1.9 +Description: Fixes the following build problem with GCC-4.5.0:
1.10 +
1.11 +/mnt/lfs/sources/libc-build/math/s_frexp.os.dt -MT /mnt/lfs/sources/libc-build/math/s_frexp.os
1.12 +./sysdeps/i386/fpu/s_frexp.S: Assembler messages:
1.13 +./sysdeps/i386/fpu/s_frexp.S:66: Error: invalid identifier for ".ifdef"
1.14 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk at end of line, first unrecognized character is `1'
1.15 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk at end of line, first unrecognized character is `1'
1.16 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk at end of line, first unrecognized character is `1'
1.17 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk at end of line, first unrecognized character is `.'
1.18 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk at end of line, first unrecognized character is `1'
1.19 +./sysdeps/i386/fpu/s_frexp.S:66: Error: expected comma after name `' in .size directive
1.20 +./sysdeps/i386/fpu/s_frexp.S:66: Error: ".endif" without ".if"
1.21 +./sysdeps/i386/fpu/s_frexp.S:66: Error: junk `.get_pc_thunk.dx' after expression
1.22 +make[2]: *** [/mnt/lfs/sources/libc-build/math/s_frexp.os] Error 1
1.23 +
1.24 +diff -Naur glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c
1.25 +--- glibc-2.11.1.orig/nptl/sysdeps/pthread/pt-initfini.c 2009-12-08 20:10:20.000000000 +0000
1.26 ++++ glibc-2.11.1/nptl/sysdeps/pthread/pt-initfini.c 2010-04-17 11:34:06.882681001 +0000
1.27 +@@ -45,6 +45,11 @@
1.28 + /* Embed an #include to pull in the alignment and .end directives. */
1.29 + asm ("\n#include \"defs.h\"");
1.30 +
1.31 ++asm ("\n#if defined __i686 && defined __ASSEMBLER__");
1.32 ++asm ("\n#undef __i686");
1.33 ++asm ("\n#define __i686 __i686");
1.34 ++asm ("\n#endif");
1.35 ++
1.36 + /* The initial common code ends here. */
1.37 + asm ("\n/*@HEADER_ENDS*/");
1.38 +
1.39 +diff -Naur glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h
1.40 +--- glibc-2.11.1.orig/sysdeps/unix/sysv/linux/i386/sysdep.h 2009-12-08 20:10:20.000000000 +0000
1.41 ++++ glibc-2.11.1/sysdeps/unix/sysv/linux/i386/sysdep.h 2010-04-17 11:34:06.882681001 +0000
1.42 +@@ -29,6 +29,10 @@
1.43 + #include <dl-sysdep.h>
1.44 + #include <tls.h>
1.45 +
1.46 ++#if defined __i686 && defined __ASSEMBLER__
1.47 ++#undef __i686
1.48 ++#define __i686 __i686
1.49 ++#endif
1.50 +
1.51 + /* For Linux we can use the system call table in the header file
1.52 + /usr/include/asm/unistd.h
1.53 +