0032315: Configuration, CMake - fix building Draw Harness plugins as static libraries
[occt.git] / src / Draw / Draw_PluginMacro.hxx
index 4c7d77e..badfb8e 100644 (file)
 #ifndef _Draw_PluginMacro_HeaderFile
 #define _Draw_PluginMacro_HeaderFile
 
+#ifdef OCCT_NO_PLUGINS
+#define DPLUGIN(name)
+#else
 #define DPLUGIN(name) \
-extern "C" {Standard_EXPORT void PLUGINFACTORY(Draw_Interpretor&);} \
-void  PLUGINFACTORY(Draw_Interpretor& theDI) { \
-        name::Factory(theDI);} \
-\
+extern "C" Standard_EXPORT void PLUGINFACTORY(Draw_Interpretor& theDI) { \
+  name::Factory(theDI); \
+}
+#endif
 
 #endif