In case any one is interested, the problem is that the contrib sources usually use a bunch of weird storage class types for their classes. For example, the plot contrib source uses the ‘WXDLLIMPEXP_PLOT’ like so:
class WXDLLIMPEXP_PLOT wxPlotEvent;
These storage class types are supposed to resolve to nothing, __declspec( dllimport ), or__declspec( dllexport ) depending on the defines that are used in your project. To get the source to compile with a stand alone project, they need to resolve to nothing. However, an unfortunate side effect of the WXUSINGDLL define that is used with the “using wxWidgets dll” templates is to make them resolve to __declspec( dllimport ).
So far, the only way around this is to manually edit the source files. Near the beginning there is usually a set of macros like this
#ifdef WXMAKINGDLL_PLOT
#define WXDLLIMPEXP_PLOT WXEXPORT
#define WXDLLIMPEXP_DATA_PLOT(type) WXEXPORT type
#elif defined(WXUSINGDLL)
#define WXDLLIMPEXP_PLOT WXIMPORT
#define WXDLLIMPEXP_DATA_PLOT(type) WXIMPORT type
#else // not making nor using DLL
#define WXDLLIMPEXP_PLOT
#define WXDLLIMPEXP_DATA_PLOT(type) type
#endif
that begin the process of resolving the storage class types to what they are supposed to be. To make them resolve to nothing when WXUSINGDLL is used, the macros can be changed to something like this:
#ifdef WXMAKINGDLL_PLOT
#define WXDLLIMPEXP_PLOT WXEXPORT
#define WXDLLIMPEXP_DATA_PLOT(type) WXEXPORT type
#elif defined(WXUSINGDLL) && !defined(ADHOCDEFINE77)
#define WXDLLIMPEXP_PLOT WXIMPORT
#define WXDLLIMPEXP_DATA_PLOT(type) WXIMPORT type
#else // not making nor using DLL
#define WXDLLIMPEXP_PLOT
#define WXDLLIMPEXP_DATA_PLOT(type) type
#endif
Then add ADHOCDEFINE77 to the compiler defines under Project->Build Options->Compiler->#defines.