Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Build Hololens Exception

Discussion in 'VR' started by coke_fenta, Apr 17, 2019.

?

for help

  1. build hololens failed

    0 vote(s)
    0.0%
  2. build hololens failed

    0 vote(s)
    0.0%
  1. coke_fenta

    coke_fenta

    Joined:
    Jun 8, 2015
    Posts:
    3
    Exception: Failed to locate env variables VS140COMNTOOLS or VS120COMNTOOLS.
    Utility.GetVSVersion () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/Utility.cs:623)
    MetroCSharpVisualStudioSolutionCreator.WriteSolutionFile (System.String solutionFileName, UnityEditor.Scripting.ScriptCompilation.ScriptAssembly[] csharpAssemblies) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/MetroCSharpVisualStudioSolutionCreator.cs:196)
    MetroCSharpVisualStudioSolutionCreator.CreateSolutionFileFrom () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/MetroCSharpVisualStudioSolutionCreator.cs:724)
    PostProcessWSA.CreateVisualStudioSolution () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessWSA.cs:320)
    PostProcessWinRT.Process () (at C:/buildslave/unity/build/PlatformDependent/WinRT/SharedSources/CSharp/PostProcessWinRT.cs:237)
    UnityEditor.WSA.BuildPostprocessor.DoPostProcess (BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:142)
    UnityEditor.WSA.BuildPostprocessor.PostProcess (BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:149)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)

    Build completed with a result of 'Failed'
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)


    UnityEditor.BuildPlayerWindow+BuildMethodException: 2 errors
    at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (BuildPlayerOptions options) [0x00207] in C:\buildslave\unity\build\Editor\Mono\BuildPlayerWindowBuildMethods.cs:172
    at UnityEditor.BuildPlayerWindow.CallBuildMethods (Boolean askForBuildLocation, BuildOptions defaultBuildOptions) [0x00050] in C:\buildslave\unity\build\Editor\Mono\BuildPlayerWindowBuildMethods.cs:83
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)
     
  2. coke_fenta

    coke_fenta

    Joined:
    Jun 8, 2015
    Posts:
    3
    upload_2019-4-17_20-11-54.png

    Fortunately, there was such a mistake when the program was released today.
     
  3. timke

    timke

    Joined:
    Nov 30, 2017
    Posts:
    400
    This appears to be the same issue discussed on this thread: https://forum.unity.com/threads/exc...bles-vs140comntools-or-vs120comntools.474195/

    The issue was posted on the Microsoft HoloLens forums: https://forums.hololens.com/discuss...nv-variables-vs140comntools-or-vs120comntools

    The fix is basically reinstall VS or manually add the environment variables (as indicated in the MS forum post). This seems to be an issue with VS installer, and I'm not sure if there's anything we can do about it.

    Are you also using VS 2017 release or a different version?