From cd8fb0998a3ca507efcbb279c34052dbfc72834c Mon Sep 17 00:00:00 2001
From: klzgrad <kizdiv@gmail.com>
Date: Mon, 10 Jun 2024 16:45:07 +0800
Subject: [PATCH] musl: allocator: Disable ifunc on aarch64

---
 .../partition_allocator/src/partition_alloc/aarch64_support.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/base/allocator/partition_allocator/src/partition_alloc/aarch64_support.h b/src/base/allocator/partition_allocator/src/partition_alloc/aarch64_support.h
index 600d4ed784..aa9eda75e2 100644
--- a/src/base/allocator/partition_allocator/src/partition_alloc/aarch64_support.h
+++ b/src/base/allocator/partition_allocator/src/partition_alloc/aarch64_support.h
@@ -10,7 +10,9 @@
 #include "partition_alloc/build_config.h"
 #include "partition_alloc/buildflags.h"
 
-#if PA_BUILDFLAG(IS_ANDROID) || PA_BUILDFLAG(IS_LINUX)
+#if defined(__MUSL__)
+// Musl does not support ifunc.
+#elif PA_BUILDFLAG(IS_ANDROID) || PA_BUILDFLAG(IS_LINUX)
 #define HAS_HW_CAPS
 #endif