[Mono-list] mcs using System.Remoting.dll on XP

Miguel de Icaza miguel@ximian.com
01 May 2002 18:21:35 -0400


> Thanks for the info Miguel!  Please direct me to any docs that would help
> clarify my general questions.  I have some more questions below if anyone has
> time to answer them.  

Well, we should really be updating the FAQ as we speak. 

For example, I am not sure that shipping mcs.bat is a good idea, maybe
we should have a monomcs.bat file that can be used to run the Mono C#
compiler with the mono runtime on Windows for now.

At least until we are at a more avanced stage, because it is hard to
debug things the way things are right now. 

> the mcs i was using was (you're right) the mcs.bat file from the windows
> binaries Johannes Roth made available last week.  
> 
> let me make sure i understand what you are saying.  is the native .NET
> execuatble you are talking about monomcs.exe?  does monomcs.exe not use the
> mono runtime?  also, i thought mono had implemented the
> System.Runtime.Remoting.dll but I don't see it in the "private GAC" you
> mentioned below.  when i use monomcs with the following options : 

`monomcs.exe' (which we call mcs.exe) loads assemblies from the
"runtime" system directory.  If your runtime is .NET it will be
something like c:\winnt\microsoft.net\v1.3705\bin.  If the runtime is
Mono, it will be your prefix directory plus the "lib" directory.

The reason is that the compiler is loading assemblies from the same
directory that the "mscorlib/corlib" assembly comes from.  

> monomcs --target ... -r System.Runtime.Remoting -r ChatServerLib.dll(local
> monomcs compiled dll,) it seems to access the MS GAC...(the simple chat server
> compiled.)  is that what is expected?

Yep.

> so, i've got a compiled chat server exe that seems to start up properly using
> the MS runtime, but not the mono runtime(can't access
> System.Runtime.Remoting.dll at runtime.)  so i'm not sure if that actually
> means it's working properly referencing some monomcs dlls and some MS dlls ??

We do not have a System.Runtime.Remoting DLL yet.  The Mono runtime
probably is failing because it can not locate the assembly.

If the System.Runtime.Remoting DLL is fully managed code and does not
make any internal calls into the runtime, you could copy this to the
directory where Mono looks for its assemblies and run it.  But Remoting
might be one of those things that use a lot of internal calls.  I am not
sure. 

> one other thing...monomcs produces IL that places the delegates outside the
> namespace they were declared in, the opposite of what microsoft does.  (both
> were declared inside the namespace in the code)

Can you provide us with a sample case, and a bug report? 
http://bugzilla.ximian.com

Miguel