dotnet / runtimelab

This repo is for experimentation and exploring new ideas that may or may not make it into the main dotnet/runtime repo.
MIT License
1.41k stars 197 forks source link

[NativeAOT][Build Error]One or more errors occurred. #1965

Closed submaie closed 2 years ago

submaie commented 2 years ago

Building Host Operation System: Windows 11 Pro v 25182.1010 TargetFramework : net6.0-windows10.0.19041.0 TrimMode: copyused Target runtime: win-x64

Package r:eference : Avalonia.Desktop v 0.10.18 Package r:eference : Avalonia.AvaloniaEdit v 0.10.12.2 Package r:eference : Microsoft.Data.Sqlite v 6.0.8 Package r:eference : NPOI v 2.5.6 Package r:eference : System.Data.OleDb v6.0.0

Error Msg: 2022/8/24 10:43:17 System.AggregateException: One or more errors occurred. ---> Microsoft.WebTools.Shared.Exceptions.WebToolsException: 发布时遇到错误。我们无法确定错误的原因。有关详细信息,请查看输出日志。 --- End of inner exception stack trace --- ---> (内部异常 #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: 发布时遇到错误。我们无法确定错误的原因。有关详细信息,请查看输出日志。<---

Microsoft.WebTools.Shared.Exceptions.WebToolsException: 发布时遇到错误。我们无法确定错误的原因。有关详细信息,请查看输出日志。

=================== One or more errors occurred. (Code generation failed for method '[Microsoft.Windows.SDK.NET]+Windows.Foundation.AsyncOperationWithProgressCompletedHandler2<TResult,TProgress><System.__Canon,int32>..cctor()') 1>System.AggregateException: One or more errors occurred. (Code generation failed for method '[Microsoft.Windows.SDK.NET]<GuidPatcherImplementationDetails>+<SignatureCache>Windows.Foundation.AsyncOperationWithProgressCompletedHandler2<TResult,TProgress><System.Canon,int32>..cctor()') 1> ---> ILCompiler.CodeGenerationFailedException: Code generation failed for method '[Microsoft.Windows.SDK.NET]+Windows.Foundation.AsyncOperationWithProgressCompletedHandler`2<TResult,TProgress><System.Canon,int32>..cctor()' 1> ---> System.InvalidOperationException: [Microsoft.Windows.SDK.NET]+Windows.Foundation.AsyncOperationWithProgressCompletedHandler2<TResult,TProgress><System.__Canon,int32>: TypeHandle: [Microsoft.Windows.SDK.NET]<GuidPatcherImplementationDetails>+<SignatureCache>Windows.Foundation.AsyncOperationWithProgressCompletedHandler2<TResult,TProgress><!0_System.Canon,int32> 1> at ILCompiler.DependencyAnalysis.PrecomputedDictionaryLayoutNode.GetSlotForEntry(GenericLookupResult entry) in //src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/DependencyAnalysis/DictionaryLayoutNode.cs:line 230 1> at ILCompiler.Compilation.ComputeGenericLookup(MethodDesc contextMethod, ReadyToRunHelperId lookupKind, Object targetOfLookup) in //src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Compilation.cs:line 398 1> at Internal.JitInterface.CorInfoImpl.ComputeLookup(CORINFO_RESOLVED_TOKEN& pResolvedToken, Object entity, ReadyToRunHelperId helperId, CORINFOLOOKUP& lookup) in //src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs:line 257 1> at Internal.JitInterface.CorInfoImpl.embedGenericHandle(CORINFO_RESOLVED_TOKEN& pResolvedToken, Boolean fEmbedParent, CORINFO_GENERICHANDLERESULT& pResult) in //src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs:line 1746 1> at Internal.JitInterface.CorInfoImpl._embedGenericHandle(IntPtr thisHandle, IntPtr ppException, CORINFO_RESOLVED_TOKEN pResolvedToken, Byte fEmbedParent, CORINFO_GENERICHANDLERESULT* pResult) in //src/coreclr/tools/Common/JitInterface/CorInfoBase.cs:line 1987 1> --- End of inner exception stack trace --- 1> at Internal.JitInterface.CorInfoImpl.CompileMethodInternal(IMethodNode methodCodeNodeNeedingCode, MethodIL methodIL) in //src/coreclr/tools/Common/JitInterface/CorInfoImpl.cs:line 379 1> at Internal.JitInterface.CorInfoImpl.CompileMethod(MethodCodeNode methodCodeNodeNeedingCode, MethodIL methodIL) in //src/coreclr/tools/aot/ILCompiler.RyuJit/JitInterface/CorInfoImpl.RyuJit.cs:line 63 1> at ILCompiler.RyuJitCompilation.CompileSingleMethod(CorInfoImpl corInfo, MethodCodeNode methodCodeNodeNeedingCode) in //src/coreclr/tools/aot/ILCompiler.RyuJit/Compiler/RyuJitCompilation.cs:line 190 1> at ILCompiler.RyuJitCompilation.CompileSingleMethod(MethodCodeNode methodCodeNodeNeedingCode) in //src/coreclr/tools/aot/ILCompiler.RyuJit/Compiler/RyuJitCompilation.cs:line 175 1> at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.b1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion) 1>--- End of stack trace from previous location --- 1> at System.Threading.Tasks.Parallel.<>c__DisplayClass19_01.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion) 1> at System.Threading.Tasks.TaskReplicator.Replica.Execute() 1> --- End of inner exception stack trace --- 1> at System.Threading.Tasks.TaskReplicator.Run[TState](ReplicatableUserAction1 action, ParallelOptions options, Boolean stopOnFirstFailure) 1> at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Func4 bodyWithLocal, Func1 localInit, Action1 localFinally) 1>--- End of stack trace from previous location --- 1> at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Func4 bodyWithLocal, Func1 localInit, Action1 localFinally) 1> at ILCompiler.RyuJitCompilation.CompileMultiThreaded(List1 methodsToCompile) in /_/src/coreclr/tools/aot/ILCompiler.RyuJit/Compiler/RyuJitCompilation.cs:line 150 1> at ILCompiler.RyuJitCompilation.ComputeDependencyNodeDependencies(List1 obj) in //src/coreclr/tools/aot/ILCompiler.RyuJit/Compiler/RyuJitCompilation.cs:line 140 1> at ILCompiler.DependencyAnalysisFramework.DependencyAnalyzer`2.ComputeMarkedNodes() in //src/coreclr/tools/aot/ILCompiler.DependencyAnalysisFramework/DependencyAnalyzer.cs:line 315 1> at ILCompiler.RyuJitCompilation.CompileInternal(String outputFile, ObjectDumper dumper) in //src/coreclr/tools/aot/ILCompiler.RyuJit/Compiler/RyuJitCompilation.cs:line 88 1> at ILCompiler.Compilation.ILCompiler.ICompilation.Compile(String outputFile, ObjectDumper dumper) in //src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Compilation.cs:line 526 1> at ILCompiler.Program.Run(String[] args) in //src/coreclr/tools/aot/ILCompiler/Program.cs:line 910 1> at ILCompiler.Program.Main(String[] args) in //src/coreclr/tools/aot/ILCompiler/Program.cs:line 1102 1>命令“"C:\Users\username.nuget\packages\runtime.win-x64.microsoft.dotnet.ilcompiler\7.0.0-preview.7.22375.6\tools\ilc" @"obj\x64\Release\net6.0-windows10.0.19041.0\win-x64\native\xReportGenerator.ilc.rsp"”已退出,代码为 1。 ========== “生成”: 0 成功,0 失败,1 更新,0 已跳过 ========== ========== “发布”: 0 成功,1 失败,0已跳过 ==========

jkotas commented 2 years ago

Duplicate of https://github.com/dotnet/runtime/issues/74477