Search Unity

Bug Building Library\Bee\artifacts\WinPlayerBuildProgram\ManagedStripped failed with output:

Discussion in 'Windows' started by NetworkingServices, Sep 30, 2022.

  1. NetworkingServices

    NetworkingServices

    Joined:
    Mar 28, 2022
    Posts:
    20
    Hello, so I was making a game in webgl and I received an error... so I decided to switch to windows (il2cpp) and received the same error. I'm guessing it has something to do with il2cpp but I'm not sure how to fix it? Any ideas?

    **Bug1 In Console**
    Building Library\Bee\artifacts\WinPlayerBuildProgram\ManagedStripped failed with output:
    C:\Program Files\Unity\Hub\Editor\2022.1.18f1\Editor\Data\il2cpp\build\deploy\UnityLinker.exe --search-directory=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport/Variations/il2cpp/Managed --search-directory=C:/Users/exodu/Run Capsule, Run/Library/PackageCache/com.unity.nuget.newtonsoft-json@3.0.2/Runtime/AOT --search-directory=C:/Users/exodu/Run Capsule, Run/Library/PackageCache/com.unity.visualscripting@1.7.8/Runtime/VisualScripting.Flow/Dependencies/NCalc --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-win32 --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-win32/Facades --out=Library/Bee/artifacts/WinPlayerBuildProgram/ManagedStripped --include-link-xml=C:/Users/exodu/Run Capsule, Run/Temp/StagingArea/Data/Managed\MethodsToPreserve.xml --include-link-xml=C:/Users/exodu/Run Capsule, Run/Temp/StagingArea/Data/Managed\TypesInScenes.xml --include-link-xml=C:/Users/exodu/Run Capsule, Run/Temp/StagingArea/Data/Managed\SerializedTypes.xml --include-directory=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport/Variations/il2cpp/Managed --include-directory=C:/Users/exodu/Run Capsule, Run/Library/PackageCache/com.unity.nuget.newtonsoft-json@3.0.2/Runtime/AOT --include-directory=C:/Users/exodu/Run Capsule, Run/Library/PackageCache/com.unity.visualscripting@1.7.8/Runtime/VisualScripting.Flow/Dependencies/NCalc --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-win32 --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-win32/Facades --dotnetprofile=unityaot-win32 --dotnetruntime=Il2Cpp --platform=WindowsDesktop --use-editor-options --engine-modules-asset-file=C:/Program Files/Unity/Hub/Editor/2022.1.18f1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport/modules.asset --editor-data-file=C:/Users/exodu/Run Capsule, Run/Temp/StagingArea/Data/Managed/EditorToUnityLinkerData.json --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/Assembly-CSharp.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/Unity.TextMeshPro.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/KinoBloom.Runtime.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/CFXRDemo.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/UnityEngine.UI.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/Unity.Polybrush.dll --include-unity-root-assembly=C:/Users/exodu/Run Capsule, Run/Library/Bee/PlayerScriptAssemblies/CFXRRuntime.dll --print-command-line
    Fatal error in Unity CIL Linker
    System.IO.FileNotFoundException: Could not find file 'C:\Users\exodu\Run Capsule'.
    File name: 'C:\Users\exodu\Run Capsule'
    at System.IO.FileStream.ValidateFileHandle(SafeFileHandle fileHandle)
    at System.IO.FileStream.CreateFileOpenHandle(FileMode mode, FileShare share, FileOptions options)
    at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options)
    at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
    at System.Xml.XmlDownloadManager.GetStream(Uri uri, ICredentials credentials, IWebProxy proxy)
    at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)
    at System.Xml.XmlTextReaderImpl.OpenUrl()
    at System.Xml.XmlTextReaderImpl.Read()
    at System.Xml.XPath.XPathDocument.LoadFromReader(XmlReader reader, XmlSpace space)
    at System.Xml.XPath.XPathDocument..ctor(String uri, XmlSpace space)
    at Unity.Linker.UnityDriver.ParseArguments(UnityPipeline p, UnityLinkContext context, ArrayList custom_steps, Boolean usingCustomLogger, I18nAssemblies& assemblies)
    at Unity.Linker.UnityDriver.UnityRun(Boolean noProfilerAllowed, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling(ILogger customLogger, Boolean noProfilerAllowed)
    at Unity.Linker.UnityDriver.RunDriver()
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)

    -----------------------------------------------------------------------------
    **Bug2 In Console**
    BuildFailedException: Incremental Player build failed!
    UnityEditor.Modules.BeeBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at <71ee84cdf7fe40d890e92f20d978f6a2>:0)
    UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <71ee84cdf7fe40d890e92f20d978f6a2>:0)
    UnityEditor.WindowsStandalone.WinPlayerPostProcessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at C:/buildslave/unity/build/PlatformDependent/WinPlayer/Extensions/Managed/WinPlayerPostProcessor.cs:106)
    UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.Int32 subtarget, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <71ee84cdf7fe40d890e92f20d978f6a2>:0)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)

    ---------------------------------------------------------------------------
    **Bug3 In Console**

    UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors
    at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002da] in <71ee84cdf7fe40d890e92f20d978f6a2>:0
    at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <71ee84cdf7fe40d890e92f20d978f6a2>:0
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
     
  2. NetworkingServices

    NetworkingServices

    Joined:
    Mar 28, 2022
    Posts:
    20
    Fixed it... I had to remove the "," in my game path...
     
    Flyingcap and sandolkakos like this.
  3. maho166167

    maho166167

    Joined:
    Sep 25, 2020
    Posts:
    1
    Ne yaptığını tam olarak anlamıyorum. yardımcı olursanız çok sevinirim.
     
  4. Ekeo

    Ekeo

    Joined:
    Jun 30, 2020
    Posts:
    1
    Sorry for upping the topic, what do you mean by game path?
     
    LFloreau likes this.
  5. RomanCalderon

    RomanCalderon

    Joined:
    Jan 4, 2014
    Posts:
    6
    They likely mean the build path.
     
  6. SANKET06

    SANKET06

    Joined:
    Mar 10, 2022
    Posts:
    1
    THANK YOU DUDE !
     
  7. Eychamove

    Eychamove

    Joined:
    Jul 3, 2019
    Posts:
    3
    I get the same bug, even though there are no "," or any other symbols or non-english letters in my path. Does Someone know another possible cause for the problem? I work on an Android version
     
    Last edited: Dec 20, 2022
  8. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    Could be a different issue, perhaps you can attach your editor log after the build fails?
     
  9. Eychamove

    Eychamove

    Joined:
    Jul 3, 2019
    Posts:
    3
    Yes, here are my errors:

    Previously i update my project from version 2019.3.7f1 to 2022.1.23f1 and i updated my GoggleMobileAds Plugin and downloaded an sdk Version that supported an API-Level of 31.

    Error 1:

    Building Library\Bee\artifacts\Android\ManagedStripped failed with output:
    C:\Program Files\Unity\Hub\Editor\2022.1.23f1\Editor\Data\il2cpp\build\deploy\UnityLinker.exe --search-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/Bee/PlayerScriptAssemblies --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/AndroidPlayer/Variations/il2cpp/Managed --search-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/PackageCache/com.unity.nuget.newtonsoft-json@3.0.2/Runtime/AOT --search-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Assets/GoogleMobileAds --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux --search-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux/Facades --out=Library/Bee/artifacts/Android/ManagedStripped --include-link-xml=C:/Users/Luca/Desktop/Apps/StoryGenerator/Temp/StagingArea/Data/Managed\MethodsToPreserve.xml --include-link-xml=C:/Users/Luca/Desktop/Apps/StoryGenerator/Temp/StagingArea/Data/Managed\TypesInScenes.xml --include-link-xml=C:/Users/Luca/Desktop/Apps/StoryGenerator/Temp/StagingArea/Data/Managed\SerializedTypes.xml --include-link-xml=C:\Users\Luca\Desktop\Apps\StoryGenerator\Assets\GoogleMobileAds\link.xml --include-link-xml=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/AndroidPlayer/Tools/AndroidNativeLink.xml --include-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/Bee/PlayerScriptAssemblies --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/AndroidPlayer/Variations/il2cpp/Managed --include-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/PackageCache/com.unity.nuget.newtonsoft-json@3.0.2/Runtime/AOT --include-directory=C:/Users/Luca/Desktop/Apps/StoryGenerator/Assets/GoogleMobileAds --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux --include-directory=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/MonoBleedingEdge/lib/mono/unityaot-linux/Facades --dotnetprofile=unityaot-linux --dotnetruntime=Il2Cpp --platform=Android --use-editor-options --engine-stripping-flag=EnableUnityConnect --engine-stripping-flag=EnableCrashReporting --engine-modules-asset-file=C:/Program Files/Unity/Hub/Editor/2022.1.23f1/Editor/Data/PlaybackEngines/AndroidPlayer/modules.asset --editor-data-file=C:/Users/Luca/Desktop/Apps/StoryGenerator/Temp/StagingArea/Data/Managed/EditorToUnityLinkerData.json --include-unity-root-assembly=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/Bee/PlayerScriptAssemblies/Assembly-CSharp.dll --include-unity-root-assembly=C:/Users/Luca/Desktop/Apps/StoryGenerator/Library/Bee/PlayerScriptAssemblies/UnityEngine.UI.dll --print-command-line
    Fatal error in Unity CIL Linker
    Mono.Linker.LinkerFatalErrorException: ILLink: error IL1005: GoogleMobileAds.Api.MobileAds.GetClientFactory(): Error processing method 'GoogleMobileAds.Api.MobileAds.GetClientFactory()' in assembly 'GoogleMobileAds.dll'
    ---> System.InvalidOperationException: No action for the assembly GoogleMobileAds.Unity, Version=7.3.1.0, Culture=neutral, PublicKeyToken=null defined
    at Mono.Linker.AnnotationStore.GetAction(AssemblyDefinition assembly)
    at Mono.Linker.Steps.MarkStep.MarkCustomAttributes(ICustomAttributeProvider provider, DependencyInfo& reason, IMemberDefinition sourceLocationMember)
    at Mono.Linker.Steps.MarkStep.MarkType(TypeReference reference, DependencyInfo reason, IMemberDefinition sourceLocationMember)
    at Mono.Linker.Steps.MarkStep.MarkTypeVisibleToReflection(TypeReference reference, DependencyInfo reason, IMemberDefinition sourceLocationMember)
    at Mono.Linker.Dataflow.ReflectionMethodBodyScanner.<>c__DisplayClass20_4.<HandleCall>b__7()
    at Mono.Linker.Dataflow.ReflectionMethodBodyScanner.HandleCall(MethodBody callingMethodBody, MethodReference calledMethod, Instruction operation, ValueNodeList methodParams, ValueNode& methodReturnValue)
    at Mono.Linker.Dataflow.MethodBodyScanner.HandleCall(MethodBody callingMethodBody, Instruction operation, Stack`1 currentStack)
    at Mono.Linker.Dataflow.MethodBodyScanner.Scan(MethodBody methodBody)
    at Mono.Linker.Dataflow.ReflectionMethodBodyScanner.ScanAndProcessReturnValue(MethodBody methodBody)
    at Unity.Linker.Steps.UnityMarkStep.MarkReflectionLikeDependencies(MethodBody body, Boolean requiresReflectionMethodBodyScanner)
    at Mono.Linker.Steps.MarkStep.MarkMethodBody(MethodBody body)
    at Unity.Linker.Steps.UnityMarkStep.MarkMethodBody(MethodBody body)
    at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method, DependencyInfo& reason)
    at Unity.Linker.Steps.UnityMarkStep.ProcessMethod(MethodDefinition method, DependencyInfo& reason)
    at Mono.Linker.Steps.MarkStep.ProcessQueue()
    --- End of inner exception stack trace ---
    at Mono.Linker.Steps.MarkStep.ProcessQueue()
    at Mono.Linker.Steps.MarkStep.ProcessPrimaryQueue()
    at Mono.Linker.Steps.MarkStep.Process()
    at Mono.Linker.Steps.MarkStep.Process(LinkContext context)
    at Unity.Linker.Steps.UnityMarkStep.Process(LinkContext context)
    at Unity.Linker.UnityPipeline.ProcessStep(LinkContext context, IStep step)
    at Mono.Linker.Pipeline.Process(LinkContext context)
    at Unity.Linker.UnityDriver.UnityRun(Boolean noProfilerAllowed, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling(ILogger customLogger, Boolean noProfilerAllowed)
    at Unity.Linker.UnityDriver.RunDriver()
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)

    Error 2:

    BuildFailedException: Incremental Player build failed!
    UnityEditor.Modules.BeeBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at <4ce403b7cdf744109283ae55cdc24285>:0)
    UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <4ce403b7cdf744109283ae55cdc24285>:0)
    UnityEditor.Android.AndroidBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <6ba6f58d0f264bb59a4f0a6df92c605b>:0)
    UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.Int32 subtarget, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <4ce403b7cdf744109283ae55cdc24285>:0)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr, Boolean&)

    Error 3:

    Build completed with a result of 'Failed' in 16 seconds (15676 ms)
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)

    Error 4:

    UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors
    at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002da] in <4ce403b7cdf744109283ae55cdc24285>:0
    at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <4ce403b7cdf744109283ae55cdc24285>:0
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
     
  10. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    Yup it's a completely different issue. Looks like something is wrong with GoogleMobileAds.dll, perhaps it's missing a dependency. Is this something you added to your project?
     
  11. Aunkon

    Aunkon

    Joined:
    Feb 6, 2016
    Posts:
    2
    Maybe some dll or Some Platform dependent method calling related issue.
    For myself, correcting the plugin dll's which I bring externally, supported Platform (ex: Windows) and fixing Platform dependent method calling fixed the issue for me. (ex: #if UNITY_STANDALONE_WIN, #elif UNITY_WEBGL && !UNITY_EDITOR)

    Thought it would help you, guys.
     
  12. HerVap

    HerVap

    Joined:
    Oct 22, 2019
    Posts:
    8
    hey @Tautvydas-Zilys

    Wb this? Unity 6


    Building Library\Bee\artifacts\WinPlayerBuildProgram\ManagedStripped failed with output:
    H:\.Unity\Unity\Hub\Editor\6000.0.0b12\Editor\Data\il2cpp\build\deploy\UnityLinker.exe @Library\Bee\artifacts\rsp\13670902357890879346.rsp
    Fatal error in Unity CIL Linker
    Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'OPS.Obfuscator.Editor, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'
    at Unity.Linker.UnityAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters)
    at Unity.IL2CPP.Common.AssemblyDependenciesComponent.CollectAssemblyDependencies(AssemblyDefinition assembly, Boolean throwOnUnresolved)
    at Unity.IL2CPP.Common.AssemblyDependenciesComponent.GetReferencedAssembliesFor(AssemblyDefinition assembly)
    at Unity.Linker.UnityLinkContext.ResolveReferences(AssemblyDefinition assembly)
    at Mono.Linker.Steps.LoadReferencesStep.ProcessReferences(AssemblyDefinition assembly)
    at Mono.Linker.Steps.BaseStep.Process(LinkContext context)
    at Unity.Linker.UnityPipeline.ProcessStep(LinkContext context, IStep step)
    at Mono.Linker.Pipeline.Process(LinkContext context)
    at Unity.Linker.UnityDriver.UnityRun(UnityLinkContext context, UnityPipeline p, LinkRequest linkerOptions, TinyProfiler2 tinyProfiler, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling(TinyProfiler2 tinyProfiler, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling()
    at Unity.Linker.UnityDriver.RunDriver()

    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
     
  13. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    Looks like something (probably precompiled DLL) is trying to reference editor specific DLL, and is marked for inclusion into the build. That is not allowed.
     
  14. HerVap

    HerVap

    Joined:
    Oct 22, 2019
    Posts:
    8
    So cant use obfuscator in unity 6 yet
     
  15. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    You never could include editor specific code into the game build, and you never will.

    That said you seem to be describing some kind of editor tooling that affects the output of your build. For that, you don't need to include those libraries into the build itself.
     
  16. NUTRACTOR

    NUTRACTOR

    Joined:
    Dec 1, 2014
    Posts:
    8
    I too am unable to do a UWP build with the IL2CPP error.
    Unity 2023.2.17.f1

    Code (CSharp):
    1. C:\Program Files\Unity\Hub\Editor\2023.2.17f1\Editor\Data\il2cpp\build\deploy\il2cpp.exe @Library\Bee\artifacts\rsp\3756153388366045599.rsp
    2. Error: IL2CPP error (no further information about what managed code was being converted is available)
    3. System.AggregateException: One or more errors occurred. (Value cannot be null. (Parameter 'document'))
    4. ---> System.ArgumentNullException: Value cannot be null. (Parameter 'document')
    5.    at Mono.Cecil.Cil.SequencePoint..ctor(Int32, Document) + 0x7e
    6.    at Mono.Cecil.SignatureReader.ReadSequencePoints(Document) + 0x1b4
    7.    at Mono.Cecil.MetadataReader.ReadSequencePoints(MethodDefinition) + 0x1b8
    8.    at Mono.Cecil.Cil.PortablePdbReader.Read(MethodDefinition) + 0x3d
    9.    at Mono.Cecil.Cil.CodeReader.ReadMethodBody() + 0xa7
    10.    at Mono.Cecil.Cil.CodeReader.ReadMethodBody(MethodDefinition) + 0x4a
    11.    at Mono.Cecil.ModuleDefinition.Read[TItem, TRet](TRet&, TItem, Func`3) + 0x5d
    12.    at Mono.Cecil.MethodDefinition.get_Body() + 0xe4
    13.    at Unity.IL2CPP.DataModel.BuildLogic.CecilLoading.CecilAssemblyLoader.ImmediateRead(UnderConstruction`2) + 0x129
    14.    at Unity.IL2CPP.DataModel.BuildLogic.DataModelBuilder.<>c__DisplayClass18_0.<BuildCecilSourcedData>b__0(UnderConstruction`2 asm) + 0x2ed
    15.    at Unity.IL2CPP.DataModel.BuildLogic.Utils.ParallelHelpers.<>c__DisplayClass6_0`2.<MapParallel>b__0(ValueTuple`2 item) + 0x25
    16.    at System.Threading.Tasks.Parallel.<>c__DisplayClass44_0`2.<PartitionerForEachWorker>b__1(IEnumerator& partitionState, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion) + 0x279
    17. --- End of stack trace from previous location ---
    18.    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
    19.    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw(Exception) + 0x13
    20.    at System.Threading.Tasks.Parallel.<>c__DisplayClass44_0`2.<PartitionerForEachWorker>b__1(IEnumerator& partitionState, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion) + 0x630
    21.    at System.Threading.Tasks.TaskReplicator.Replica.Execute() + 0x3a
    22.    --- End of inner exception stack trace ---
    23.    at System.Threading.Tasks.TaskReplicator.Run[TState](TaskReplicator.ReplicatableUserAction`1, ParallelOptions, Boolean) + 0x15d
    24.    at System.Threading.Tasks.Parallel.PartitionerForEachWorker[TSource, TLocal](Partitioner`1, ParallelOptions, Action`1, Action`2, Action`3, Func`4, Func`5, Func`1, Action`1) + 0x23f
    25. --- End of stack trace from previous location ---
    26.    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20
    27.    at System.Threading.Tasks.Parallel.ThrowSingleCancellationExceptionOrOtherException(ICollection, CancellationToken, Exception) + 0x31
    28.    at System.Threading.Tasks.Parallel.PartitionerForEachWorker[TSource, TLocal](Partitioner`1, ParallelOptions, Action`1, Action`2, Action`3, Func`4, Func`5, Func`1, Action`1) + 0x3e0
    29.    at Unity.IL2CPP.DataModel.BuildLogic.DataModelBuilder.BuildCecilSourcedData(ReadOnlyCollection`1, ReadOnlyCollection`1&) + 0x2c3
    30.    at Unity.IL2CPP.DataModel.BuildLogic.DataModelBuilder.Build() + 0x62
    31.    at Unity.IL2CPP.AssemblyConversion.Phases.InitializePhase.Run(AssemblyConversionContext) + 0x319
    32.    at Unity.IL2CPP.AssemblyConversion.Classic.ClassicConverter.Run(AssemblyConversionContext) + 0x11
    33.    at Unity.IL2CPP.AssemblyConversion.AssemblyConverter.ConvertAssemblies(AssemblyConversionContext, ConversionMode) + 0x24
    34.    at Unity.IL2CPP.AssemblyConversion.AssemblyConverter.ConvertAssemblies(TinyProfiler2, AssemblyConversionInputData, AssemblyConversionParameters, AssemblyConversionInputDataForTopLevelAccess) + 0x17f
    35.  
    36. UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
    37.  
     
  17. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,674
    That sounds like you have a mismatching .mdb or .pdb file next to one of your managed .dll files in the project. Look for .mdb or .pdb files that have timestamps that don't match the .dll file and delete them.
     
  18. NUTRACTOR

    NUTRACTOR

    Joined:
    Dec 1, 2014
    Posts:
    8
    Thank you.
    I was able to delete the .mdb and .pdb files and build.
     
  19. jinn97

    jinn97

    Joined:
    Oct 22, 2020
    Posts:
    22
    Building Library\Bee\artifacts\Android\ManagedStripped failed with output:
    C:\Program Files\Unity\Hub\Editor\2023.2.18f1\Editor\Data\il2cpp\build\deploy\UnityLinker.exe @Library\Bee\artifacts\rsp\3806029852383503544.rsp
    Fatal error in Unity CIL Linker
    System.Xml.XmlException: Root element is missing.
    at System.Xml.XmlTextReaderImpl.Throw(Exception e)
    at System.Xml.XmlTextReaderImpl.ThrowWithoutLineInfo(String res)
    at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
    at System.Xml.XPath.XPathDocument.LoadFromReader(XmlReader reader, XmlSpace space)
    at System.Xml.XPath.XPathDocument..ctor(String uri, XmlSpace space)
    at Unity.Linker.UnityDriver.ParseArgumentsNormalMode(LinkRequest linkerOptions, UnityPipeline p, UnityLinkContext context, ArrayList custom_steps, Boolean usingCustomLogger, I18nAssemblies& assemblies)
    at Unity.Linker.UnityDriver.UnityRun(UnityLinkContext context, UnityPipeline p, LinkRequest linkerOptions, TinyProfiler2 tinyProfiler, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling(TinyProfiler2 tinyProfiler, ILogger customLogger)
    at Unity.Linker.UnityDriver.RunDriverWithoutErrorHandling()
    at Unity.Linker.UnityDriver.RunDriver()

    UnityEngine.GUIUtility:processEvent (int,intptr,bool&) is there a fix for this?