Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/.net/21.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java IKVM.NET:在mscorelib版本问题上IKVMTUB阻塞_Java_.net_Ikvm_Mscorlib - Fatal编程技术网

Java IKVM.NET:在mscorelib版本问题上IKVMTUB阻塞

Java IKVM.NET:在mscorelib版本问题上IKVMTUB阻塞,java,.net,ikvm,mscorlib,Java,.net,Ikvm,Mscorlib,我在谷歌上找到了不少关于这个问题的答案,但找不到解决办法 当我尝试使用ikvmstub.exe将.NET接口转换为Java存根时,出现以下错误: C:\public\ikvm-0.44.0.5\bin\ikvmstub.exe NET_Interface.dll Error: unable to load assembly 'NET_Interface.dll' as it depends on a higher ver sion of mscorlib than the one current

我在谷歌上找到了不少关于这个问题的答案,但找不到解决办法

当我尝试使用
ikvmstub.exe
将.NET接口转换为Java存根时,出现以下错误:

C:\public\ikvm-0.44.0.5\bin\ikvmstub.exe NET_Interface.dll
Error: unable to load assembly 'NET_Interface.dll' as it depends on a higher ver
sion of mscorlib than the one currently loaded
NET\u Interface.dll
取决于框架版本4。此版本已安装在我的计算机上

我如何解决这个问题


谢谢您的时间。

有两种方法可以解决这个问题:

1) 创建一个ikvmstub.exe.config文件,强制ikvmstub.exe在.NET 4.0上运行

2) 明确指定要使用的mscorlib版本: \ikvm\bin\ikvmstub-nostdlib-r:\windows\microsoft.net\framework\v4.0.30319\mscorlib.dll net\u Interface.dll


请注意,当您想使用ikvmc进行编译时,您需要执行相同的操作(两个选项中的任何一个)。

感谢您注册,以回答此问题!IKVM规则!:)