Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions aurora-main/cmake/patches/abseil-nintendo-switch-platform.patch
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
#if defined(__APPLE__) || defined(__FreeBSD__)
#include <sys/sysctl.h>
#endif
@@ -461,6 +465,18 @@
return reinterpret_cast<pid_t>(thread);
@@ -465,6 +469,18 @@ pid_t GetTID() {
return static_cast<pid_t>(zx_thread_self());
}

+#elif defined(__SWITCH__)
Expand All @@ -32,13 +32,12 @@
// Fallback implementation of `GetTID` using `pthread_self`.
--- a/absl/debugging/internal/elf_mem_image.h
+++ b/absl/debugging/internal/elf_mem_image.h
@@ -35,7 +35,13 @@
#if defined(__ELF__) && !defined(__OpenBSD__) && !defined(__QNX__) && \
!defined(__native_client__) && !defined(__asmjs__) && \
!defined(__wasm__) && !defined(__HAIKU__) && !defined(__sun) && \
- !defined(__VXWORKS__) && !defined(__hexagon__)
+ !defined(__VXWORKS__) && !defined(__hexagon__) && \
+ !defined(__SWITCH__)
@@ -35,7 +35,12 @@
#if defined(__ELF__) && !defined(__OpenBSD__) && !defined(__QNX__) && \
!defined(__asmjs__) && !defined(__wasm__) && !defined(__HAIKU__) && \
!defined(__sun) && !defined(__VXWORKS__) && !defined(__hexagon__) && \
- !defined(__XTENSA__)
+ !defined(__XTENSA__) && !defined(__SWITCH__)
+// __SWITCH__ (Nintendo Switch homebrew, devkitA64/libnx): the .nro output is derived from an
+// ELF binary (so __ELF__ is defined), but devkitA64/newlib has no <link.h> - this whole feature
+// is glibc's dynamic-linker ELF introspection API (dl_phdr_info, ElfW macros), which has no
Expand All @@ -49,7 +48,7 @@

--- a/absl/time/internal/cctz/src/time_zone_libc.cc
+++ b/absl/time/internal/cctz/src/time_zone_libc.cc
@@ -61,8 +61,13 @@
@@ -61,8 +61,13 @@ auto tm_zone(const std::tm& tm) -> decltype(tzname[0]) {
return tzname[is_dst];
}
#elif defined(__native_client__) || defined(__myriad2__) || \
Expand Down