--- tcg/region.c.orig +++ tcg/region.c @@ -684,7 +684,7 @@ */ prot = PROT_NONE; flags = MAP_PRIVATE | MAP_ANONYMOUS; -#ifdef CONFIG_DARWIN +#if defined(CONFIG_DARWIN) && defined(MAP_JIT) /* Applicable to both iOS and macOS (Apple Silicon). */ if (!splitwx) { flags |= MAP_JIT;