]> code.ossystems Code Review - openembedded-core.git/commitdiff
eglibc: fix build for armv4 machines
authorDmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Wed, 3 Aug 2011 12:12:37 +0000 (16:12 +0400)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 4 Aug 2011 14:01:18 +0000 (15:01 +0100)
eglibc builds for arm-eabi unconditionally enables the libc-do-syscall.S
file, which contains thumb assembly. It's unused in arm-eabi-nothumb case,
so just ifdef the actual code.

V2: use the patch from oe.dev.

The patch is submitted to sourceware bugzilla by Khem Raj back in October
of 2010, but the status is still UNCONFIRMED and the patch isn't commited.

Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Cc: Khem Raj <raj.khem@gmail.com>
meta/recipes-core/eglibc/eglibc-2.12/armv4-eabi-compile-fix.patch [new file with mode: 0644]
meta/recipes-core/eglibc/eglibc-2.13/armv4-eabi-compile-fix.patch [new file with mode: 0644]
meta/recipes-core/eglibc/eglibc_2.12.bb
meta/recipes-core/eglibc/eglibc_2.13.bb

diff --git a/meta/recipes-core/eglibc/eglibc-2.12/armv4-eabi-compile-fix.patch b/meta/recipes-core/eglibc/eglibc-2.12/armv4-eabi-compile-fix.patch
new file mode 100644 (file)
index 0000000..c2407ee
--- /dev/null
@@ -0,0 +1,25 @@
+Source: http://sourceware.org/bugzilla/show_bug.cgi?id=12097
+Upstream-Status: Submitted
+
+The patch should be merged into glibc-ports
+
+-Khem
+Index: libc/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
+===================================================================
+--- libc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
++++ libc/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
+@@ -16,6 +16,8 @@
+    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+    02111-1307 USA.  */
++#if defined(__thumb__)
++
+ #include <sysdep.h>
+ /* Out-of-line syscall stub.  We expect the system call number in ip
+@@ -41,3 +43,5 @@ ENTRY (__libc_do_syscall)
+       pop     {r7, pc}
+       .fnend
+ END (__libc_do_syscall)
++
++#endif /* __thumb__ */
diff --git a/meta/recipes-core/eglibc/eglibc-2.13/armv4-eabi-compile-fix.patch b/meta/recipes-core/eglibc/eglibc-2.13/armv4-eabi-compile-fix.patch
new file mode 100644 (file)
index 0000000..c2407ee
--- /dev/null
@@ -0,0 +1,25 @@
+Source: http://sourceware.org/bugzilla/show_bug.cgi?id=12097
+Upstream-Status: Submitted
+
+The patch should be merged into glibc-ports
+
+-Khem
+Index: libc/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
+===================================================================
+--- libc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
++++ libc/ports/sysdeps/unix/sysv/linux/arm/eabi/libc-do-syscall.S
+@@ -16,6 +16,8 @@
+    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+    02111-1307 USA.  */
++#if defined(__thumb__)
++
+ #include <sysdep.h>
+ /* Out-of-line syscall stub.  We expect the system call number in ip
+@@ -41,3 +43,5 @@ ENTRY (__libc_do_syscall)
+       pop     {r7, pc}
+       .fnend
+ END (__libc_do_syscall)
++
++#endif /* __thumb__ */
index 3a95b59fb905f7ced3d87cd7fc557e7644a42706..ce16bd69a9a772399c00af0ded7e05ed6880cb7b 100644 (file)
@@ -11,6 +11,7 @@ SRC_URI = "svn://www.eglibc.org/svn/branches/;module=${EGLIBC_BRANCH};proto=http
            file://IO-acquire-lock-fix.patch \
            file://shorten-build-commands.patch \
            file://mips-rld-map-check.patch \
+           file://armv4-eabi-compile-fix.patch \
            file://etc/ld.so.conf \
            file://generate-supported.mk \
          "
index d9935bea025e6b630b90ffb9308755b345f8382f..ddca50fe8b88ca264514dbc427f882323d0ccc38 100644 (file)
@@ -13,6 +13,7 @@ SRC_URI = "svn://www.eglibc.org/svn/branches/;module=${EGLIBC_BRANCH};proto=http
            file://shorten-build-commands.patch \
            file://mips-rld-map-check.patch \
            file://stack-protector-test.patch \
+           file://armv4-eabi-compile-fix.patch \
            file://etc/ld.so.conf \
            file://generate-supported.mk \
            file://glibc_bug_fix_12454.patch \