[Mono-list] Compiling library references with hardcoded paths?

Francisco Figueiredo Jr. fxjrlists@yahoo.com.br
Sun, 25 Apr 2004 16:28:31 -0300

Karl Bowden wrote:
> If I compile an app with a reference to say gnome-sharp.dll but I 
> reference it with the full path, will that app then look for that full 
> path first when loading that app?

Hi Karl.

Nope. The references are used by compiler to get managed information 
about the types, metadata and code being used in the assembly.
The information about referenced assemblies kept in your app will be 
only the assembly name (eg gnome-sharp) and its version information (Of 
course this info is over simplified as may have some other info about 
your assemblies in your code.)

When running your app, while mono runtime loads your app, and sees you 
are using a given assembly, it will try to load that assembly using the 
standard assembly location algorithms (eg, from paths in MONO_PATH or in 
your MonoInstall/lib dir). So, in no way it will use any previously 
hardcoded path for your assembly.

I hope it helps.


Francisco Figueiredo Jr.
Membro Fundador do Projeto MonoBrasil - MonoBrasil Project Founder Member

"Science without religion is lame;
religion without science is blind."

                   ~ Albert Einstein