Page 1 of 1

Plugins by Mono

Posted: Mon Jan 26, 2015 3:48 pm
by Sergey_Babakov
Hello! My name Sergey Babakov I am engineer from M.Kartsev scientific research institute for computer complexes inc. (NIIVK), Moscow, Russia. I have some questions about using Virtual Radar Server with Linux.
I have written my plugin in Microsoft Visual Studio 2013. Plugin connects to MySQL server database and writes data in some database table. I use Entity Data Model classes for database accessing. Entity Framework version is 3.5. In Windows plugin works greate. Now I would like to adapt my plugin by Linux and Mono. Will Entity Framework 3.5 work on Linux? I have got the latest version of Mono. Can I use dll, which was built on Visual Studio? Or I need to rebuild it by Mono?
Thank you for answers. Sergey Babakov

Re: Plugins by Mono

Posted: Tue Jan 27, 2015 12:50 am
by agw
I'd actually answered this one when the exact same text arrived as an email :) But for others who might be after the same information the answers are:

1) No idea if Entity Framework runs under Mono. He'll need to try it and see.

2) You shouldn't need to recompile your plugin to run on Mono, just ship the Windows-built DLLs. If a plugin needs to do something different when it's running under Mono then VRS offers a mechanism for finding out if you're running under Mono:

Code: Select all

var isMono = Factory.Singleton.Resolve<IRuntimeEnvironment>().Singleton.IsMono;
if(isMono) {
    // Do whatever needs to be done when running under Mono
} else {
    // Do whatever needs to be done when running under .NET
}