From 30a35a897f2220d1b252d211c389cf0319170a94 Mon Sep 17 00:00:00 2001 From: George Thayamkery Date: Thu, 30 May 2024 11:49:30 -0500 Subject: [PATCH] not android check on std.debug.getContext have_getcontext must be false for android, this makes sure that std.debug.getContext wont call the non-existant function (and thus hit a compileError) --- lib/std/debug.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/std/debug.zig b/lib/std/debug.zig index 44bcf3abc1..f431d0eb91 100644 --- a/lib/std/debug.zig +++ b/lib/std/debug.zig @@ -237,8 +237,8 @@ pub fn relocateContext(context: *ThreadContext) void { }; } -pub const have_getcontext = @hasDecl(posix.system, "getcontext") and - native_os != .openbsd and native_os != .haiku and +pub const have_getcontext = native_os != .openbsd and native_os != .haiku and + !builtin.target.isAndroid() and (native_os != .linux or switch (builtin.cpu.arch) { .x86, .x86_64,