Jason Harrop
2017-01-22 07:45:27 UTC
I'm trying to IKVM https://github.com/plutext/slf4j-net-commons-logging
using IKVMC 8.1.5717.0 to update
https://www.nuget.org/packages/slf4j-NetCommonLogging/
Before doing so, I thought I'd update Common.Logging to v3.3.1.0
I got this error:
[echo] Building slf4j-NetCommonLogging DLL..
[echo]
[exec] IKVM.NET <http://ikvm.net/> Compiler version 8.1.5717.0
[exec] Copyright (C) 2002-2015 Jeroen Frijters
[exec] http://www.ikvm.net/
[exec]
[exec] Error: unable to load assembly 'lib\dotNET\packages\Common.
Logging.3.3.1\lib\net40\Common.Logging.dll'
as it depends on a higher version of mscorlib than the one currently loaded
So I thought I'd try specifying .NET 4 in my ant build file:
<arg value="-nostdlib" />
<arg value="-lib:\windows\microsoft.net\framework\v4.0.30319" />
<arg value="-r:mscorlib.dll" />
(This is a Win 10 machine which has .NET 4.6)
Now I got the curious error:
[echo] Building slf4j-NetCommonLogging DLL..
[echo]
[exec] IKVM.NET <http://ikvm.net/> Compiler version 8.1.5717.0
[exec] Copyright (C) 2002-2015 Jeroen Frijters
[exec] http://www.ikvm.net/
[exec]
[exec] fatal error IKVMC5045: Link error: Method "cli.Common.Logging.
LogManager.GetLogger(Ljava.lang.String;)Lcli.Common.Logging.ILog;" has a
return type "cli.Common.Logging.ILog, Common.Logging.Core, Version=3.3.1.0,
Culture=neutral, PublicKeyToken=af08829b84f0328e"
instead of type "cli.Common.Logging.ILog, Common.Logging.Core,
Version=3.3.1.0, Culture=neutral, PublicKeyToken=af08829b84f0328e" as
expected by "com.plutext.slf4jNetCommonsLogging.NetCommonsLoggerFactory"
Notice the return types look identical.
I also get this same error if I use the net35 /Common.Logging packages
(from nuget) and let ikvmc use its default mscorlib:
<arg
value="-reference:lib/dotNET/packages/Common.Logging.3.3.1/lib/net35/Common.Logging.dll"
/>
<arg value="-reference:lib/dotNET/packages/Common.Logging.Core.
3.3.1/lib/net35/Common.Logging.Core.dll" />
Thoughts?
For now, I've reverted to compiling against Common.Logging 2.1.2 which is
what I had before and which works.
thanks .. Jason
using IKVMC 8.1.5717.0 to update
https://www.nuget.org/packages/slf4j-NetCommonLogging/
Before doing so, I thought I'd update Common.Logging to v3.3.1.0
I got this error:
[echo] Building slf4j-NetCommonLogging DLL..
[echo]
[exec] IKVM.NET <http://ikvm.net/> Compiler version 8.1.5717.0
[exec] Copyright (C) 2002-2015 Jeroen Frijters
[exec] http://www.ikvm.net/
[exec]
[exec] Error: unable to load assembly 'lib\dotNET\packages\Common.
Logging.3.3.1\lib\net40\Common.Logging.dll'
as it depends on a higher version of mscorlib than the one currently loaded
So I thought I'd try specifying .NET 4 in my ant build file:
<arg value="-nostdlib" />
<arg value="-lib:\windows\microsoft.net\framework\v4.0.30319" />
<arg value="-r:mscorlib.dll" />
(This is a Win 10 machine which has .NET 4.6)
Now I got the curious error:
[echo] Building slf4j-NetCommonLogging DLL..
[echo]
[exec] IKVM.NET <http://ikvm.net/> Compiler version 8.1.5717.0
[exec] Copyright (C) 2002-2015 Jeroen Frijters
[exec] http://www.ikvm.net/
[exec]
[exec] fatal error IKVMC5045: Link error: Method "cli.Common.Logging.
LogManager.GetLogger(Ljava.lang.String;)Lcli.Common.Logging.ILog;" has a
return type "cli.Common.Logging.ILog, Common.Logging.Core, Version=3.3.1.0,
Culture=neutral, PublicKeyToken=af08829b84f0328e"
instead of type "cli.Common.Logging.ILog, Common.Logging.Core,
Version=3.3.1.0, Culture=neutral, PublicKeyToken=af08829b84f0328e" as
expected by "com.plutext.slf4jNetCommonsLogging.NetCommonsLoggerFactory"
Notice the return types look identical.
I also get this same error if I use the net35 /Common.Logging packages
(from nuget) and let ikvmc use its default mscorlib:
<arg
value="-reference:lib/dotNET/packages/Common.Logging.3.3.1/lib/net35/Common.Logging.dll"
/>
<arg value="-reference:lib/dotNET/packages/Common.Logging.Core.
3.3.1/lib/net35/Common.Logging.Core.dll" />
Thoughts?
For now, I've reverted to compiling against Common.Logging 2.1.2 which is
what I had before and which works.
thanks .. Jason