我卸载了Xamarin Studio(因为xamarin是免费的)并试图在VS上运行我的应用程序而且我收到了这个错误:
System.DllNotFoundException:java-interop
我不知道如何解决这个问题,已在互联网上搜索过,一无所获。
这是日志
Loaded assembly: /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.Xml.XmlSerializer.dll
Loaded assembly: /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.ServiceModel.Internals.dll [External]
Loaded assembly: /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/Mono.Android.dll
Loaded assembly: /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/Java.Interop.dll [External]
03-31 15:12:06.457 D/Mono ( 2254): Assembly Ref addref Java.Interop[0x9e01f9a0] -> System.Collections.Concurrent[0xb43f0700]: 2
03-31 15:12:06.457 D/Mono ( 2254): Assembly Ref addref System.Collections.Concurrent[0xb43f0700] -> mscorlib[0xb4250dc0]: 4
03-31 15:12:06.457 D/Mono ( 2254): Assembly Ref addref Java.Interop[0x9e01f9a0] -> System.Reflection[0xb43fc700]: 2
03-31 15:12:06.457 D/Mono ( 2254): Assembly Ref addref System.Reflection[0xb43fc700] -> mscorlib[0xb4250dc0]: 5
03-31 15:12:06.469 D/Mono ( 2254): Assembly Ref addref Java.Interop[0x9e01f9a0] -> System.Threading[0x9e01f280]: 2
03-31 15:12:06.469 D/Mono ( 2254): Assembly Ref addref System.Threading[0x9e01f280] -> mscorlib[0xb4250dc0]: 6
03-31 15:12:06.470 D/Mono ( 2254): Assembly Ref addref Java.Interop[0x9e01f9a0] -> System.Diagnostics.Debug[0xb43f0a60]: 2
03-31 15:12:06.470 D/Mono ( 2254): Assembly Loader probing location: '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll'.
03-31 15:12:06.470 D/Mono ( 2254): Image addref System[0x9e01fbe0] -> /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll[0x9e023500]: 2
03-31 15:12:06.470 D/Mono ( 2254): Assembly System[0x9e01fbe0] added to domain RootDomain, ref_count=1
03-31 15:12:06.470 D/Mono ( 2254): AOT module '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll.so' not found: dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libaot-System.dll.so" not found
03-31 15:12:06.470 D/Mono ( 2254): AOT module '/Users/builder/data/lanes/3053/a94a03b5/source/monodroid/builds/install/mono-x86/lib/mono/aot-cache/x86/System.dll.so' not found: dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libaot-System.dll.so" not found
03-31 15:12:06.470 D/Mono ( 2254): Assembly Loader loaded assembly from location: '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll'.
03-31 15:12:06.470 D/Mono ( 2254): Config attempting to parse: '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll.config'.
03-31 15:12:06.470 D/Mono ( 2254): Config attempting to parse: '/Users/builder/data/lanes/3053/a94a03b5/source/monodroid/builds/install/mono-x86/etc/mono/assemblies/System/System.config'.
03-31 15:12:06.470 D/Mono ( 2254): Assembly Ref addref System.Diagnostics.Debug[0xb43f0a60] -> System[0x9e01fbe0]: 2
03-31 15:12:06.470 D/Mono ( 2254): Assembly Ref addref System[0x9e01fbe0] -> mscorlib[0xb4250dc0]: 7
Loaded assembly: /storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/System.dll
03-31 15:12:06.475 D/Mono ( 2254): Assembly Ref addref Java.Interop[0x9e01f9a0] -> System.Runtime.InteropServices[0xb43fcac0]: 2
03-31 15:12:06.475 D/Mono ( 2254): Assembly Ref addref System.Runtime.InteropServices[0xb43fcac0] -> mscorlib[0xb4250dc0]: 8
03-31 15:12:06.478 D/Mono ( 2254): DllImport attempting to load: 'java-interop'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop.so" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library 'libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop.so" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library 'java-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/java-interop" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop" not found'.
03-31 15:12:06.478 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.479 W/Mono ( 2254): DllImport unable to load library 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport attempting to load: 'java-interop'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop.so" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library 'java-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/java-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop" not found'.
03-31 15:12:06.479 D/Mono ( 2254): DllImport error loading library '/storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//storage/emulated/0/Android/data/MaoNaRoda.Droid/files/.__override__/libjava-interop.so" not found'.
03-31 15:12:06.481 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop" not found'.
03-31 15:12:06.481 D/Mono ( 2254): DllImport error loading library '/system/lib/libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86//system/lib/libjava-interop.so" not found'.
03-31 15:12:06.481 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.482 D/Mono ( 2254): DllImport error loading library 'libjava-interop.so': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop.so" not found'.
03-31 15:12:06.482 D/Mono ( 2254): DllImport error loading library 'libjava-interop': 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
03-31 15:12:06.482 W/Mono ( 2254): DllImport unable to load library 'dlopen failed: library "/data/app/MaoNaRoda.Droid-1/lib/x86/libjava-interop" not found'.
Unhandled Exception:
System.DllNotFoundException: java-interop
更多细节
03-31 16:23:23.607 E/mono ( 2743):
03-31 16:23:23.607 E/mono ( 2743): Unhandled Exception:
03-31 16:23:23.607 E/mono ( 2743): System.DllNotFoundException: java-interop
03-31 16:23:23.607 E/mono ( 2743): at (wrapper managed-to-native) Java.Interop.NativeMethods:java_interop_jnienv_get_java_vm (intptr,intptr&)
03-31 16:23:23.607 E/mono ( 2743): at Java.Interop.JniEnvironment+References.GetJavaVM (IntPtr jnienv, System.IntPtr& vm) [0x00003] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:163
03-31 16:23:23.607 E/mono ( 2743): at Java.Interop.JniEnvironmentInfo.set_EnvironmentPointer (IntPtr value) [0x0002e] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:190
03-31 16:23:23.607 E/mono ( 2743): at Java.Interop.JniEnvironmentInfo..ctor (IntPtr environmentPointer, Java.Interop.JniRuntime runtime) [0x00009] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:215
03-31 16:23:23.607 E/mono ( 2743): at Java.Interop.JniRuntime..ctor (Java.Interop.CreationOptions options) [0x00105] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniRuntime.cs:192
03-31 16:23:23.607 E/mono ( 2743): at Android.Runtime.AndroidRuntime..ctor (IntPtr jnienv, IntPtr vm, Boolean allocNewObjectSupported, IntPtr classLoader, IntPtr classLoader_loadClass) [0x00000] in /Users/builder/data/lanes/2923/a908ff16/source/monodroid/src/Mono.Android/src/Runtime/AndroidRuntime.cs:17
03-31 16:23:23.607 E/mono ( 2743): at Android.Runtime.JNIEnv.Initialize (Android.Runtime.JnienvInitializeArgs* args) [0x00168] in /Users/builder/data/lanes/2923/a908ff16/source/monodroid/src/Mono.Android/src/Runtime/JNIEnv.cs:237
03-31 16:23:23.607 E/mono-rt ( 2743): [ERROR] FATAL UNHANDLED EXCEPTION: System.DllNotFoundException: java-interop
03-31 16:23:23.607 E/mono-rt ( 2743): at (wrapper managed-to-native) Java.Interop.NativeMethods:java_interop_jnienv_get_java_vm (intptr,intptr&)
03-31 16:23:23.607 E/mono-rt ( 2743): at Java.Interop.JniEnvironment+References.GetJavaVM (IntPtr jnienv, System.IntPtr& vm) [0x00003] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:163
03-31 16:23:23.607 E/mono-rt ( 2743): at Java.Interop.JniEnvironmentInfo.set_EnvironmentPointer (IntPtr value) [0x0002e] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:190
03-31 16:23:23.607 E/mono-rt ( 2743): at Java.Interop.JniEnvironmentInfo..ctor (IntPtr environmentPointer, Java.Interop.JniRuntime runtime) [0x00009] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniEnvironment.cs:215
03-31 16:23:23.607 E/mono-rt ( 2743): at Java.Interop.JniRuntime..ctor (Java.Interop.CreationOptions options) [0x00105] in /Users/builder/data/lanes/2923/a908ff16/source/Java.Interop/src/Java.Interop/Java.Interop/JniRuntime.cs:192
03-31 16:23:23.607 E/mono-rt ( 2743): at Android.Runtime.AndroidRuntime..ctor (IntPtr jnienv, IntPtr vm, Boolean allocNewObjectSupported, IntPtr classLoader, IntPtr classLoader_loadClass) [0x00000] in /Users/builder/data/lanes/2923/a908ff16/source/monodroid/src/Mono.Android/src/Runtime/AndroidRuntime.cs:17
03-31 16:23:23.607 E/mono-rt ( 2743): at Android.Runtime.JNIEnv.Initialize (Android.Runtime.JnienvInitializeArgs* args) [0x00168] in /Users/builder/data/lanes/2923/a908ff16/source/monodroid/src/Mono.Android/src/Runtime/JNIEnv.cs:237
答案 0 :(得分:5)
感谢您提交相应的错误报告:https://bugzilla.xamarin.com/show_bug.cgi?id=40031。还要感谢您对该错误的后续评论,其中您提到您能够通过以下方式解决问题:
听起来这些步骤应该可以为其他可能遇到问题的人解决问题。
(作为旁注,有一个即将到来的修复另一个相关的错误,其中“陈旧”的设备上的文件导致错误。我认为该修复将来有助于防止此类问题。)