Salome HOME
492d3c0b16b957032089f8c351e02130c080dbd0
[modules/paravis.git] / src / Plugins / TableReader / ParaViewPlugin / CMakeLists.txt
1 # Copyright (C) 2010-2016  CEA/DEN, EDF R&D
2 #
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
7 #
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 # Lesser General Public License for more details.
12 #
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 #
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 #
19
20 IF(PARAVIEW_BUILD_QT_GUI)
21    
22     INCLUDE(UseQtExt)
23     # Custom object panel for the reader and 
24     # custom display panel for line chart view
25     QT_WRAP_UIC(CLIENT_UI_SRCS
26         Resources/UI/TableReaderPanel.ui
27         Resources/UI/CustomXYChartDisplayPanel.ui
28     )
29
30     QT_WRAP_MOC(MOC_SRCS 
31         pqTableReaderPanel.h
32         pqTableTo3DPanel.h
33         pqCustomChartDisplayPanelImplementation.h
34         pqCustomXYChartDisplayPanel.h
35         pqCustomPlotSettingsModel.h
36     )
37         
38      SET(CLIENT_SRCS
39         pqTableReaderPanel.cxx
40         pqTableTo3DPanel.cxx
41         pqCustomChartDisplayPanelImplementation.cxx
42         pqCustomXYChartDisplayPanel.cxx
43         pqCustomPlotSettingsModel.cxx
44     )   
45
46     ADD_PARAVIEW_OBJECT_PANEL(
47         TABLEREADER_IFACES TABLEREADER_IFACE_SRCS 
48         CLASS_NAME pqTableReaderPanel
49         XML_NAME TableReader 
50         XML_GROUP sources)
51     
52     ADD_PARAVIEW_OBJECT_PANEL(
53         TABLETO3D_IFACES TABLETO3D_IFACE_SRCS 
54         CLASS_NAME pqTableTo3DPanel
55         XML_NAME TableTo3D 
56         XML_GROUP filters)
57
58     # define the server-side and the client-side parts
59     # of the table reader plugin
60     ADD_PARAVIEW_PLUGIN(TableReaderPlugin "1.0"
61         SOURCES ../Reader/TableParser.cxx
62         SERVER_MANAGER_SOURCES ../Reader/vtkVisuTableReader.cxx ../TableTo3DFilter/vtkTableTo3D.cxx
63         SERVER_MANAGER_XML Resources/TableReaderServer.xml Resources/TableTo3DServer.xml
64         GUI_INTERFACES ${TABLEREADER_IFACES} ${TABLETO3D_IFACES} pqCustomChartDisplayPanel
65         GUI_SOURCES ${CLIENT_SRCS} 
66             ${CLIENT_UI_SRCS} 
67             ${TABLEREADER_IFACE_SRCS} 
68             ${TABLETO3D_IFACE_SRCS}
69             ${MOC_SRCS}
70         GUI_RESOURCES Resources/TableReader.qrc Resources/TableTo3D.qrc)
71       
72 ELSE(PARAVIEW_BUILD_QT_GUI)
73
74     # define the server-side part of the table reader plugin
75     ADD_PARAVIEW_PLUGIN(TableReaderPlugin "1.0" 
76       SOURCES TableParser.cxx
77       SERVER_MANAGER_SOURCES vtkVisuTableReader.cxx vtkTableTo3D.cxx
78       SERVER_MANAGER_XML Resources/TableReaderServer.xml Resources/TableTo3DServer.xml)
79
80 ENDIF(PARAVIEW_BUILD_QT_GUI)
81
82 TARGET_LINK_LIBRARIES(TableReaderPlugin vtkVisuTableReader vtkTableTo3D)
83
84 # Install
85 INSTALL(
86     TARGETS TableReaderPlugin
87     RUNTIME DESTINATION lib/paraview
88     LIBRARY DESTINATION lib/paraview
89     ARCHIVE DESTINATION lib/paraview
90 )