I need to reference a specific version of a signed assembly. Because it is present in GAC, compiler picks up the 'vendor' version instead of the one I provide (the GAC version number is higher, even though it's an older API). Is there some kind of extension to the basic /reference=Library.dll
compiler option that allows specyfing a strong name?
I'm compiling with NAnt, so <csc>
task-based solution would be optimal, but compiler command line (csc AND mcs) is also fine.
I found a NAnt-specific workaround. In <references>
part of <csc>
task, specify individual <include>
elements for assemblies using directory path, so that it won't match assemblies in GAC. So the same will work with the compilers, when one specifies the full path to the assembly. It's not exactly what I had in mind, but it works.