Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

Mono Upgrade mscorlib.dll was not found

Discussion in 'Experimental Scripting Previews' started by pneuro, Dec 13, 2018.

  1. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    I have upgraded to .NET 4.x Equivalent in my Unity project on Unity 2018.2.13f1 and now I am unable to create a build. I am getting the following error:

    WARNING: The runtime version supported by this application is unavailable.
    Using default runtime: v1.1.4322
    The assembly mscorlib.dll was not found or could not be loaded.
    It should have been installed in the `C:\Program Files\Unity 2018.2.13f1\Editor\Data\Mono\lib\mono\1.0\mscorlib.dll' directory.

    Anyone has any idea how to fix?
     

    Attached Files:

  2. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Can you provide the full editor log file?
     
  3. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    Thanks for your quick response. I would but the file is 15mb and I am unable to upload.
     
  4. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Can you provide only the text around the error message? I'd like to know if there is more information about this error.
     
  5. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    Yes. Please find in the attachment.
     

    Attached Files:

  6. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Can you provide a bit more context? Specifically, I'd like to see the full compiler command line information above the "-----CompilerOutput:" line.
     
  7. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    I suppose you are talking about command line arguments.

    Here is a snippet:
    -----Compiler Commandline Arguments:
    Filename: "C:\Program Files\Unity 2018.2.13f1\Editor\Data\MonoBleedingEdge\bin\mono.exe"
    Arguments: "C:\Program Files\Unity 2018.2.13f1\Editor\Data\MonoBleedingEdge\lib\mono\4.5\mcs.exe" @temp/UnityTempFile-d8960e9631bcb5c4287c71908d884c06
    index: 89
    Responsefile: Temp/UnityTempFile-d8960e9631bcb5c4287c71908d884c06 Contents:
    -debug
    -target:library
    -nowarn:0169
    -langversion:6
    -out:Temp/Assembly-CSharp-firstpass.dll
    -nostdlib
    -optimize
    -r:Library/ScriptAssemblies/Unity.TextMeshPro.dll
    -r:"C:\Program Files\Unity 2018.2.13f1\Editor\Data\PlaybackEngines\windowsstandalonesupport/Managed/UnityEngine.dll"
    -r:"C:\Program Files\Unity 2018.2.13f1\Editor\Data\PlaybackEngines\windowsstandalonesupport/Managed/UnityEngine.AIModule.dll"


    More text is available in the attachment.
     

    Attached Files:

  8. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
  9. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    It looks like the error is related to compilation of some UnityScript code in the project. I see the .js source files in
    Assets/Oculus/Spatializer/Scenes/Standard Assets/Character Controllers/Sources/Scripts, for example.

    We're not supporting UnityScript with the .NET 4.x equivalent runtime, and UnityScript support is removed entirely in Unity 2018.3. If you don't need these .js files, I'd recommend removing them. I think the error will go away then.
     
  10. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    I have deleted all .js files, but still not able to build. Do I have to delete any other files as well?
     
  11. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Maybe there was another issue that caused this. Can you send an updated Editor.log file, created without an UnityScript files in the project?
     
  12. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
  13. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    I still see .js files being compiled, at the same location in the project I mentioned above. So it looks like a few are still hanging around.
     
  14. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    Yes, that is because when we create a new build, previous editor log is not cleared. Unity adds new log on top of previous log. That's why the above error message is appearing multiple times in the log.
     
  15. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Can you delete the old editor log, then get a new one with only the current error message in it?
     
  16. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    Please check the same link again.
     
  17. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    In this editor.log, it looks like the C# compiler succeeds now.
     
  18. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    It did not, but thanks a lot for your support. The problem has been fixed by updating PiXYZ plugin.
     
    JoshPeterson likes this.
  19. pneuro

    pneuro

    Joined:
    Aug 19, 2018
    Posts:
    15
    Now I am facing another weird Issue. PiXYZ is not working in build.

    So the bottom line is, project won't build if you are using PiXYZ 2018.1.022 and upgrade to .NET 4.x
    Error: mscorlib.dll issue posted above.
    Tested on: Unity 2018.1.0f2

    and PiXYZ runtime import doesn't work in build, if you upgrade to latest PiXYZ 2018.3.1.4
    (Tested on both Unity 2018.2.13f1 (64-bit) and Unity 2018.3.0f2 (64-bit))
    Even the sample scene ImportOnPlay provided by PiXYZ is not working in build.
     
  20. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,936
    Sorry, I'm not familiar with PiXYZ. Maybe they have support channels you can use though.