简体   繁体   English

Ubuntu上的Mono,Visual Studio DLL问题

[英]Mono on Ubuntu, Issue with Visual Studio DLLs

I'm not sure if my description is the best. 我不确定我的描述是否最好。

I have a project built with VS2012/13 on Windows/.NET which I've brought over to an Ubuntu box running Mono (the latest version). 我有一个在Windows / .NET上使用VS2012 / 13构建的项目,已将其带到运行Mono(最新版本)的Ubuntu盒中。

I'm getting this error, and I'm not sure what it's telling me, or how to fix it: 我收到此错误,并且不确定它告诉我什么或如何解决:

Missing method System.Web.Http.HttpResponseException::.ctor(HttpStatusCode) in assembly /usr/local/lib/mono/gac/System.Web.Http/4.0.0.0__31bf3856ad364e35/System.Web.Http.dll, referenced in assembly /home/ubuntu/node-servers/NodeProcessorHost/native/BatchEmailSend/Profiles.Client.dll 在程序集/usr/local/lib/mono/gac/System.Web.Http/4.0.0.0__31bf3856ad364e35/System.Web.Http.dll中缺少方法System.Web.Http.HttpResponseException ::。ctor(HttpStatusCode)程序集/home/ubuntu/node-servers/NodeProcessorHost/native/BatchEmailSend/Profiles.Client.dll

Note that this is running via EdgeJS (hence the Node references), but that it runs fine on Windows/EdgeJS. 请注意,这是通过EdgeJS运行的(因此有Node引用),但是在Windows / EdgeJS上运行良好。

So, it's two questions really: 因此,确实有两个问题:

  • What is the root cause of this message? 此消息的根本原因是什么?
  • How do I fix it? 我如何解决它?

Be careful of differences in System assemblies between platforms. 注意平台之间的系统组装之间的差异。 Messages about vacant constructors (ctor) maybe an indication of an improper or missing assembly. 有关空的构造函数(ctor)的消息可能表示组装不正确或丢失。 One way to ensure your assemblies are found is to set the MONO_PATH to include their location. 确保找到程序集的一种方法是将MONO_PATH设置为包括其位置。

In this situation, that worked for me. 在这种情况下,这对我有用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM