Hi
I'm doing a Mono project on Mac and I've seem to hit a bug. It affects all version found on Nuget after v7.3.4830 - meaning that the bug is present in the following versions:
7.4.5196
8.0.5449
8.0.5449.1
8.1.5717
It's triggered running the following lines of code:
ikvm.runtime.Startup.addBootClassPathAssembly(
System.Reflection.Assembly.GetAssembly(
typeof(org.slf4j.impl.StaticLoggerBinder)));
I'm running on Mono JIT compiler version 4.6.2 (mono-4.6.0-branch/08fd525 Thu Nov 10 20:28:28 EST 2016)
System.MissingMethodException: Method 'IKVM.Attributes.PackageListAttribute..ctor' not found.
at at (wrapper managed-to-native) System.MonoCustomAttrs:GetCustomAttributesInternal (System.Reflection.ICustomAttributeProvider,System.Type,bool)
at System.MonoCustomAttrs.GetCustomAttributesBase (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inheritedOnly) [0x00019] in /private/tmp/source-mono-4.6.0/bockbuild-mono-4.6.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/corlib/System/MonoCustomAttrs.cs:128
at System.MonoCustomAttrs.GetCustomAttributes (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inherit) [0x00040] in /private/tmp/source-mono-4.6.0/bockbuild-mono-4.6.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/corlib/System/MonoCustomAttrs.cs:158
at System.Reflection.MonoModule.GetCustomAttributes (System.Type attributeType, System.Boolean inherit) [0x00000] in /private/tmp/source-mono-4.6.0/bockbuild-mono-4.6.0-branch/profiles/mono-mac-xamarin/build-root/mono-x86/mcs/class/corlib/System.Reflection/MonoModule.cs:129
at IKVM.Internal.AttributeHelper.GetJavaModuleAttributes (System.Reflection.Module mod) [0x00000] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at IKVM.Internal.AssemblyClassLoader+AssemblyLoader..ctor (System.Reflection.Assembly assembly) [0x00034] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at IKVM.Internal.AssemblyClassLoader..ctor (System.Reflection.Assembly assembly, System.String[] fixedReferences) [0x00008] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at IKVM.Internal.AssemblyClassLoader..ctor (System.Reflection.Assembly assembly) [0x00000] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at IKVM.Internal.AssemblyClassLoader.Create (System.Reflection.Assembly assembly) [0x0002f] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at IKVM.Internal.AssemblyClassLoader.FromAssembly (System.Reflection.Assembly assembly) [0x00026] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at Java_ikvm_runtime_Startup.addBootClassPathAssembly (System.Reflection.Assembly asm) [0x00005] in <348dbf156c634ec3bfe46b06f5a0b9f2>:0
at ikvm.runtime.Startup.addBootClassPathAssembly (System.Reflection.Assembly a) [0x00000] in <abb781df9cb248918c4b2c1c2d511142>:0
at …</abb781df9cb248918c4b2c1c2d511142>
You are probably mixing different ikvm runtimes or assemblies compiled with different versions of ikvmc.