I've an Android app that compiles and runs in Debug mode. When I set it to Release mode, I receive following error during compilation:
XALNK7001: System.NullReferenceException: Object reference not set to an instance of an object.
at MonoDroid.Tuner.AddKeepAlivesStep.AddKeepAlives(TypeDefinition type)
at MonoDroid.Tuner.AddKeepAlivesStep.AddKeepAlives(AssemblyDefinition assembly)
at MonoDroid.Tuner.AddKeepAlivesStep.ProcessAssembly(AssemblyDefinition assembly)
at Mono.Linker.Steps.BaseStep.Process(LinkContext context)
at Mono.Linker.Pipeline.ProcessStep(LinkContext context, IStep step)
at Mono.Linker.Pipeline.Process(LinkContext context)
at MonoDroid.Tuner.Linker.Process(LinkerOptions options, ILogger logger, LinkContext& context)
at Xamarin.Android.Tasks.LinkAssemblies.Execute(DirectoryAssemblyResolver res)
at Xamarin.Android.Tasks.LinkAssemblies.RunTask()
at Microsoft.Android.Build.Tasks.AndroidTask.Execute() in /Users/runner/work/1/s/xamarin-android/external/xamarin-android-tools/src/Microsoft.Android.Build.BaseTasks/AndroidTask.cs:line 17 Jokes.Droid
Can anyone help me? What could be the reason of this error?