Cross-platform compile?

Dec 10, 2011 at 10:54 PM

We're using SuperWebSocket on Windows, but would like to use it on Mono as well. The recent changes require compiling it separately for that platform. Is it possible to modify the projects so that they can be compiled once and run on both platforms? It is fairly straightforward to determine at run-time whether one is running on Mono or the CLR for the few places (one?) that the difference matters in code. 

Dec 11, 2011 at 5:26 AM

Because there some lines code are not compatible, so I separated them for SuperSocket.

I'll do more research about it to find whether there is a way to improve it.

Dec 11, 2011 at 10:26 AM

Your requirement is fair.

But the log4net.dll cannot be used in Mono directly, because it contains some code platform specific.

So I use the a modified version of log4net provided by a man in internet for Mono.

I am not sure whether I should always use the modified version of log4net for .NET and Mono.

Dec 12, 2011 at 5:35 AM

The log4net people say they have a DLL which can run on both Mono and the CLR. See http://logging.apache.org/log4net/release/framework-support.html. It might make sense to compile against this neutral version ("CLI 1.0 Compatible") but let users know that they can replace the actual log4net.dll distributed with SuperWebSocket/SuperSocket with a platform-specific one if they must use a platform-specific logging functionality. They are likely to have their own logging preferences and versions in any case.

Dec 12, 2011 at 5:41 AM

Yes, the CLI 1.0. But I have never test against it.

I'll think about using it in SuperSocket and SuperWebSocket.

Recently, log4net released 1.2.12. It's time to upgrade now.

Dec 13, 2011 at 4:17 PM

Hi, I have improved SuperSocket and SuperWebSocket, you can use .NET 4.0 assemblies on Mono of Linux now.

Please get latest code from SVN.

Dec 14, 2011 at 4:15 AM

This is great news! I'll be able to take a look at it next week.