I have a third party application that I am providing plugins for. The app provides some WPF DLLs that i can use to build my plugin GUI on, so my GUI depends on both WPF and these app DLLs. I also have a separate C++ DLL that does the processing and initializes the plugin /including the GUI). this creates dependent references like this:
MyGui.dll (C# / WPF)
- foreign exe WPF-DLLs
- some .NET DLLs
- system DLLs
MyPlugin.dll (C++ / CLR)
- MyGui.dll
- foreign exe WPF-DLLs
- some .NET DLLs
The deployment works on most machines, but on some the plugin causes undefined behaviour, up to and including crashing the application.
I did some analysis, mainly comparing to plugins that work, and found that another plugin specifically sets the CopyLocal flag to true. However, this isn't necessary on my machine, and I'm not sure what the effect of this setting is on my machine, or on deployed machines.
Here are my questions, all regarding deployment only (I am aware that you may come up with different answers when only looking at the dev machine):
C++ references:
1. When do I need to set the flag "Copy Local"?
2. When do I need to set the flag "Copy Local Satellite Assemblies"?
C# references:
3. When do I need to set the flag "Copy Local"?
4. When/how do I need to set the flag "Specific version"?
All with reference to the dependencies outlined above.
What I have tried:
I got some helpful information here
.net - When should copy-local be set to true and when should it not? - Stack Overflow[
^] But since I am only beginner level regarding .net, I have some trouble understanding the information provided there (e. g. what does GAC mean, and how can I find out what is in it)
Update:
I've found an explanation on GAC on Wikipedia and a few more insightful bits of information. I do understand the descriptions insofar as the flags are used on the devs machine. But that is not my question!
Setting these flags or not clearly have an effect on deployment! This is what makes my plugin fail or run on some machines it's deployed to! However, I still haven't found the slightest bit of information how these flags affect deployed assemblies.
Maybe this effect on deployment is a side effect not originally intended to be triggered by these flags. If so, it might be worth a bug report, although I have no idea what, exactly, is causing the problem, or how to reproduce the issue.