Hello! I’m getting the below error when trying to build to Android.
I’m currently using using Unity 2022.3.4f1 but also tried the upgrade to 2022.3.9f1 - no luck.
It works well on PC, and builds fine for iOS - but shows below error when trying to build on Android.
Things I’ve tried so far:
- Deleting Library folder and restarting
- Reimport All on Assets
- Upgrading to newer Unity 2022.3.9f1
- Removing some of the packages (Auth0, iOS Goodies - whatever I could without completely breaking the project)
- Changing minimum API Level & Target API
- Creating new project with same Unity version - this one builds just fine
- Changing to Mono and building the apk works but I need ARM64 and *.aab build
There are following Plugins in the project (also attached Packages pic):
-
AdvancedInputField
-
Android Goodies
-
Auth0
-
Firebase
-
iOS Goodies
-
MuteSwitchDetector
-
QFSW
-
SaveToMp3
-
Simple Scroll-Snap
-
BetterIU
Attached my build settings / other related files.
Any help would be much appreciated!
ERROR:
C:\Program Files\Unity\Hub\Editor\2022.3.4f1\Editor\Data\il2cpp\build\deploy\il2cpp.exe @Library\Bee\artifacts\rsp\5757077050576414663.rsp
Error: IL2CPP error (no further information about what managed code was being converted is available)
System.AggregateException: One or more errors occurred. (Unresolved type reference : System.Security.Cryptography.X509Certificates.X509Certificate2 in module System.IdentityModel.Tokens.Jwt.dll with scope Microsoft.IdentityModel.Tokens, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35)
—> System.ArgumentException: Unresolved type reference : System.Security.Cryptography.X509Certificates.X509Certificate2 in module System.IdentityModel.Tokens.Jwt.dll with scope Microsoft.IdentityModel.Tokens, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35
at Unity.IL2CPP.DataModel.TypeContext.GetDef(TypeReference reference)
at Unity.IL2CPP.DataModel.BuildLogic.TypeReferenceResolver.ResolveTypeReference(TypeReference typeReference, MappingContext mappingContext, CecilSourcedAssemblyData assembly)
at Unity.IL2CPP.DataModel.BuildLogic.TypeReferenceResolver.ResolveAssemblyTypeReferences(CecilSourcedAssemblyData assembly, ReadOnlyHashSet1 typeReferences, ReadOnlyHashSet1 genericInstances)
at Unity.IL2CPP.DataModel.BuildLogic.DataModelBuilder.<>c__DisplayClass16_0.b__0(CecilSourcedAssemblyData data)
at System.Threading.Tasks.Parallel.<>c__DisplayClass33_02.<ForEachWorker>b__0(Int32 i) at System.Threading.Tasks.Parallel.<>c__DisplayClass19_01.b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
— End of stack trace from previous location —
at System.Threading.Tasks.Parallel.<>c__DisplayClass19_01.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion) at System.Threading.Tasks.TaskReplicator.Replica.Execute() --- End of inner exception stack trace --- at System.Threading.Tasks.TaskReplicator.Run[TState](ReplicatableUserAction1 action, ParallelOptions options, Boolean stopOnFirstFailure)
at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Func4 bodyWithLocal, Func1 localInit, Action1 localFinally) --- End of stack trace from previous location --- at System.Threading.Tasks.Parallel.ThrowSingleCancellationExceptionOrOtherException(ICollection exceptions, CancellationToken cancelToken, Exception otherException) at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Func4 bodyWithLocal, Func1 localInit, Action1 localFinally)
at System.Threading.Tasks.Parallel.ForEachWorker[TSource,TLocal](IList1 list, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Action3 bodyWithStateAndIndex, Func4 bodyWithStateAndLocal, Func5 bodyWithEverything, Func1 localInit, Action1 localFinally)
at System.Threading.Tasks.Parallel.ForEachWorker[TSource,TLocal](IEnumerable1 source, ParallelOptions parallelOptions, Action1 body, Action2 bodyWithState, Action3 bodyWithStateAndIndex, Func4 bodyWithStateAndLocal, Func5 bodyWithEverything, Func1 localInit, Action1 localFinally)
at System.Threading.Tasks.Parallel.ForEach[TSource](IEnumerable1 source, Action1 body)
at Unity.IL2CPP.DataModel.BuildLogic.Utils.ParallelHelpers.ForEach[TSource](IEnumerable1 source, Action1 func, Boolean enableSerial)
at Unity.IL2CPP.DataModel.BuildLogic.DataModelBuilder.Build()
at Unity.IL2CPP.AssemblyConversion.Phases.InitializePhase.Run(AssemblyConversionContext context)
at Unity.IL2CPP.AssemblyConversion.Classic.ClassicConverter.Run(AssemblyConversionContext context)
at Unity.IL2CPP.AssemblyConversion.AssemblyConverter.ConvertAssemblies(AssemblyConversionContext context, ConversionMode conversionMode)
at Unity.IL2CPP.AssemblyConversion.AssemblyConverter.ConvertAssemblies(TinyProfiler2 tinyProfiler, AssemblyConversionInputData data, AssemblyConversionParameters parameters, AssemblyConversionInputDataForTopLevelAccess dataForTopLevel)
0x00007ff667cc3a2d (Unity) StackWalker::GetCurrentCallstack
0x00007ff667cc89d9 (Unity) StackWalker::ShowCallstack
0x00007ff668c940e1 (Unity) GetStacktrace
0x00007ff669355b32 (Unity) DebugStringToFile
0x00007ff666bf4e76 (Unity) DebugLogHandler_CUSTOM_Internal_Log
0x000001e27d89fc0a (Mono JIT Code) (wrapper managed-to-native) UnityEngine.DebugLogHandler:Internal_Log (UnityEngine.LogType,UnityEngine.LogOption,string,UnityEngine.Object)
0x000001e27d89fa7b (Mono JIT Code) UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[ ])
0x000001e27d8c4e2e (Mono JIT Code) UnityEngine.Logger:Log (UnityEngine.LogType,object)
0x000001e1cf8461da (Mono JIT Code) UnityEngine.Debug:LogError (object)
0x000001e16450a2cb (Mono JIT Code) UnityEditor.Modules.BeeBuildPostprocessor:PrintStdoutOnErrorProcessor (Bee.BinLog.NodeFinishedMessage)
0x000001e164507d68 (Mono JIT Code) UnityEditor.Modules.BeeBuildPostprocessor:ReportBuildResults ()
0x000001e1612915a3 (Mono JIT Code) UnityEditor.Modules.BeeBuildPostprocessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs)
0x000001e16108ebbe (Mono JIT Code) UnityEditor.Modules.DefaultBuildPostprocessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs,UnityEditor.BuildProperties&)
0x000001e1610895eb (Mono JIT Code) UnityEditor.Android.AndroidBuildPostprocessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs,UnityEditor.BuildProperties&)
0x000001e1610888e5 (Mono JIT Code) UnityEditor.PostprocessBuildPlayer:Postprocess (UnityEditor.BuildTargetGroup,UnityEditor.BuildTarget,int,string,string,string,int,int,UnityEditor.BuildOptions,UnityEditor.RuntimeClassRegistry,UnityEditor.Build.Reporting.BuildReport)
0x000001e161088f5f (Mono JIT Code) (wrapper runtime-invoke) :runtime_invoke_void_int_int_int_object_object_object_int_int_int_object_object (object,intptr,intptr,intptr)
0x00007fffdcd7e0e4 (mono-2.0-bdwgc) mono_jit_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/mini/mini-runtime.c:3445)
0x00007fffdccbeb84 (mono-2.0-bdwgc) do_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/metadata/object.c:3066)
0x00007fffdccbed1c (mono-2.0-bdwgc) mono_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/metadata/object.c:3113)
0x00007ff667be2534 (Unity) scripting_method_invoke
0x00007ff667bc11b4 (Unity) ScriptingInvocation::Invoke
0x00007ff6696ca051 (Unity) CallMono
0x00007ff6696d2f07 (Unity) PostprocessPlayer
0x00007ff6696cd2f3 (Unity) DoBuildPlayer_PostBuild
0x00007ff6696cb3ee (Unity) DoBuildPlayer
0x00007ff6696bed25 (Unity) BuildPlayer
0x00007ff66745ebdf (Unity) BuildPipeline::BuildPlayerInternalNoCheck
0x00007ff66720342c (Unity) BuildPipeline_CUSTOM_BuildPlayerInternalNoCheck
0x000001e1d1ede898 (Mono JIT Code) (wrapper managed-to-native) UnityEditor.BuildPipeline:BuildPlayerInternalNoCheck (string[ ],string,string,UnityEditor.BuildTargetGroup,UnityEditor.BuildTarget,int,UnityEditor.BuildOptions,string[ ],bool)
0x000001e1d1edd363 (Mono JIT Code) UnityEditor.BuildPlayerWindow/DefaultBuildMethods:BuildPlayer (UnityEditor.BuildPlayerOptions)
0x000001e1d1ed097b (Mono JIT Code) UnityEditor.BuildPlayerWindow:CallBuildMethods (bool,UnityEditor.BuildOptions)
0x000001e2502cc6eb (Mono JIT Code) UnityEditor.BuildPlayerWindow:GUIBuildButtons (UnityEditor.Modules.IBuildWindowExtension,bool,bool,bool,UnityEditor.Build.BuildPlatform,UnityEditor.Modules.IBuildPostprocessor)
0x000001e2502aec43 (Mono JIT Code) UnityEditor.BuildPlayerWindow:ShowBuildTargetSettings ()
0x000001e250286563 (Mono JIT Code) UnityEditor.BuildPlayerWindow:OnGUI ()
0x000001e2780dc54a (Mono JIT Code) UnityEditor.HostView:InvokeOnGUI (UnityEngine.Rect)
0x000001e2780dbfd3 (Mono JIT Code) UnityEditor.DockArea:smile:rawView (UnityEngine.Rect)
0x000001e2780814c3 (Mono JIT Code) UnityEditor.DockArea:OldOnGUI ()
0x000001e277076ff1 (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:smile:oOnGUI (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,bool,UnityEngine.Rect,System.Action,bool)
0x000001e0b24aabd3 (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,System.Action,bool)
0x000001e27d684c5b (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,System.Action,bool)
0x000001e27d684973 (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,bool)
0x000001e27d682bcb (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUIRaw (UnityEngine.UIElements.EventBase,bool,bool)
0x000001e27d679323 (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUI (UnityEngine.UIElements.EventBase,bool,bool)
0x000001e240e11a33 (Mono JIT Code) UnityEngine.UIElements.IMGUIContainer:ProcessEvent (UnityEngine.UIElements.EventBase)
0x000001e240e10a93 (Mono JIT Code) UnityEngine.UIElements.CallbackEventHandler:HandleEvent (UnityEngine.UIElements.EventBase)
0x000001e240e0f57c (Mono JIT Code) UnityEngine.UIElements.CallbackEventHandler:HandleEventAtCurrentTargetAndPhase (UnityEngine.UIElements.EventBase)
0x000001e240e0ea4b (Mono JIT Code) UnityEngine.UIElements.CallbackEventHandler:HandleEventAtTargetPhase (UnityEngine.UIElements.EventBase)
0x000001e27d66f573 (Mono JIT Code) UnityEngine.UIElements.MouseCaptureDispatchingStrategy:smile:ispatchEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
0x000001e24a12b596 (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,bool)
0x000001e24a129e2b (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
0x000001e240dd6b2b (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:ProcessEventQueue ()
0x000001e240dd670b (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:OpenGate ()
0x000001e240dd648b (Mono JIT Code) UnityEngine.UIElements.EventDispatcherGate:smile:ispose ()
0x000001e24a12ae03 (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
0x000001e24a128d7b (Mono JIT Code) UnityEngine.UIElements.EventDispatcher:smile:ispatch (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,UnityEngine.UIElements.DispatchMode)
0x000001e24a12888b (Mono JIT Code) UnityEngine.UIElements.BaseVisualElementPanel:SendEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.DispatchMode)
0x000001e2562ca673 (Mono JIT Code) UnityEngine.UIElements.UIElementsUtility:smile:oDispatch (UnityEngine.UIElements.BaseVisualElementPanel)
0x000001e2562c95d3 (Mono JIT Code) UnityEngine.UIElements.UIElementsUtility:UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (int,intptr,bool&)
0x000001e2562c8f44 (Mono JIT Code) UnityEngine.UIElements.UIEventRegistration:ProcessEvent (int,intptr)
0x000001e2562c8c3b (Mono JIT Code) UnityEngine.UIElements.UIEventRegistration/<>c:<.cctor>b__1_2 (int,intptr)
0x000001e2562c86e5 (Mono JIT Code) UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
0x000001e2562c8926 (Mono JIT Code) (wrapper runtime-invoke) :runtime_invoke_void_int_intptr_intptr& (object,intptr,intptr,intptr)
0x00007fffdcd7e0e4 (mono-2.0-bdwgc) mono_jit_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/mini/mini-runtime.c:3445)
0x00007fffdccbeb84 (mono-2.0-bdwgc) do_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/metadata/object.c:3066)
0x00007fffdccbed1c (mono-2.0-bdwgc) mono_runtime_invoke (at C:/build/output/Unity-Technologies/mono/mono/metadata/object.c:3113)
0x00007ff667be2534 (Unity) scripting_method_invoke
0x00007ff667bc11b4 (Unity) ScriptingInvocation::Invoke
0x00007ff667bbbe05 (Unity) ScriptingInvocation::Invoke
0x00007ff667d0e14a (Unity) Scripting::UnityEngine::GUIUtilityProxy::ProcessEvent
0x00007ff668700238 (Unity) GUIView::ProcessRetainedMode
0x00007ff668cc63e4 (Unity) GUIView::OnInputEvent
0x00007ff668700183 (Unity) GUIView::ProcessInputEventFromAPI
0x00007ff668700058 (Unity) GUIView::ProcessInputEvent
0x00007ff668cc71ec (Unity) GUIView::ProcessEventMessages
0x00007ff668cc0f0a (Unity) GUIView::GUIViewWndProc
0x00007ff89dc88241 (USER32) DispatchMessageW
0x00007ff89dc87d01 (USER32) DispatchMessageW
0x00007ff668c9a643 (Unity) MainMessageLoop
0x00007ff668c9f8c0 (Unity) WinMain
0x00007ff66a0842fe (Unity) __scrt_common_main_seh
0x00007ff89dba257d (KERNEL32) BaseThreadInitThunk
0x00007ff89eb6aa68 (ntdll) RtlUserThreadStart




