Salome HOME
Implement table of rules.
[modules/hydro.git] / src / HYDROGUI / CMakeLists.txt
1 #include(../../CMake/Common.cmake)
2 include(../../CMake/UseQT4EXT.cmake)
3
4 set(PROJECT_HEADERS 
5     HYDROGUI.h
6     HYDROGUI_AbstractDisplayer.h
7     HYDROGUI_AISTrihedron.h
8     HYDROGUI_BathymetryPrs.h
9     HYDROGUI_CalculationDlg.h
10     HYDROGUI_CalculationOp.h
11     HYDROGUI_ChannelDlg.h
12     HYDROGUI_ChannelOp.h
13     HYDROGUI_ColorWidget.h
14     HYDROGUI_CopyPasteOp.h
15     HYDROGUI_CopyPastePositionOp.h
16     HYDROGUI_CurveCreatorProfile.h
17     HYDROGUI_DataBrowser.h
18     HYDROGUI_DataModel.h
19     HYDROGUI_DataModelSync.h
20     HYDROGUI_DataObject.h
21     HYDROGUI_DeleteDlg.h
22     HYDROGUI_DeleteOp.h
23     HYDROGUI_DigueDlg.h
24     HYDROGUI_DigueOp.h
25     HYDROGUI_Displayer.h
26     HYDROGUI_ExportImageOp.h
27     HYDROGUI_GVSelector.h
28     HYDROGUI_ImmersibleZoneDlg.h
29     HYDROGUI_ImmersibleZoneOp.h
30     HYDROGUI_ImportBathymetryDlg.h
31     HYDROGUI_ImportBathymetryOp.h
32     HYDROGUI_ImportImageDlg.h
33     HYDROGUI_ImportImageOp.h
34     HYDROGUI_InputPanel.h
35     HYDROGUI_LocalCSDlg.h
36     HYDROGUI_LocalCSOp.h
37     HYDROGUI_Module.h
38     HYDROGUI_NameValidator.h
39     HYDROGUI_ObjSelector.h
40     HYDROGUI_ObserveImageOp.h
41     HYDROGUI_OCCDisplayer.h
42     HYDROGUI_OCCSelector.h
43     HYDROGUI_Operation.h
44     HYDROGUI_Operations.h
45     HYDROGUI_Poly3DDlg.h
46     HYDROGUI_Poly3DOp.h
47     HYDROGUI_PolylineDlg.h
48     HYDROGUI_PolylineOp.h
49     HYDROGUI_ProfileDlg.h
50     HYDROGUI_ProfileOp.h
51     HYDROGUI_Prs.h
52     HYDROGUI_PrsDriver.h
53     HYDROGUI_PrsImage.h
54     HYDROGUI_PrsImageDriver.h
55     HYDROGUI_PrsImageFrame.h
56     HYDROGUI_PrsPolyline.h
57     HYDROGUI_PrsPolylineDriver.h
58     HYDROGUI_PrsZone.h
59     HYDROGUI_PrsZoneDriver.h
60     HYDROGUI_Region.h
61     HYDROGUI_RemoveImageRefsOp.h
62     HYDROGUI_Shape.h
63     HYDROGUI_ShapeBathymetry.h
64     HYDROGUI_ShapeImage.h
65     HYDROGUI_ShowHideOp.h
66     HYDROGUI_StreamDlg.h
67     HYDROGUI_StreamOp.h
68     HYDROGUI_Tool.h
69     HYDROGUI_TwoImagesDlg.h
70     HYDROGUI_TwoImagesOp.h
71     HYDROGUI_UpdateFlags.h
72     HYDROGUI_UpdateObjectOp.h
73     HYDROGUI_VisualStateOp.h
74     HYDROGUI_VTKPrs.h
75     HYDROGUI_VTKPrsBathymetry.h
76     HYDROGUI_VTKPrsBathymetryDriver.h
77     HYDROGUI_VTKPrsDisplayer.h
78     HYDROGUI_VTKPrsDriver.h
79     HYDROGUI_VTKPrsShape.h
80     HYDROGUI_VTKPrsShapeDriver.h
81     HYDROGUI_Wizard.h
82     HYDROGUI_Zone.h
83     HYDROGUI_ImportGeomObjectOp.h
84     HYDROGUI_ImportObstacleFromFileOp.h
85     HYDROGUI_ExportCalculationOp.h
86     HYDROGUI_GeomObjectDlg.h
87     HYDROGUI_SetColorOp.h
88     HYDROGUI_ColorDlg.h
89     HYDROGUI_ImportProfilesOp.h
90     HYDROGUI_GeoreferencementDlg.h
91     HYDROGUI_GeoreferencementOp.h
92     HYDROGUI_Actor.h
93     HYDROGUI_BathymetryBoundsOp.h
94     HYDROGUI_TranslateObstacleDlg.h
95     HYDROGUI_TranslateObstacleOp.h
96     HYDROGUI_ListModel.h
97     HYDROGUI_ZLevelsDlg.h
98     HYDROGUI_ZLevelsOp.h
99     HYDROGUI_OrderedListWidget.h
100     HYDROGUI_ListSelector.h
101     HYDROGUI_ZLayers.h
102     HYDROGUI_PriorityWidget.h
103         HYDROGUI_PriorityTableModel.h
104 )
105
106 QT4_WRAP_CPP(PROJECT_HEADERS_MOC ${PROJECT_HEADERS})
107
108 set(PROJECT_SOURCES 
109     HYDROGUI_AbstractDisplayer.cxx
110     HYDROGUI_AISTrihedron.cxx
111     HYDROGUI_BathymetryPrs.cxx
112     HYDROGUI_CalculationDlg.cxx
113     HYDROGUI_CalculationOp.cxx
114     HYDROGUI_ChannelDlg.cxx
115     HYDROGUI_ChannelOp.cxx
116     HYDROGUI_ColorWidget.cxx
117     HYDROGUI_CopyPasteOp.cxx
118     HYDROGUI_CopyPastePositionOp.cxx
119     HYDROGUI_CurveCreatorProfile.cxx
120     HYDROGUI_DataBrowser.cxx
121     HYDROGUI_DataModel.cxx
122     HYDROGUI_DataModelSync.cxx
123     HYDROGUI_DataObject.cxx
124     HYDROGUI_DeleteDlg.cxx
125     HYDROGUI_DeleteOp.cxx
126     HYDROGUI_DigueDlg.cxx
127     HYDROGUI_DigueOp.cxx
128     HYDROGUI_Displayer.cxx
129     HYDROGUI_ExportImageOp.cxx
130     HYDROGUI_GVSelector.cxx
131     HYDROGUI_ImmersibleZoneDlg.cxx
132     HYDROGUI_ImmersibleZoneOp.cxx
133     HYDROGUI_ImportBathymetryDlg.cxx
134     HYDROGUI_ImportBathymetryOp.cxx
135     HYDROGUI_ImportImageDlg.cxx
136     HYDROGUI_ImportImageOp.cxx
137     HYDROGUI_InputPanel.cxx
138     HYDROGUI_LocalCSDlg.cxx
139     HYDROGUI_LocalCSOp.cxx
140     HYDROGUI_Module.cxx
141     HYDROGUI_NameValidator.cxx
142     HYDROGUI_ObjSelector.cxx
143     HYDROGUI_ObserveImageOp.cxx
144     HYDROGUI_OCCDisplayer.cxx
145     HYDROGUI_OCCSelector.cxx
146     HYDROGUI_Operation.cxx
147     HYDROGUI_Operations.cxx
148     HYDROGUI_Poly3DDlg.cxx
149     HYDROGUI_Poly3DOp.cxx
150     HYDROGUI_PolylineDlg.cxx
151     HYDROGUI_PolylineOp.cxx
152     HYDROGUI_ProfileDlg.cxx
153     HYDROGUI_ProfileOp.cxx
154     HYDROGUI_Prs.cxx
155     HYDROGUI_PrsDriver.cxx
156     HYDROGUI_PrsImage.cxx
157     HYDROGUI_PrsImageDriver.cxx
158     HYDROGUI_PrsImageFrame.cxx
159     HYDROGUI_PrsPolyline.cxx
160     HYDROGUI_PrsPolylineDriver.cxx
161     HYDROGUI_PrsZone.cxx
162     HYDROGUI_PrsZoneDriver.cxx
163     HYDROGUI_Region.cxx
164     HYDROGUI_RemoveImageRefsOp.cxx
165     HYDROGUI_Shape.cxx
166     HYDROGUI_ShapeBathymetry.cxx
167     HYDROGUI_ShapeImage.cxx
168     HYDROGUI_ShowHideOp.cxx
169     HYDROGUI_StreamDlg.cxx
170     HYDROGUI_StreamOp.cxx
171     HYDROGUI_Tool.cxx
172     HYDROGUI_TwoImagesDlg.cxx
173     HYDROGUI_TwoImagesOp.cxx
174     HYDROGUI_UpdateObjectOp.cxx
175     HYDROGUI_VisualStateOp.cxx
176     HYDROGUI_VTKPrs.cxx
177     HYDROGUI_VTKPrsBathymetry.cxx
178     HYDROGUI_VTKPrsBathymetryDriver.cxx
179     HYDROGUI_VTKPrsDisplayer.cxx
180     HYDROGUI_VTKPrsDriver.cxx
181     HYDROGUI_VTKPrsShape.cxx
182     HYDROGUI_VTKPrsShapeDriver.cxx
183     HYDROGUI_Wizard.cxx
184     HYDROGUI_Zone.cxx
185     HYDROGUI_ImportGeomObjectOp.cxx
186     HYDROGUI_ImportObstacleFromFileOp.cxx
187     HYDROGUI_ExportCalculationOp.cxx
188     HYDROGUI_GeomObjectDlg.cxx
189     HYDROGUI_SetColorOp.cxx
190     HYDROGUI_ColorDlg.cxx
191     HYDROGUI_ImportProfilesOp.cxx
192     HYDROGUI_GeoreferencementDlg.cxx
193     HYDROGUI_GeoreferencementOp.cxx
194     HYDROGUI_Actor.cxx
195     HYDROGUI_BathymetryBoundsOp.cxx
196     HYDROGUI_TranslateObstacleDlg.cxx
197     HYDROGUI_TranslateObstacleOp.cxx
198     HYDROGUI_ListModel.cxx
199     HYDROGUI_ZLevelsDlg.cxx
200     HYDROGUI_ZLevelsOp.cxx
201     HYDROGUI_OrderedListWidget.cxx
202     HYDROGUI_ListSelector.cxx
203     HYDROGUI_ZLayers.cxx
204     HYDROGUI_ZLayers2.cxx
205     HYDROGUI_PriorityWidget.cxx
206         HYDROGUI_PriorityTableModel.cxx
207 )
208
209 add_definitions(
210   -DHYDROGUI_EXPORTS
211   ${CAS_DEFINITIONS}
212   ${OMNIORB_DEFINITIONS}
213   ${QT_DEFINITIONS}
214 #  $(GUI_CXXFLAGS)
215   ${GUI_DEFINITIONS}
216 #  $(GEOM_CXXFLAGS)
217   ${GEOM_DEFINITIONS}
218 )
219
220 include_directories(
221   ${CAS_INCLUDE_DIRS}
222   ${QT_INCLUDES}
223 #  ${GUI_ROOT_DIR}/include/salome
224   ${GUI_INCLUDE_DIRS}
225 #  ${GEOM_ROOT_DIR}/include/salome
226   ${GEOM_INCLUDE_DIRS}
227   ${CMAKE_CURRENT_SOURCE_DIR}
228   ${CMAKE_CURRENT_SOURCE_DIR}/../HYDROData
229   ${VTK_INCLUDE_DIRS}
230 )
231
232
233 add_library(HYDROGUI SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${PROJECT_HEADERS_MOC})
234 target_link_libraries(HYDROGUI HYDROData
235     ${CAS_TKV3d} ${CAS_TKTopAlgo} ${CAS_TKBrep} ${CAS_TKBO}
236     ${GUI_LightApp} ${GUI_CAM} ${GUI_suit} ${GUI_qtx} ${GUI_ObjBrowser} ${GUI_GraphicsView} ${GUI_std} 
237     ${GUI_Event} ${GUI_OCCViewer} ${GEOM_GEOM} ${GEOM_GEOMBase} ${GEOM_CurveCreator}
238     ${VTK_LIBRARIES} ${SVTK} ${SalomeObject} ${SalomePrs}
239     )
240
241 INSTALL(TARGETS HYDROGUI EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
242
243 set(PROJECT_LIBRARIES HYDROGUI)
244
245 set(GUITS_SOURCES
246   resources/HYDROGUI_images.ts
247   resources/HYDROGUI_msg_en.ts
248   resources/HYDROGUI_msg_fr.ts
249 )
250
251 #include(../../CMake/CommonInstall.cmake)
252
253 # resources
254 QT4_INSTALL_TS_RESOURCES("${GUITS_SOURCES}" "${SALOME_HYDRO_INSTALL_RES_DATA}")
255
256 FILE(GLOB GUIPNG_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.png")
257 FILE(GLOB GUIXML_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.xml")
258 SET(GUI_DATA ${GUIPNG_DATA} ${GUIXML_DATA})
259 INSTALL(FILES ${GUI_DATA} DESTINATION ${SALOME_HYDRO_INSTALL_RES_DATA})
260
261 # tests
262 if(SALOME_BUILD_TESTS)
263
264   set(TEST_HEADERS 
265     test_HYDROGUI_ListModel.h
266   )
267
268   set(TEST_SOURCES 
269     test_HYDROGUI_Main.cxx
270     test_HYDROGUI_ListModel.cxx    
271   )
272   
273   set(TEST_EXE test_HYDROGUI)
274   include(../../CMake/CPPUnitTests.cmake)
275   target_link_libraries(test_HYDROGUI ${CPPUNIT_LIBRARIES} HYDROData HYDROGUI)
276
277   INSTALL(TARGETS test_HYDROGUI EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_BINS})
278
279 endif(SALOME_BUILD_TESTS)
280