Salome HOME
Merge remote-tracking branch 'origin/BR_LAND_COVER' into BR_v14_rc
[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_DataOwner.h
22     HYDROGUI_DeleteDlg.h
23     HYDROGUI_DeleteOp.h
24     HYDROGUI_DigueDlg.h
25     HYDROGUI_DigueOp.h
26     HYDROGUI_Displayer.h
27     HYDROGUI_DuplicateOp.h
28     HYDROGUI_ExportImageOp.h
29     HYDROGUI_ExportFileOp.h
30     HYDROGUI_GVSelector.h
31     HYDROGUI_ImagePrs.h
32         HYDROGUI_BasicZoneDlg.h
33     HYDROGUI_ImmersibleZoneDlg.h
34     HYDROGUI_ImmersibleZoneOp.h
35     HYDROGUI_ImportBathymetryDlg.h
36     HYDROGUI_ImportBathymetryOp.h
37     HYDROGUI_ImportImageDlg.h
38     HYDROGUI_ImportImageOp.h
39     HYDROGUI_ImportPolylineOp.h
40     HYDROGUI_ImportSinusXOp.h
41     HYDROGUI_ExportSinusXOp.h
42     HYDROGUI_ExportSinusXDlg.h
43     HYDROGUI_InputPanel.h
44     HYDROGUI_LocalCSDlg.h
45     HYDROGUI_LocalCSOp.h
46     HYDROGUI_MergePolylinesDlg.h
47     HYDROGUI_MergePolylinesOp.h
48     HYDROGUI_Module.h
49     HYDROGUI_NameValidator.h
50     HYDROGUI_ObjSelector.h
51     HYDROGUI_ObserveImageOp.h
52     HYDROGUI_OCCDisplayer.h
53     HYDROGUI_OCCSelector.h
54     HYDROGUI_Operation.h
55     HYDROGUI_Operations.h
56     HYDROGUI_Poly3DDlg.h
57     HYDROGUI_Poly3DOp.h
58     HYDROGUI_PolylineDlg.h
59     HYDROGUI_PolylineOp.h
60     HYDROGUI_ProfileDlg.h
61     HYDROGUI_ProfileOp.h
62     HYDROGUI_ProfileInterpolateDlg.h
63     HYDROGUI_ProfileInterpolateOp.h
64     HYDROGUI_Prs.h
65     HYDROGUI_PrsDriver.h
66     HYDROGUI_PrsImage.h
67     HYDROGUI_PrsImageDriver.h
68     HYDROGUI_PrsImageFrame.h
69     HYDROGUI_PrsPolyline.h
70     HYDROGUI_PrsPolylineDriver.h
71     HYDROGUI_PrsZone.h
72     HYDROGUI_PrsZoneDriver.h
73     HYDROGUI_Region.h
74     HYDROGUI_RemoveImageRefsOp.h
75     HYDROGUI_Shape.h
76     HYDROGUI_Polyline.h
77     HYDROGUI_ShapeBathymetry.h
78     HYDROGUI_ShapeImage.h
79     HYDROGUI_ShowHideOp.h
80     HYDROGUI_SplitPolylinesDlg.h
81     HYDROGUI_SplitPolylinesOp.h
82     HYDROGUI_StreamDlg.h
83     HYDROGUI_StreamOp.h
84     HYDROGUI_LineEditDoubleValidator.h
85     HYDROGUI_StricklerTableDlg.h
86     HYDROGUI_StricklerTableOp.h
87         HYDROGUI_LandCoverDlg.h
88         HYDROGUI_LandCoverOp.h
89     HYDROGUI_SubmersibleOp.h
90     HYDROGUI_Tool.h
91     HYDROGUI_TwoImagesDlg.h
92     HYDROGUI_TwoImagesOp.h
93     HYDROGUI_UpdateFlags.h
94     HYDROGUI_UpdateObjectOp.h
95     HYDROGUI_VisualStateOp.h
96     HYDROGUI_VTKPrs.h
97     HYDROGUI_VTKPrsBathymetry.h
98     HYDROGUI_VTKPrsBathymetryDriver.h
99     HYDROGUI_VTKPrsDisplayer.h
100     HYDROGUI_VTKPrsDriver.h
101     HYDROGUI_VTKPrsShape.h
102     HYDROGUI_VTKPrsShapeDriver.h
103     HYDROGUI_Wizard.h
104     HYDROGUI_Zone.h
105     HYDROGUI_ImportGeomObjectOp.h
106     HYDROGUI_ImportObstacleFromFileOp.h
107     HYDROGUI_ExportCalculationOp.h
108     HYDROGUI_GeomObjectDlg.h
109     HYDROGUI_SetColorOp.h
110     HYDROGUI_ColorDlg.h
111     HYDROGUI_ImportProfilesOp.h
112     HYDROGUI_GeoreferencementDlg.h
113     HYDROGUI_GeoreferencementOp.h
114     HYDROGUI_Actor.h
115     HYDROGUI_BathymetryBoundsOp.h
116     HYDROGUI_TranslateObstacleDlg.h
117     HYDROGUI_TranslateObstacleOp.h
118     HYDROGUI_ListModel.h
119     HYDROGUI_ZLevelsDlg.h
120     HYDROGUI_ZLevelsOp.h
121     HYDROGUI_OrderedListWidget.h
122     HYDROGUI_ListSelector.h
123     HYDROGUI_ZLayers.h
124     HYDROGUI_PriorityWidget.h
125     HYDROGUI_PriorityTableModel.h
126     HYDROGUI_RiverBottomDlg.h
127     HYDROGUI_RiverBottomOp.h
128     HYDROGUI_ViewerDlg.h
129     HYDROGUI_ObjComboBox.h
130     HYDROGUI_ObjListBox.h
131     HYDROGUI_RecognizeContoursDlg.h
132     HYDROGUI_RecognizeContoursOp.h
133 )
134
135 QT4_WRAP_CPP(PROJECT_HEADERS_MOC ${PROJECT_HEADERS})
136
137 set(PROJECT_SOURCES 
138     HYDROGUI_AbstractDisplayer.cxx
139     HYDROGUI_AISTrihedron.cxx
140     HYDROGUI_BathymetryPrs.cxx
141     HYDROGUI_CalculationDlg.cxx
142     HYDROGUI_CalculationOp.cxx
143     HYDROGUI_ChannelDlg.cxx
144     HYDROGUI_ChannelOp.cxx
145     HYDROGUI_ColorWidget.cxx
146     HYDROGUI_CopyPasteOp.cxx
147     HYDROGUI_CopyPastePositionOp.cxx
148     HYDROGUI_CurveCreatorProfile.cxx
149     HYDROGUI_DataBrowser.cxx
150     HYDROGUI_DataModel.cxx
151     HYDROGUI_DataModelSync.cxx
152     HYDROGUI_DataObject.cxx
153         HYDROGUI_DataOwner.cxx
154     HYDROGUI_DeleteDlg.cxx
155     HYDROGUI_DeleteOp.cxx
156     HYDROGUI_DigueDlg.cxx
157     HYDROGUI_DigueOp.cxx
158     HYDROGUI_Displayer.cxx
159     HYDROGUI_DuplicateOp.cxx
160     HYDROGUI_ExportImageOp.cxx
161     HYDROGUI_ExportFileOp.cxx
162     HYDROGUI_GVSelector.cxx
163     HYDROGUI_ImagePrs.cxx
164         HYDROGUI_BasicZoneDlg.cxx
165     HYDROGUI_ImmersibleZoneDlg.cxx
166     HYDROGUI_ImmersibleZoneOp.cxx
167     HYDROGUI_ImportBathymetryDlg.cxx
168     HYDROGUI_ImportBathymetryOp.cxx
169     HYDROGUI_ImportImageDlg.cxx
170     HYDROGUI_ImportImageOp.cxx
171     HYDROGUI_ImportPolylineOp.cxx
172     HYDROGUI_ImportSinusXOp.cxx
173     HYDROGUI_ExportSinusXOp.cxx
174     HYDROGUI_ExportSinusXDlg.cxx
175     HYDROGUI_InputPanel.cxx
176     HYDROGUI_LocalCSDlg.cxx
177     HYDROGUI_LocalCSOp.cxx
178     HYDROGUI_MergePolylinesDlg.cxx
179     HYDROGUI_MergePolylinesOp.cxx
180     HYDROGUI_Module.cxx
181     HYDROGUI_NameValidator.cxx
182     HYDROGUI_ObjSelector.cxx
183     HYDROGUI_ObserveImageOp.cxx
184     HYDROGUI_OCCDisplayer.cxx
185     HYDROGUI_OCCSelector.cxx
186     HYDROGUI_Operation.cxx
187     HYDROGUI_Operations.cxx
188     HYDROGUI_Poly3DDlg.cxx
189     HYDROGUI_Poly3DOp.cxx
190     HYDROGUI_PolylineDlg.cxx
191     HYDROGUI_PolylineOp.cxx
192     HYDROGUI_ProfileDlg.cxx
193     HYDROGUI_ProfileOp.cxx
194     HYDROGUI_ProfileInterpolateDlg.cxx
195     HYDROGUI_ProfileInterpolateOp.cxx
196     HYDROGUI_Prs.cxx
197     HYDROGUI_PrsDriver.cxx
198     HYDROGUI_PrsImage.cxx
199     HYDROGUI_PrsImageDriver.cxx
200     HYDROGUI_PrsImageFrame.cxx
201     HYDROGUI_PrsPolyline.cxx
202     HYDROGUI_PrsPolylineDriver.cxx
203     HYDROGUI_PrsZone.cxx
204     HYDROGUI_PrsZoneDriver.cxx
205     HYDROGUI_Region.cxx
206     HYDROGUI_RemoveImageRefsOp.cxx
207     HYDROGUI_Shape.cxx
208     HYDROGUI_Polyline.cxx
209     HYDROGUI_ShapeBathymetry.cxx
210     HYDROGUI_ShapeImage.cxx
211     HYDROGUI_ShowHideOp.cxx
212     HYDROGUI_StreamDlg.cxx
213     HYDROGUI_StreamOp.cxx
214     HYDROGUI_LineEditDoubleValidator.cxx
215     HYDROGUI_StricklerTableDlg.cxx
216     HYDROGUI_StricklerTableOp.cxx
217         HYDROGUI_LandCoverDlg.cxx
218         HYDROGUI_LandCoverOp.cxx
219     HYDROGUI_SplitPolylinesDlg.cxx
220     HYDROGUI_SplitPolylinesOp.cxx
221     HYDROGUI_SubmersibleOp.cxx
222     HYDROGUI_Tool.cxx
223     HYDROGUI_TwoImagesDlg.cxx
224     HYDROGUI_TwoImagesOp.cxx
225     HYDROGUI_UpdateObjectOp.cxx
226     HYDROGUI_VisualStateOp.cxx
227     HYDROGUI_VTKPrs.cxx
228     HYDROGUI_VTKPrsBathymetry.cxx
229     HYDROGUI_VTKPrsBathymetryDriver.cxx
230     HYDROGUI_VTKPrsDisplayer.cxx
231     HYDROGUI_VTKPrsDriver.cxx
232     HYDROGUI_VTKPrsShape.cxx
233     HYDROGUI_VTKPrsShapeDriver.cxx
234     HYDROGUI_Wizard.cxx
235     HYDROGUI_Zone.cxx
236     HYDROGUI_ImportGeomObjectOp.cxx
237     HYDROGUI_ImportObstacleFromFileOp.cxx
238     HYDROGUI_ExportCalculationOp.cxx
239     HYDROGUI_GeomObjectDlg.cxx
240     HYDROGUI_SetColorOp.cxx
241     HYDROGUI_ColorDlg.cxx
242     HYDROGUI_ImportProfilesOp.cxx
243     HYDROGUI_GeoreferencementDlg.cxx
244     HYDROGUI_GeoreferencementOp.cxx
245     HYDROGUI_Actor.cxx
246     HYDROGUI_BathymetryBoundsOp.cxx
247     HYDROGUI_TranslateObstacleDlg.cxx
248     HYDROGUI_TranslateObstacleOp.cxx
249     HYDROGUI_ListModel.cxx
250     HYDROGUI_ZLevelsDlg.cxx
251     HYDROGUI_ZLevelsOp.cxx
252     HYDROGUI_OrderedListWidget.cxx
253     HYDROGUI_ListSelector.cxx
254     HYDROGUI_ZLayers.cxx
255     HYDROGUI_ZLayers2.cxx
256     HYDROGUI_ZLayers3.cxx
257     HYDROGUI_PriorityWidget.cxx
258     HYDROGUI_PriorityTableModel.cxx
259     HYDROGUI_RiverBottomDlg.cxx
260     HYDROGUI_RiverBottomOp.cxx
261     HYDROGUI_ViewerDlg.cxx
262     HYDROGUI_ObjComboBox.cxx
263     HYDROGUI_ObjListBox.cxx
264     HYDROGUI_RecognizeContoursDlg.cxx
265     HYDROGUI_RecognizeContoursOp.cxx
266 )
267
268 add_definitions(
269   -DHYDROGUI_EXPORTS
270   ${CAS_DEFINITIONS}
271   ${OMNIORB_DEFINITIONS}
272   ${QT_DEFINITIONS}
273 #  $(GUI_CXXFLAGS)
274   ${GUI_DEFINITIONS}
275 #  $(GEOM_CXXFLAGS)
276   ${GEOM_DEFINITIONS}
277 )
278
279 include_directories(
280   ${CAS_INCLUDE_DIRS}
281   ${QT_INCLUDES}
282 #  ${GUI_ROOT_DIR}/include/salome
283   ${GUI_INCLUDE_DIRS}
284 #  ${GEOM_ROOT_DIR}/include/salome
285   ${GEOM_INCLUDE_DIRS}
286   ${CMAKE_CURRENT_SOURCE_DIR}
287   ${CMAKE_CURRENT_SOURCE_DIR}/../HYDROData
288   ${VTK_INCLUDE_DIRS}
289 )
290
291
292 add_library(HYDROGUI SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${PROJECT_HEADERS_MOC})
293 target_link_libraries(HYDROGUI HYDROData
294     ${CAS_TKV3d} ${CAS_TKTopAlgo} ${CAS_TKBrep} ${CAS_TKBO}
295     ${GUI_LightApp} ${GUI_CAM} ${GUI_suit} ${GUI_qtx} ${GUI_ObjBrowser} ${GUI_GraphicsView} ${GUI_std} 
296     ${GUI_Event} ${GUI_OCCViewer} ${GEOM_GEOM} ${GEOM_GEOMBase} ${GEOM_CurveCreator}
297     ${VTK_LIBRARIES} ${SVTK} ${SalomeObject} ${SalomePrs}
298     )
299
300 INSTALL(TARGETS HYDROGUI EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
301
302 set(PROJECT_LIBRARIES HYDROGUI)
303
304 set(GUITS_SOURCES
305   resources/HYDROGUI_images.ts
306   resources/HYDROGUI_msg_en.ts
307   resources/HYDROGUI_msg_fr.ts
308 )
309
310 #include(../../CMake/CommonInstall.cmake)
311
312 # resources
313 QT4_INSTALL_TS_RESOURCES("${GUITS_SOURCES}" "${SALOME_HYDRO_INSTALL_RES_DATA}")
314
315 FILE(GLOB GUIPNG_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.png")
316 FILE(GLOB GUIXML_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.xml")
317 FILE(GLOB GUITXT_DATA "${CMAKE_CURRENT_SOURCE_DIR}/resources/*.txt")
318 SET(GUI_DATA ${GUIPNG_DATA} ${GUIXML_DATA} ${GUITXT_DATA})
319 INSTALL(FILES ${GUI_DATA} DESTINATION ${SALOME_HYDRO_INSTALL_RES_DATA})
320
321 # tests
322 if(SALOME_BUILD_TESTS)
323
324   set(TEST_HEADERS 
325     test_HYDROGUI_ListModel.h
326   )
327
328   set(TEST_SOURCES 
329     test_HYDROGUI_Main.cxx
330     test_HYDROGUI_ListModel.cxx    
331   )
332   
333   set(TEST_EXE test_HYDROGUI)
334   include(../../CMake/CPPUnitTests.cmake)
335   target_link_libraries(test_HYDROGUI ${CPPUNIT_LIBRARIES} HYDROData HYDROGUI)
336
337   INSTALL(TARGETS test_HYDROGUI EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_BINS})
338
339 endif(SALOME_BUILD_TESTS)
340