Primary Output brings with it all referenced components, but I dont want them..

cjard

Well-known member
Joined
Apr 25, 2006
Messages
7,081
Programming Experience
10+
I have a project that generates a DLL. The DLL is a plugin and is intended to be used only within a certain app.

This app accesses database tables and other things, and provides these for use to any plugin DLLs.

Necessarily, the plugin DLL must reference the main app's project, because all plugins must derive from MainApp.PluginBase class to be considered a plugin. Also because plugins access MainApp.CoreServices.DBPrefs, and this is implemented by the AppsPrefs project, the plugin must have a reference to AppsPrefs

The solution looks like:
VB.NET:
Solution
+-MainApp (Project)
+-AppsPrefs (Project)
+-AppsLogs (Profect)
+-MyPlugin1
  +-References
[B]    +-MainApp (ref)[/B]
[B]    +-AppsPrefs (ref)[/B]
[B]    +-AppsLogs (ref)[/B]
+-MyPlugin2
+-SetupMainApp
+-SetupMyPlugin1
+-SetupMyPlugin2

What this adds up to is that I can set CopyLocal = false to all the items in bold and the DLLs/EXEs generated dont appear when debugging or releasing..

But when I make a deployment project that merely has the Primary Output of MyPlugin1, I find that it puts MainApp.exe, AppsPrefs.DLL and AppsLogs.DLL in the plugin distribution as well.. I dont want them in there because they are polluting the plugins folder.

How can I build a setup that includes the output of the plugin project, but not the referenced components (because they will already exist and be loaded by the time the plugin comes to need them, the plugin wont need its own copy, which it never uses)
 
Set the Exclude property to true for each of these entries in SetupMyplugin1\FileSystemView\ApplicationFolder
 
Back
Top