Build settings can cause release build with il2cpp crash at startup
MaartenDeMeyer opened this issue · 1 comments
We've had an elusive crash at startup happen, only for our gamecore release builds and only for il2cpp - development builds were fine & threw no exception, mono backend was OK too.
After some searching it seems this is caused by the logic in ImportWin32BuildSettings. There, the BuildOptions are built from the EditorBuildSettings, copying over flag by flag, removing setting of these flags fixes our issue.
My working theory is that this method should NOT copy over certain development only settings (such as AllowDebugging, WaitForPlayerConnection etc, unless the Development buildoption is checked. In the UI these settings are greyed out, but their values are still set. [Alternatively there might be an issue with one of the individual flags - eg enableHeadlessMode is obsolete.]
Thank you so, so much for letting us know about this elusive issue. We will investigate and get this fixed.