Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

WebGL Build Error, Need Help Debugging

Discussion in 'WebGL' started by DerrickBarra, Mar 13, 2015.

  1. DerrickBarra

    DerrickBarra

    Joined:
    Nov 19, 2013
    Posts:
    210
    Hi everyone, I'm trying to port my Unity Web Player project over to WebGL, but I'm recieving two errors in the export process that I haven't been able to figure out...

    Code (CSharp):
    1. Win32Exception: ApplicationName='"C:\Program Files\Unity\Editor\Data\PlaybackEngines\webglsupport/BuildTools/Emscripten_Win/python/2.7.5.3_64bit/python.exe"',
    2. CommandLine='"C:\Program Files\Unity\Editor\Data\PlaybackEngines\webglsupport/BuildTools/Emscripten/emcc" -Oz -s NO_EXIT_RUNTIME=1 -o
    3. "C:/Users/Derrick/Gambit Games Dropbox/Dropbox/Scrum Hero Digital App/Scrum Hero Unity Project/Assets/../Temp/StagingArea/Data\Native\UserAssembly.bc"
    4. @"C:\Temp\tmp120c6172.tmp"', CurrentDirectory='C:/Users/Derrick/Gambit Games Dropbox/Dropbox/Scrum Hero Digital App/Scrum Hero Unity Project/Assets/../Temp/EmscriptenWork'
    5.  
    6. System.Diagnostics.Process.Start_noshell (System.Diagnostics.ProcessStartInfo startInfo, System.Diagnostics.Process process)
    7. System.Diagnostics.Process.Start_common (System.Diagnostics.ProcessStartInfo startInfo, System.Diagnostics.Process process)
    8. System.Diagnostics.Process.Start ()
    9. (wrapper remoting-invoke-with-check) System.Diagnostics.Process:Start ()
    10. UnityEditor.Utils.Program.Start () (at C:/buildslave/unity/build/Editor/Mono/Utils/Program.cs:33)
    11. NativeCompiler.RunProgram (System.Diagnostics.ProcessStartInfo startInfo) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/NativeCompiler.cs:42)
    12. NativeCompiler.Execute (System.String arguments, System.String compilerPath) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/NativeCompiler.cs:26)
    13. UnityEditor.WebGL.Il2Cpp.EmscriptenCompiler.LinkObjects (IEnumerable`1 sources, System.String outfile)
    14. UnityEditor.WebGL.Il2Cpp.EmscriptenCompiler.MultiThreadedCompile (System.String outfile, IEnumerable`1 sources, IEnumerable`1 includePaths, Boolean exceptionSupport)
    15. UnityEditor.WebGL.Il2Cpp.EmscriptenCompiler.CompileDynamicLibrary (System.String outFile, IEnumerable`1 sources, IEnumerable`1 includePaths, IEnumerable`1 libraries, IEnumerable`1 libraryPaths)
    16. UnityEditorInternal.IL2CPPBuilder.Run () (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:290)
    17. UnityEditorInternal.IL2CPPUtils.RunIl2Cpp (System.String stagingAreaData, IIl2CppPlatformProvider platformProvider, System.Action`1 modifyOutputBeforeCompile, UnityEditor.RuntimeClassRegistry runtimeClassRegistry) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:218)
    18. UnityEditor.WebGL.WebGlBuildPostprocessor.PostProcess (BuildPostProcessArgs args)
    19. UnityEditor.PostprocessBuildPlayer.Postprocess (BuildTarget target, System.String installPath, System.String companyName, System.String productName, Int32 width, Int32 height, System.String downloadWebplayerUrl, System.String manualDownloadWebplayerUrl, BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/PostprocessBuildPlayer.cs:316)
    20. UnityEditor.HostView:OnGUI()
    21.  

    Code (CSharp):
    1. Error building Player: Win32Exception: ApplicationName='"C:\Program Files\Unity\Editor\Data\PlaybackEngines\webglsupport/BuildTools/Emscripten_Win/python/2.7.5.3_64bit/python.exe"',
    2. CommandLine='"C:\Program Files\Unity\Editor\Data\PlaybackEngines\webglsupport/BuildTools/Emscripten/emcc" -Oz -s NO_EXIT_RUNTIME=1 -o
    3. "C:/Users/Derrick/Gambit Games Dropbox/Dropbox/Scrum Hero Digital App/Scrum Hero Unity Project/Assets/../Temp/StagingArea/Data\Native\UserAssembly.bc"
    4. @"C:\Temp\tmp120c6172.tmp"', CurrentDirectory='C:/Users/Derrick/Gambit Games Dropbox/Dropbox/Scrum Hero Digital App/Scrum Hero Unity Project/Assets/../Temp/EmscriptenWork'
    5.  

    Is there a recommended way to find out where/why WebGL builds fail when the error isn't immediately obvious?
     
  2. gfoot

    gfoot

    Joined:
    Jan 5, 2011
    Posts:
    550
    Make sure you clear the console window before building. I have found that when a WebGL build fails I usually see three error messages; and if I fix the problem and build again, one of them gets cleared before the build, but the other two stay there. Then even after the build succeeds, those error messages are still visible, there looking suspicious.

    So make sure you hit "clear" before building.
     
  3. DerrickBarra

    DerrickBarra

    Joined:
    Nov 19, 2013
    Posts:
    210
    Sokki: This is my first time working with the WebGL export option, and WebGL in general. My background is mostly web player, mobile, and desktop.

    gfoot: I'll double check this, that's an interesting quirk that I didn't know about. I believe my console log was clear before I began the build process (I tried multiple times with the same error, but it's been a few days so maybe I didn't hit "Clear").
     
  4. Gnatty

    Gnatty

    Joined:
    May 17, 2012
    Posts:
    77
    Building for WebGL will only work on 64bit.
    Is the above build on a 64bit machine?
     
  5. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    Please don't solicit in posts where people are asking for specific help. It's not fair to the people wanting help and has a very negative impact on your reputation.
     
    sokki likes this.
  6. ShyRec

    ShyRec

    Joined:
    Jun 30, 2013
    Posts:
    18
    same errors. unity 5.0.0f4 64bit editor, win 8.1 64bit.
    even on empty project
     
  7. Dustin-Horne

    Dustin-Horne

    Joined:
    Apr 4, 2013
    Posts:
    4,568
    There was a patch release today with a bunch of IL2CPP fixes. Can you try again with the new patch?
     
    ShyRec likes this.
  8. ShyRec

    ShyRec

    Joined:
    Jun 30, 2013
    Posts:
    18
    Not yet. I will try this today or in a few days and write in this thread if it's help. Thanks
     
  9. DerrickBarra

    DerrickBarra

    Joined:
    Nov 19, 2013
    Posts:
    210
    I'm on a 64-Bit machine, but when the opportunity comes around I'll check out the patched release. Thanks for the notification Dustin.
     
  10. ShyRec

    ShyRec

    Joined:
    Jun 30, 2013
    Posts:
    18
    Ok, I'm idiot. This patch help me with this errors, but now I have one new. My user folder have russian chars (cause I forget about my microsoft account is russian, and sign in :( ) I think the error due to this
    Code (CSharp):
    1. C:\Program Files\Unity\Editor\Data\PlaybackEngines\webglsupport/BuildTools/Emscripten_FastComp_Win\llvm-link: C:/Users/����/AppData/Local/Unity/Editor/EmscriptenCache/libcxx.bc: error: Could not open input file: No mapping for the Unicode character exists in the target multi-byte code page
    I guess this patсh solve problem in latin-named user folder, so thanks, Dustin. I try compile on different pc with correct named user folder in next week.
     
  11. jonas-echterhoff

    jonas-echterhoff

    Unity Technologies

    Joined:
    Aug 18, 2005
    Posts:
    1,666
    Yes, indeed, WebGL builds will fail when building on user or project names with non-ASCII characters on windows (this is a limitation of the emscripten toolchain). Unity 5.1 will add proper error message output for this so at least people won't be clueless when this happens.
     
  12. AFrisby

    AFrisby

    Joined:
    Apr 14, 2010
    Posts:
    223
    Hi guys, still getting this error in 5.1.3f1.

    What is weird however is this exact project worked under 5.0 earlier. The break occurred after the 5.1 upgrade. Unfortunately I can't provide the project (50+gb), unless you want it via DVD or something.
     
  13. AFrisby

    AFrisby

    Joined:
    Apr 14, 2010
    Posts:
    223
    Quick update, the patch release 5.1.3p2 fixed this.