How to solve the WebGL build error?

I am new here, just finished watching lecture 33 and I am having problems making a WebGL build.

When I am trying to build, it fails with 2 errors. There is a lot of text in Console but the gist is “failed running il2cpp”. The Unity versions I tried are 2019.2.12f1 and 2019.3.0f1. I tried deleting the il2cpp cache folder, tried restarting and making a new project. Even an empty project wouldn’t build there… Here are the full logs of the errors:

  1. First error:
  2. Second one:

Hi Alex,

Did you use any non-English characters or parentheses or something like that in your project name or folder name? See this answer. There are more potential solutions in the linked thread. Did any of them help you fix the problem?

Hi Nina,

No I did not use any non-English nor parentheses. Here is the installation path for Unity: D:\Programs\Unity\Unity Editors\2019\Editor
Here is where my project sits with all its assets etc (no parentheses or non-Eng characters in the project name either): D:\Unity Repos\Unity2D\Text101\Text101

Or did you mean something different?

I also tried running as admin and setting all admin permissions for il2cpp.exe and Unity. The same error occured on Unity 2019.1.0f2 and Unity 2019.2.12f1 as well as Unity 2019.3.
I examined this thread you linked again (already read it before), and that is why I actually downgraded to 2019.1.0f2 (some said it fixed the issue), but no - always the same il2cpp error.

Nina, I think it has been solved now but it was a bit more complex than just renaming the folder.

What I did is:

  1. On my main Windows 10 (Home) profile, I created another profile (well, I opened the hidden Administrator one) via command line. I entered there: net user Administrator /active:yes
  2. Logged out of my “Alex” profile and into “Administrator”
  3. Renamed my C:\Users\Alex folder
  4. Opened the register via “regedit” and searched for all old folder names (Alex) via F3. Changed them all to the new one
  5. When there were none left, I logged back into “Alex” profile on my Windows and checked that my new C drive user folder had the new name (that I gave via “Administartor”)
  6. Launched Unity 2019.3.0f1 and built the WebGL build without any errors.

That’s it. Hope it can help others.

Thanks a lot for sharing your solution, Alex. :slight_smile:

Your folder names were fine. I’m wondering if there had been any restrictions on D because I’m not sure what the problem was your complex solution fixes.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms