OK I’m up to build # 6 trying to get a project built for iOS. The builds fail after about 10 minutes of time and the logs show two particular errors:
[error] [2025-02-28T04:41:02Z - Unity] ERROR: Unable to fall back to CPU lightmapper.
[error] [warning] [2025-02-28T04:41:03Z - Unity] ERROR: Player export failed. Reason: Assets/Scripts/GUI/CardInfoController.cs(132,22): warning CS0414: The field 'CardInfoController.allowEscBack' is assigned but its value is never used
The game is 2D and doesn’t use lighting. And this project has several “unused variables” but only ONE warning in the log complaining. If I comment it out, then a DIFFERENT “never used” variable ends up in the log as an error. But I’ve never seen this cause a build failure before. Usually errors with “warning” in them don’t also have a stacktrace in the log, but this one does.
This project builds to Windows and Android without issue.
Unity 2022.3.49
Tried building with Mac Sonoma, Ventura, Sonoma Experimental.
Tried with 15.2, 15.3, 15.4 and now trying with 16
No success and very strange.
I’m trying now with “Strict” turned off (but I’ve always had strict turned on for other iOS projects).
We were coincidentally investigating something similar earlier today and we believe it might’ve related to an editor bug in the strict setting that forces lightbaking to happen regardless of lightbaking being needed.
Can you try again with strict mode turned off. And if possible please use Xcode 16.0 / 16.1 and sonoma arm to benefit from the new apple silicon machines we have (you should see a performance boost on the arm editors which should reduce build minutes)
Update: we believe the issue was introduced in 2022.3.18f1, but we’re not certain and are checking with the editor team.
Could you create a ticket with the UBA team via DevOps > Help & Support > File a ticket ?
Or DM me the link to the failed build so we can take a closer look.
Following up here, since there was some private direct communications regarding this.
The errors in the main logs were not the issue. I should have been looking in the additional “Xcode Logs” for deeper clues.
In there, it was found that there was some old Google Play Services related files somehow in my project, despite not using GPS. Those referenced non-existent files.
Deleting the two “GPGS” files and building with Xcode 16.1 solved the issue.
I heard back from a Unity engineer as well and they’re confident my issue was a bug with the Silicon editor not honouring the strict mode setting correctly (which was enabled)
The potential fix is to temporarily disable strict mode, which I’ve yet to try. Alternatively switching to Intel also fixes the issue.
Regarding the Google Play Services files…
Were these part of the Unity\Google package that was once installed? Would you be able to list the file locations\names please, so others can check as well?
The Google files in question were legacy files that somehow didn’t delete when upgrading to the 9.6.0 Google Mobile Ads package. The files in question were:
After disabling strict mode (as recommended by the Unity engineer) I finally managed a successful Silicon build last night. It was quicker than Intel, but not significantly.
I also found this (old) issue describing what appears to be the problem, so maybe this is a regression…