Stephen Howe
2009-12-15 20:02:54 UTC
Hi
Using VS2005 Professional
I have bog-standard Win32 DLL, and it has an export header file like so
#ifdef MOD_EXPORTS
#define MOD_API __declspec(dllexport)
#else
#define MOD_API __declspec(dllimport)
#endif
class MOD_API CObj1
{
private:
CObj2 m_Obj2;
};
Now CObj2 resides in a proper library file (not an import library but a real library)
Both the Win32 DLL and the proper library use the RTL in DLL form yet I am getting
warning C4251: 'CObj1::m_Obj2 : class 'CObj2' needs to have dll-interface to be used by clients of class 'CObj1'
How do I eliminate this warning correctly (I dont mean shut the compiler up with a pragma, but I do if the warning is spurious)?
For that matter, how do I give CObj2 a DLL interface?
Thanks
Stephen Howe
Using VS2005 Professional
I have bog-standard Win32 DLL, and it has an export header file like so
#ifdef MOD_EXPORTS
#define MOD_API __declspec(dllexport)
#else
#define MOD_API __declspec(dllimport)
#endif
class MOD_API CObj1
{
private:
CObj2 m_Obj2;
};
Now CObj2 resides in a proper library file (not an import library but a real library)
Both the Win32 DLL and the proper library use the RTL in DLL form yet I am getting
warning C4251: 'CObj1::m_Obj2 : class 'CObj2' needs to have dll-interface to be used by clients of class 'CObj1'
How do I eliminate this warning correctly (I dont mean shut the compiler up with a pragma, but I do if the warning is spurious)?
For that matter, how do I give CObj2 a DLL interface?
Thanks
Stephen Howe