Unity iOS构建错误UnusedBytecodeStripper2.exe无法正常运行

时间:2017-02-01 09:02:34

标签: c# ios unity3d mono il2cpp

我在构建iOS应用程序时遇到此错误。脚本后端设置为IL2CPP,架构是通用的。我知道我的项目中的插件使用了zxing库,这导致了这个错误。当我为Android构建但无法获得ios构建时,我没有遇到任何错误。除了删除插件之外,还有其他方法可以构建吗?

  

运行C:\ Program Files \ Unity \ Editor \ Data \ Tools / UnusedByteCodeStripper2 / UnusedBytecodeStripper2.exe -out“C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed”失败-l none -c link -x“C:\ Program Files \ Unity \ Editor \ Data \ Tools \ native_link.xml”-f“C:\ Program Files \ Unity \ Editor \ Data \ il2cpp \ LinkerDescriptors”-x“C :\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed .. \ platform_native_link.xml“-x”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS / Temp / StagingArea / Data / methods_pointedto_by_uievents.xml“-d”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed“-a”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ Assembly-CSharp-firstpass.dll“-a”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ Assembly-CSharp.dll“-a “C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ Assembly-UnityScript.dll”-a“C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ UnityEngine.UI.dll“-a”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ cscanner.dll“ - a“C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ Google.ProtocolBuffers.dll”-a“C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ Google.ProtocolBuffers.Serialization.dll“-a”C:\ Users \ Koray \ Source \ Repos \ NewJoyiOS \ NewJoyiOS \ Temp \ StagingArea \ Data \ Managed \ NativeToolkitWP8.dll“

     

标准输出:   Mono CIL Linker中的致命错误   Mono.Cecil.AssemblyResolutionException:无法解析程序集:'zxing.unity,Version = 0.12.0.0,Culture = neutral,PublicKeyToken = null'     在Mono.Linker.LinkContext.Resolve(IMetadataScope范围)[0x00000] in:0     在Mono.Linker.Steps.ResolveFromXmlStep.ProcessReferences(Mono.Cecil.AssemblyDefinition assembly,Mono.Linker.LinkContext context)[0x00000] in:0     在Mono.Linker.Steps.ResolveFromXmlStep.GetAssembly(Mono.Linker.LinkContext context,System.String assemblyName)[0x00000] in:0     在Mono.Linker.Steps.ResolveFromXmlStep.ProcessAssemblies(Mono.Linker.LinkContext context,System.Xml.XPath.XPathNodeIterator iterator)[0x00000] in:0     在Mono.Linker.Steps.ResolveFromXmlStep.Process()[0x00000] in:0     在Mono.Linker.Steps.BaseStep.Process(Mono.Linker.LinkContext context)[0x00000] in:0     在Mono.Linker.Pipeline.Process(Mono.Linker.LinkContext context)[0x00000] in:0     在Mono.Linker.Driver.Run()[0x00000]中:0     在Mono.Linker.Driver.RunDriver(Mono.Linker.Driver驱动程序)[0x00000] in:0   标准错误:

     

UnityEngine.Debug:LOGERROR(对象)   UnityEditorInternal.Runner:RunManagedProgram(String,String,String,CompilerOutputParserBase)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:66)   UnityEditorInternal.AssemblyStripper:RunAssemblyLinker(IEnumerable 1, String&, String&, String, String) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:192) UnityEditorInternal.AssemblyStripper:StripAssembliesTo(String, String, String&, String&, String, String, IEnumerable 1)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:185)   UnityEditorInternal.AssemblyStripper:Strip(String,String,String&,String&,String,String,IEnumerable 1) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:136) UnityEditorInternal.AssemblyStripper:Strip(String[], String[], String, String, String&, String&, String, String, IEnumerable 1)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs :121)   UnityEditorInternal.IL2CPPBuilder:RunAssemblyStripper(IEnumerable,String,String [],String [],String)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:477)   UnityEditorInternal.IL2CPPBuilder:StripAssemblies(String [],String)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:465)   UnityEditorInternal.IL2CPPBuilder:Run()(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:293)   UnityEditorInternal.IL2CPPUtils:RunIl2Cpp(String,String,IIl2CppPlatformProvider,Action`1,RuntimeClassRegistry)(在C:/buildslave/unity/build/Editor/Mono/BuildPipeline/Il2Cpp/IL2CPPUtils.cs:211)   UnityEditor.HostView:OnGUI()

1 个答案:

答案 0 :(得分:0)

项目中是否有zxing.unity.dll文件?看起来装配丢失了。我怀疑项目中有一个引用该程序集的link.xml文件。如果删除该link.xml文件,则可能会有效。

请注意,这可能适用于Android / Mono,因为默认情况下不启用托管代码剥离,因此会忽略项目中的link.xml文件。

作为参考,有关使用Unity here的link.xml文件的更多详细信息。