All dependencies used in a monoproject must be compiled using mono

Let's say I started a C # project under Windows (Visual Studio 2008), and I want to switch to Mono. Do I need to recompile all the dependencies that my project uses, for example, NHibernate and each individual external dependency?

Note 1: The reason I asked this question is because I built a project with MonoDevelop on Ubuntu 9.10 and everything went like a charm, but when I tried to debug the start of some tests written using NUnit, everything just froze. I need to cancel the current test in order to get a backup of MonoDevelop, and there is no clear stack trace or tooltip that I could use to find the problem. Therefore, although, perhaps, I will need to compile NHibernate (and other dependencies) on Mono / Linux.

+3
source share
3 answers

No, you do not need to recompile the DLLs that you reference in code compiled using Mono compilers.

, Mono, Microsoft.NET, DLL , Mono, .

Mono migration, DLL, , - , Mono.

, DLL, Mono, , Microsoft.

+6

Windows? FAQ .

, mono , .

+2

, .

As an example, I recently needed to use Mono.Cecil.dll to avoid some of the reflection pain from AppDomain that I was experiencing and was able to capture the latest version created by the Mono compiler and it ran on my .NET. 3.5 no problem.

Of course, if you plan to run on Linux or something other than Windows, you should rely on the fact that these assemblies are correctly written, so use Environment.NewLine, Path.Combine, etc. instead of Windows specific code.

+1
source

Source: https://habr.com/ru/post/1722637/


All Articles