Start .NET and Godot games under FEX without per-game setup (#168)

This commit is contained in:
Magarto authored and GitHub committed 2026-10-04 08:19:11 -04:00
1 parent 8502fc517b
commit 32ea22e033
4 files changed
+154 -3

No files matched your search

@@ -29,6 +29,12 @@ object GameEnvironment {
"MESA_SHADER_CACHE_DISABLE" to "false",
"VKD3D_FEATURE_LEVEL" to "12_2",
"VKD3D_SHADER_MODEL" to "6_9",
// .NET 7 and later reserve 256 GB of address space for the GC heap at startup, more than an
// Android process has free, and the runtime fails to start. 32 GB is plenty for a game.
"DOTNET_GCRegionRange" to "0x800000000",
// .NET's W^X writes JIT code through a second mapping that FEX does not watch, so FEX keeps
// running the stale translation and the game hangs at startup.
"DOTNET_EnableWriteXorExecute" to "0",
).apply {
FexPreset.env(preset).forEach { put(it.substringBefore('='), it.substringAfter('=')) }
}