From 0097a8249ca2d1a498b457019db15d3540a259f3 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Sat, 20 Feb 2010 17:19:15 +0100 Subject: add vendor string "openadk" to toolchain triplet With this change you can compile toolchains even when host cpu arch is identical to target cpu arch. --- toolchain/glibc/patches/longjmp_chk.patch | 56 +++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 toolchain/glibc/patches/longjmp_chk.patch (limited to 'toolchain/glibc/patches') diff --git a/toolchain/glibc/patches/longjmp_chk.patch b/toolchain/glibc/patches/longjmp_chk.patch new file mode 100644 index 000000000..b2590460c --- /dev/null +++ b/toolchain/glibc/patches/longjmp_chk.patch @@ -0,0 +1,56 @@ +diff -Nur glibc-2.11.orig/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S glibc-2.11/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S +--- glibc-2.11.orig/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S 2009-10-30 18:17:08.000000000 +0100 ++++ glibc-2.11/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S 2010-02-19 08:06:22.000000000 +0100 +@@ -33,10 +33,10 @@ + cfi_register(%ebx,%ecx); \ + LOAD_PIC_REG (bx); \ + leal longjmp_msg@GOTOFF(%ebx), %eax; \ +- call __GI___fortify_fail@PLT ++ call HIDDEN_JUMPTARGET(__fortify_fail) + #else + # define CALL_FAIL movl $longjmp_msg, %eax; \ +- call __fortify_fail ++ call HIDDEN_JUMPTARGET(__fortify_fail) + #endif + + +diff -Nur glibc-2.11.orig/sysdeps/unix/sysv/linux/ia64/____longjmp_chk.S glibc-2.11/sysdeps/unix/sysv/linux/ia64/____longjmp_chk.S +--- glibc-2.11.orig/sysdeps/unix/sysv/linux/ia64/____longjmp_chk.S 2009-10-30 18:17:08.000000000 +0100 ++++ glibc-2.11/sysdeps/unix/sysv/linux/ia64/____longjmp_chk.S 2010-02-19 08:06:22.000000000 +0100 +@@ -30,19 +30,13 @@ + + #define __longjmp ____longjmp_chk + +-#ifdef PIC +-# define CALL_FAIL __GI___fortify_fail +-#else +-# define CALL_FAIL __fortify_fail +-#endif +- + #define CHECK_RSP(reg) \ + cmp.ltu p0, p8 = reg, r12; \ + (p8) br.cond.dpnt .Lok;; \ + addl r28 = @ltoffx(longjmp_msg#), r1;; \ + ld8.mov r28 = [r28], longjmp_msg#;; \ + ld8 out0 = [r28]; \ +- br.call.sptk.many b0 = CALL_FAIL#;; \ ++ br.call.sptk.many b0 = HIDDEN_JUMPTARGET(__fortify_fail)#;; \ + .Lok: + + #include "__longjmp.S" +diff -Nur glibc-2.11.orig/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S glibc-2.11/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S +--- glibc-2.11.orig/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S 2009-10-30 18:17:08.000000000 +0100 ++++ glibc-2.11/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S 2010-02-19 08:06:22.000000000 +0100 +@@ -31,10 +31,10 @@ + + #ifdef PIC + # define CALL_FAIL leaq longjmp_msg(%rip), %rdi; \ +- call __GI___fortify_fail ++ call HIDDEN_JUMPTARGET(__fortify_fail) + #else + # define CALL_FAIL movq $longjmp_msg, %rdi; \ +- call __fortify_fail ++ call HIDDEN_JUMPTARGET(__fortify_fail) + #endif + + #define CHECK_RSP(reg) \ -- cgit v1.2.3