Skip to content

VERY experimental Nintendo Switch 2 emulator

C++

Fix aarch and android builds (#4576)

PavelBARABANOV305f40100d76
diff --git a/src/android/app/build.gradle.kts b/src/android/app/build.gradle.kts
index 3ae6d73994..69dd6a8e4f 100644
--- a/src/android/app/build.gradle.kts
+++ b/src/android/app/build.gradle.kts
@@ -259,7 +259,7 @@ android {
externalNativeBuild {
cmake {
- version = "3.31.6"
+ version = "3.31.5"
path = file("${edenDir}/CMakeLists.txt")
}
}
diff --git a/src/core/arm/nce/arm_nce_asm_definitions.h b/src/core/arm/nce/arm_nce_asm_definitions.h
index 8ea4383f73..ec6abd62d2 100644
--- a/src/core/arm/nce/arm_nce_asm_definitions.h
+++ b/src/core/arm/nce/arm_nce_asm_definitions.h
@@ -1,3 +1,6 @@
+// SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project
+// SPDX-License-Identifier: GPL-3.0-or-later
+
/* SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project */
/* SPDX-License-Identifier: GPL-2.0-or-later */
@@ -5,9 +8,22 @@
#define __ASSEMBLY__
+// Newer Linux UAPI headers check __ASSEMBLER__ instead of __ASSEMBLY__ to hide C declarations.
+// Without it, asm-generic/signal.h redeclares sigset_t and clashes with glibc's. Only define it
+// around these includes, since glibc headers also look at __ASSEMBLER__.
+#ifndef __ASSEMBLER__
+#define __ASSEMBLER__
+#define EDEN_NCE_UNDEF_ASSEMBLER
+#endif
+
#include <asm-generic/signal.h>
#include <asm-generic/unistd.h>
+#ifdef EDEN_NCE_UNDEF_ASSEMBLER
+#undef __ASSEMBLER__
+#undef EDEN_NCE_UNDEF_ASSEMBLER
+#endif
+
#define ReturnToRunCodeByExceptionLevelChangeSignal SIGUSR2
#define BreakFromRunCodeSignal SIGURG
#define GuestAccessFaultSignal SIGSEGV