[Mono-devel-list] [PATCH] Fix for runtime version selection and improved assembly remapping

Lluis Sanchez lluis at ximian.com
Fri Feb 11 11:35:38 EST 2005

Sorry, forgot the attachment.

On dv, 2005-02-11 at 17:12 +0100, Lluis Sanchez wrote:
> Hi!
> This patch fixes two issues. First of all, it fixes the bug #62913,
> which is about selecting the correct runtime for an executable.
> Right now, an executable compiled with .NET 2.0 or gmcs will try to run
> using the mono 2.0 framework, even if this framework is not installed,
> in which case it will crash. With the patch, mono checks that the
> mscorlib for the requested framework version exists. If it does not, it
> will fall-back to the next supported framework. This means that an
> application with the following .config file:
> <configuration>
> 	<startup>
> 		<supportedRuntime version="v2.0.40607"/>
> 		<supportedRuntime version="v1.1.4322"/>
> 	</startup>
> </configuration>
> will properly fall-back to v1.1.4322 if v2.0.40607 is not installed.
> The other issue that the patch fixes is related again to assembly
> version remapping. It turns out that some assemblies which do not use
> the same version numbers as mscorlib also need to be in sync with the
> runtime. Those assemblies are Microsoft.VisualBasic and
> Microsoft.VisualC. This is specially a problem for
> Microsoft.VisualBasic, since all assemblies compiled with VB will
> reference it.
> With the patch, we have several system assembly version sets for each
> runtime version, not just one. Then, each system assembly is linked to a
> specific version set, which is used for remapping.
> Another change I've made is to allow version remapping even if the
> assembly being loaded is newer than the selected system assembly. Paolo
> suggested not to remap in this case, but not doing it has some issues.
> For example, an application compiled with gmcs will contain references
> to 2.0 assemblies, and it will fail when trying to run in a system that
> does not have the 2.0 assemblies installed. If we remap to 1.1, it has
> at least a chance to run.
> Comments are welcome!
> Lluis.
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tmp.diff
Type: text/x-patch
Size: 15266 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20050211/9b908bc9/attachment.bin 

More information about the Mono-devel-list mailing list