Commit 9c3506e6 authored by Utkarsh Ayachit's avatar Utkarsh Ayachit

BUG: When people had CMakeLists.txt files making multiple calls to

ADD_PARAVIEW_PLUGIN macro, due to variable scoping, the state from previous call
leaked into the next call. Fixed that by changing ADD_PARAVIEW_PLUGIN to be a
function instead of a macro.
parent 733c6798
......@@ -860,7 +860,7 @@ ENDMACRO(PARAVIEW_QT4_ADD_RESOURCES)
# [REQUIRED_ON_CLIENT]
# [REQUIRED_PLUGINS pluginname1 pluginname2]
# )
MACRO(ADD_PARAVIEW_PLUGIN NAME VERSION)
FUNCTION(ADD_PARAVIEW_PLUGIN NAME VERSION)
SET(QT_RCS)
SET(GUI_SRCS)
SET(SM_SRCS)
......@@ -882,6 +882,7 @@ MACRO(ADD_PARAVIEW_PLUGIN NAME VERSION)
SET(PLUGIN_REQUIRED_ON_CLIENT 1)
SET(PLUGIN_REQUIRED_PLUGINS)
SET(HAVE_REQUIRED_PLUGINS 0)
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR})
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR})
......@@ -998,7 +999,7 @@ MACRO(ADD_PARAVIEW_PLUGIN NAME VERSION)
ENDIF(GUI_SRCS OR SM_SRCS OR ARG_SOURCES OR ARG_PYTHON_MODULES)
ENDMACRO(ADD_PARAVIEW_PLUGIN)
ENDFUNCTION(ADD_PARAVIEW_PLUGIN)
# wrap a Plugin into Python so that it can be called from pvclient and pvbatch
#it will produce lib${NAME}Python.so, which you can then
......
......@@ -33,18 +33,27 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "vtkObjectFactory.h"
#ifdef INITIALIZE_WRAPPING
# include "vtkProcessModule.h"
# include "vtkClientServerInterpreter.h"
//-----------------------------------------------------------------------------
#ifdef plugin_type_servermanager
# ifdef INITIALIZE_WRAPPING
# include "vtkProcessModule.h"
# include "vtkClientServerInterpreter.h"
extern "C" void @PLUGIN_NAME@_Initialize(vtkClientServerInterpreter *arlu);
# endif
#endif
//-----------------------------------------------------------------------------
#ifdef plugin_type_servermanager
@SM_PLUGIN_INCLUDES@
@INTERFACE_INCLUDES@
@PUSH_BACK_XML_INTERFACES@
#endif
//-----------------------------------------------------------------------------
#ifdef plugin_type_gui
@PUSH_BACK_PV_INTERFACES@
@INTERFACE_INCLUDES@
#endif
//-----------------------------------------------------------------------------
#ifdef plugin_type_servermanager
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment