-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
63 additions
and
2 deletions.
There are no files selected for viewing
61 changes: 61 additions & 0 deletions
61
pkgs/development/compilers/gcc/8/0001-Fix-build-with-glibc-2.31.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
From 8d87a4ae8d48e837082198ea985241aaf5ecfbcb Mon Sep 17 00:00:00 2001 | ||
From: Maximilian Bosch <[email protected]> | ||
Date: Thu, 20 Feb 2020 17:26:04 +0100 | ||
Subject: [PATCH] Fix build with glibc 2.31 | ||
|
||
--- | ||
.../sanitizer_platform_limits_posix.cc | 5 +++-- | ||
.../sanitizer_platform_limits_posix.h | 15 +-------------- | ||
2 files changed, 4 insertions(+), 16 deletions(-) | ||
|
||
diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc | ||
index a915d37cd..5c720b2e7 100644 | ||
--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc | ||
+++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc | ||
@@ -1147,8 +1147,9 @@ CHECK_SIZE_AND_OFFSET(ipc_perm, uid); | ||
CHECK_SIZE_AND_OFFSET(ipc_perm, gid); | ||
CHECK_SIZE_AND_OFFSET(ipc_perm, cuid); | ||
CHECK_SIZE_AND_OFFSET(ipc_perm, cgid); | ||
-#if !defined(__aarch64__) || !SANITIZER_LINUX || __GLIBC_PREREQ (2, 21) | ||
-/* On aarch64 glibc 2.20 and earlier provided incorrect mode field. */ | ||
+#if !SANITIZER_LINUX || __GLIBC_PREREQ (2, 31) | ||
+/* glibc 2.30 and earlier provided 16-bit mode field instead of 32-bit | ||
+ on many architectures. */ | ||
CHECK_SIZE_AND_OFFSET(ipc_perm, mode); | ||
#endif | ||
|
||
diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
index 4d11d0717..9c1429623 100644 | ||
--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
+++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | ||
@@ -210,26 +210,13 @@ namespace __sanitizer { | ||
u64 __unused1; | ||
u64 __unused2; | ||
#elif defined(__sparc__) | ||
-#if defined(__arch64__) | ||
unsigned mode; | ||
- unsigned short __pad1; | ||
-#else | ||
- unsigned short __pad1; | ||
- unsigned short mode; | ||
unsigned short __pad2; | ||
-#endif | ||
unsigned short __seq; | ||
unsigned long long __unused1; | ||
unsigned long long __unused2; | ||
-#elif defined(__mips__) || defined(__aarch64__) || defined(__s390x__) | ||
- unsigned int mode; | ||
- unsigned short __seq; | ||
- unsigned short __pad1; | ||
- unsigned long __unused1; | ||
- unsigned long __unused2; | ||
#else | ||
- unsigned short mode; | ||
- unsigned short __pad1; | ||
+ unsigned int mode; | ||
unsigned short __seq; | ||
unsigned short __pad2; | ||
#if defined(__x86_64__) && !defined(_LP64) | ||
-- | ||
2.25.0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters