Ant: Re: [Gtk-sharp-list] gtk-sharp.dll not working on linux because it references win32 dll's

Todd Berman tberman at off.net
Thu Jul 21 15:27:12 EDT 2005


On Thu, 2005-07-21 at 21:19 +0200, Jost Boekemeier wrote:
> Hi,
> 
> [I don't agree with your points, but I feel that this
> discussion goes nowhere...]
> 

Agreed.

> > We actually chose a proactive method of identifying
> > all possible
> > assemblies in the GAC from pc files
> 
> Loading directly from the GAC should be possible.  But
> this doesn't tell me which one is the "default" one,
> whatever "default" may mean (one could select any
> version, but the choice must be consistent for all
> applications).
> 


dude, it IS possible.

The issue you dont seem to understand is that there is no "default"
version.

There are multiple versions possibly, all of which are just as "default"
as any of the others. If you want the newest version, that is different,
but that is not the "default".

All applications that build against a library in the GAC include in
their metadata exactly the information required to match the strong name
of the assembly.

If you look at the output of "monodis --assemblyref
some-gtk-sharp-app.exe" you will see stuff like:

8: Version=2.6.0.0
        Name=gtk-sharp
        Public Key: 0x00000000: 35 E1 01 95 DA B3 C9 9F


That tells mono that this copy of MonoDevelop was built against
gtk-sharp version 2.6.0.0 and gives the public key. This is exactly the
information required to load that version of gtk# on any computer, and
fail if that computer does not have it, so that the application runs
properly.

It is not like mono sees the gtk# reference, and looks in the gac, sees
three versions and decides 'Hell, today, for fun, lets randomly load
1.2.0.0 instead of the other 2'. It loads exactly what the application
was built against (with the exception of publisher policies, but that is
beyond the scope of this discussion).

I hope this helps to clear up some of the misunderstandings you are
having.

--Todd



More information about the Gtk-sharp-list mailing list