#ifdef WIN32 # define DYN_EXPORTS # ifdef DYN_EXPORTS # define DYN_EXPORT __declspec(dllexport) # else # define DYN_EXPORT __declspec(dllimport) # endif #else # define DYN_EXPORT #endif extern "C" DYN_EXPORT void func1(); extern "C" DYN_EXPORT void func2(); extern "C" DYN_EXPORT void func2_1(); extern "C" DYN_EXPORT void func3(); class DYN_EXPORT A { public: void method1(); void method2(); void method2_1(); void method3(); };