aboutsummaryrefslogtreecommitdiff
path: root/packages/gcc
diff options
context:
space:
mode:
authorChris Packham <judge.packham@gmail.com>2022-05-16 21:28:59 +1200
committerChris Packham <judge.packham@gmail.com>2022-05-18 20:17:01 +1200
commit1b6ad7cd48e0849072e2372826498c01b56b7fc9 (patch)
tree24fff509d33b53b58caa369c16f9a217e372b6b1 /packages/gcc
parentb17792c52cd6ddc1600bd10f7df5e2c74056f19f (diff)
downloadcrosstool-ng-1b6ad7cd48e0849072e2372826498c01b56b7fc9.tar.gz
crosstool-ng-1b6ad7cd48e0849072e2372826498c01b56b7fc9.tar.bz2
crosstool-ng-1b6ad7cd48e0849072e2372826498c01b56b7fc9.zip
gcc: Bring in fix for libsanitizer on mips64
The kernel's struct stat is 104 bytes when compiling for _MIPS_SIM_ABI64. Set struct_kernel_stat_sz to match. Fixes #1733 Signed-off-by: Chris Packham <judge.packham@gmail.com>
Diffstat (limited to 'packages/gcc')
-rw-r--r--packages/gcc/11.3.0/0010-libsanitizer-mips64-Set-struct_kernel_stat_sz-to-mat.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/packages/gcc/11.3.0/0010-libsanitizer-mips64-Set-struct_kernel_stat_sz-to-mat.patch b/packages/gcc/11.3.0/0010-libsanitizer-mips64-Set-struct_kernel_stat_sz-to-mat.patch
new file mode 100644
index 00000000..8d05ca65
--- /dev/null
+++ b/packages/gcc/11.3.0/0010-libsanitizer-mips64-Set-struct_kernel_stat_sz-to-mat.patch
@@ -0,0 +1,31 @@
+From ac6e15a2776e8fffdbd108213e8690c9f30a7380 Mon Sep 17 00:00:00 2001
+From: Chris Packham <chris.packham@alliedtelesis.co.nz>
+Date: Mon, 16 May 2022 20:55:36 +1200
+Subject: [PATCH] libsanitizer: mips64: Set struct_kernel_stat_sz to match the
+ kernel
+
+The kernel's struct stat is 104 bytes when compiling for
+_MIPS_SIM_ABI64. Set struct_kernel_stat_sz to match.
+
+Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
+Link: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105614
+---
+ libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h
+index 83861105a509..326419a5d613 100644
+--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h
++++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h
+@@ -83,7 +83,7 @@ const unsigned struct_kernel_stat64_sz = 104;
+ #elif defined(__mips__)
+ const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
+ ? FIRST_32_SECOND_64(104, 128)
+- : FIRST_32_SECOND_64(144, 216);
++ : FIRST_32_SECOND_64(144, 104);
+ const unsigned struct_kernel_stat64_sz = 104;
+ #elif defined(__s390__) && !defined(__s390x__)
+ const unsigned struct_kernel_stat_sz = 64;
+--
+2.36.1
+