.NET for Android error JAVA0000

Example messages

MSBUILD : java error JAVA0000: Error in obj/Debug/net7.0-android/lp/59/jl/classes.jar:android/support/v4/app/INotificationSideChannel$Stub.class: [Example.csproj]
MSBUILD : java error JAVA0000: Type android.support.v4.app.INotificationSideChannel$Stub is defined multiple times: obj/Debug/net7.0-android/lp/59/jl/classes.jar:android/support/v4/app/INotificationSideChannel$Stub.class, obj/Debug/net7.0-android/lp/4/jl/bin/classes.jar:android/support/v4/app/INotificationSideChannel$Stub.class [Example.csproj]
MSBUILD : java error JAVA0000: Compilation failed [Example.csproj]
MSBUILD : java error JAVA0000: java.lang.RuntimeException: com.android.tools.r8.CompilationFailedException: Compilation failed to complete, origin: obj/Debug/net7.0-android/lp/59/jl/classes.jar [Example.csproj]
MSBUILD : java error JAVA0000: android/support/v4/app/INotificationSideChannel$Stub.class [Example.csproj]
MSBUILD : java error JAVA0000: 	at com.android.tools.r8.internal.Bj.a(R8_3.3.28_2aaf796388b4e9f6bed752d926eca110512a53a3f09a8d755196089c1cfdf799:98) [Example.csproj]
MSBUILD : java error JAVA0000: 	at com.android.tools.r8.D8.main(R8_3.3.28_2aaf796388b4e9f6bed752d926eca110512a53a3f09a8d755196089c1cfdf799:4) [Example.csproj]

Issue

During a normal .NET for Android build various java tools are run. This message indicates that [java][java] tool which was run raised an error.

Solution

Look at the stack trace included in the error. This should provide some clues into why the error occured.

Consider submitting a bug if you are getting this error under normal circumstances.