Hello, I'm working on an open source project (Logbus-ng), and I need to implement a web service spawned by a console application in a way that works both on Windows and Mono.
Currently, thanks to the tutorial by MSDN Magazine, I succeeded in doing this on Windows. A console application can spawn its own web server and actually open a web service interface to the external. The problem is that this doesn't work in Mono, reasonably because of a Mono bug.
Chatting with Mono developers, they suggested me to use the Mono.XSP assembly to enable the ASP.NET pipeline into console applications, so I think I'll use different implementations of the web service activator depending on the configuration.
Now my question is: since Mono.XSP is available in GAC in all Mono distributions (ie. when using xbuild under Linux) but is not available in Windows unless someone installs it into the GAC, and I don't want to ship Mono.XSP with my software, neither force someone to install Mono if they don't need it (ie. if compiling under Windows), can I set a reference to Mono.XSP assembly in GAC that is enabled only if the MONO compilation flag is enabled? When this flag is enabled, my code will obviously be referencing Mono.XSP instead of HttpListenLibrary covered in the tutorial linked above, and the reference will be used by the compiler correctly.
Thank you in advance.