mirror of
https://github.com/macports/macports-ports.git
synced 2026-07-12 18:20:25 -07:00
This rolls up backports of the following fixes for later llvm versions to llvm-12:93df941348clang-14: Fix build under Xcode 152605e66ff7lldb-14: fix build with macOS ≥ 14 SDK (Xcode ≥ 15)aa0bc47391clang-14: Move libc++*.* libraries to libc++ sub-dir, fix install names49df5ce7f1clang-14, llvm-14: restore functionality on macOS 15 (Xcode 16) It also enables lldb-12 on macOS ≥ 14, where it was previously separately disabled. References: https://trac.macports.org/ticket/68257 References: https://trac.macports.org/ticket/70779
48 lines
2.0 KiB
Diff
48 lines
2.0 KiB
Diff
From 786c10cd82a78c210379700b72cf18a018e1e1f7 Mon Sep 17 00:00:00 2001
|
||
From: Mark Mentovai <mark@mentovai.com>
|
||
Date: Thu, 28 Sep 2023 11:18:41 -0400
|
||
Subject: [PATCH] [sanitizer] Use consistent checks for XDR
|
||
MIME-Version: 1.0
|
||
Content-Type: text/plain; charset=UTF-8
|
||
Content-Transfer-Encoding: 8bit
|
||
|
||
This is a backport of 28800c2e18972935cd4f942aa428c5e6cc4c1670
|
||
(https://reviews.llvm.org/D130060), which is in llvm-15, to llvm-14,
|
||
however it’s been adapted to be
|
||
pre-8246b2e156568c31e71e16cbaf4c14d316e7c06e
|
||
(https://reviews.llvm.org/D126263), which renamed SANITIZER_MAC (the
|
||
macro in llvm-14) to SANITIZER_APPLE (the macro in llvm-15 and later).
|
||
|
||
The original change’s description:
|
||
|
||
> sanitizer_platform_limits_posix.h defines `__sanitizer_XDR ` if
|
||
> `SANITIZER_LINUX && !SANITIZER_ANDROID`, but
|
||
> sanitizer_platform_limits_posix.cpp tries to check it if
|
||
> `HAVE_RPC_XDR_H`. This coincidentally works because macOS has a broken
|
||
> <rpc/xdr.h> which causes `HAVE_RPC_XDR_H` to be 0, but if <rpc/xdr.h>
|
||
> is fixed then clang fails to compile on macOS. Restore the platform
|
||
> checks so that <rpc/xdr.h> can be fixed on macOS.
|
||
|
||
This has become important with Xcode 15, which contains the macOS 14
|
||
SDK, which does have a fixed <rpc/xdr.h>.
|
||
---
|
||
.../lib/sanitizer_common/sanitizer_platform_limits_posix.cpp | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
|
||
index 32b8f47ed633..6cefef3f3327 100644
|
||
--- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
|
||
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
|
||
@@ -1250,7 +1250,7 @@ CHECK_SIZE_AND_OFFSET(group, gr_passwd);
|
||
CHECK_SIZE_AND_OFFSET(group, gr_gid);
|
||
CHECK_SIZE_AND_OFFSET(group, gr_mem);
|
||
|
||
-#if HAVE_RPC_XDR_H
|
||
+#if HAVE_RPC_XDR_H && !SANITIZER_MAC
|
||
CHECK_TYPE_SIZE(XDR);
|
||
CHECK_SIZE_AND_OFFSET(XDR, x_op);
|
||
CHECK_SIZE_AND_OFFSET(XDR, x_ops);
|
||
--
|
||
2.42.0
|
||
|