Use defines to avoid threading with Emscripten.