1 # Copyright (C) 2012-2022 CEA/DEN, EDF R&D, OPEN CASCADE
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.
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.
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
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
24 # additional include directories
26 ${OpenCASCADE_INCLUDE_DIR}
29 ${PTHREAD_INCLUDE_DIR}
31 ${PROJECT_SOURCE_DIR}/src/CAM
32 ${PROJECT_SOURCE_DIR}/src/CASCatch
33 ${PROJECT_SOURCE_DIR}/src/Event
34 ${PROJECT_SOURCE_DIR}/src/LogWindow
35 ${PROJECT_SOURCE_DIR}/src/ObjBrowser
36 ${PROJECT_SOURCE_DIR}/src/Prs
37 ${PROJECT_SOURCE_DIR}/src/Qtx
38 ${PROJECT_SOURCE_DIR}/src/STD
39 ${PROJECT_SOURCE_DIR}/src/SUIT
40 ${PROJECT_SOURCE_DIR}/src/Style
42 IF(SALOME_USE_SALOMEOBJECT)
43 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/OBJECT)
45 IF(SALOME_USE_GLVIEWER)
46 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/GLViewer)
48 IF(SALOME_USE_GRAPHICSVIEW)
49 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/GraphicsView)
51 IF(SALOME_USE_PYVIEWER)
52 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/PyEditor)
53 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/PyViewer)
55 IF(SALOME_USE_OCCVIEWER)
56 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/OCCViewer)
57 IF(SALOME_USE_SALOMEOBJECT)
58 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SOCC)
61 IF(SALOME_USE_PV3DVIEWER)
62 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/PV3DViewer)
63 IF(SALOME_USE_SALOMEOBJECT)
64 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SPV3D)
67 IF(SALOME_USE_PLOT2DVIEWER)
68 INCLUDE_DIRECTORIES(${QWT_INCLUDE_DIR})
69 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/Plot2d)
70 IF(SALOME_USE_SALOMEOBJECT)
71 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SPlot2d)
74 IF(SALOME_USE_VTKVIEWER)
75 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/VTKViewer)
76 IF(SALOME_USE_SALOMEOBJECT)
77 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SVTK)
80 IF(SALOME_USE_QXGRAPHVIEWER)
81 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/QxScene)
83 IF(SALOME_USE_PVVIEWER)
84 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/PVViewer)
86 IF(SALOME_USE_PYCONSOLE)
88 ${PYTHON_INCLUDE_DIRS}
89 ${PROJECT_SOURCE_DIR}/tools/PyConsole/src
90 ${PROJECT_SOURCE_DIR}/tools/PyInterp/src
91 ${PROJECT_SOURCE_DIR}/src/SUITApp
95 # additional preprocessor / compiler flags
96 ADD_DEFINITIONS(${OpenCASCADE_DEFINITIONS} ${QT_DEFINITIONS} ${HDF5_DEFINITIONS})
97 IF(SALOME_USE_PLOT2DVIEWER)
98 ADD_DEFINITIONS(${QWT_DEFINITIONS})
100 IF(SALOME_USE_PYCONSOLE)
101 ADD_DEFINITIONS(${PYTHON_DEFINITIONS})
104 # libraries to link to
106 ${OpenCASCADE_FoundationClasses_LIBRARIES}
109 CASCatch qtx suit std SalomeStyle SalomePrs CAM LogWindow ObjBrowser Event
110 ${KERNEL_SalomeHDFPersist} ${KERNEL_SALOMELocalTrace}
112 IF(SALOME_USE_SALOMEOBJECT)
113 LIST(APPEND _link_LIBRARIES SalomeObject)
115 IF(SALOME_USE_GLVIEWER)
116 LIST(APPEND _link_LIBRARIES GLViewer)
118 IF(SALOME_USE_GRAPHICSVIEW)
119 LIST(APPEND _link_LIBRARIES GraphicsView)
121 IF(SALOME_USE_PYVIEWER)
122 LIST(APPEND _link_LIBRARIES PyEditor PyViewer)
124 IF(SALOME_USE_OCCVIEWER)
125 LIST(APPEND _link_LIBRARIES OCCViewer)
126 IF(SALOME_USE_SALOMEOBJECT)
127 LIST(APPEND _link_LIBRARIES SOCC)
130 IF(SALOME_USE_PV3DVIEWER)
131 LIST(APPEND _link_LIBRARIES PV3DViewer)
132 IF(SALOME_USE_SALOMEOBJECT)
133 LIST(APPEND _link_LIBRARIES SPV3D)
136 IF(SALOME_USE_PLOT2DVIEWER)
137 LIST(APPEND _link_LIBRARIES Plot2d)
138 IF(SALOME_USE_SALOMEOBJECT)
139 LIST(APPEND _link_LIBRARIES SPlot2d)
142 IF(SALOME_USE_VTKVIEWER)
143 LIST(APPEND _link_LIBRARIES VTKViewer)
144 IF(SALOME_USE_SALOMEOBJECT)
145 LIST(APPEND _link_LIBRARIES SVTK)
148 IF(SALOME_USE_QXGRAPHVIEWER)
149 LIST(APPEND _link_LIBRARIES QxScene)
151 IF(SALOME_USE_PVVIEWER)
152 LIST(APPEND _link_LIBRARIES PVViewer)
154 IF(SALOME_USE_PYCONSOLE)
155 LIST(APPEND _link_LIBRARIES PyInterp PyConsole SUITApp)
160 # header files / to be processed by moc
163 LightApp_Application.h
167 LightApp_ModuleAction.h
170 LightApp_OBSelector.h
172 LightApp_Preferences.h
173 LightApp_PreferencesDlg.h
174 LightApp_SelectionMgr.h
175 LightApp_ShowHideOp.h
178 LightApp_WgViewModel.h
180 IF(SALOME_USE_GLVIEWER)
181 LIST(APPEND _moc_HEADERS LightApp_GLSelector.h)
183 IF(SALOME_USE_GRAPHICSVIEW)
184 LIST(APPEND _moc_HEADERS LightApp_GVSelector.h)
186 IF(SALOME_USE_OCCVIEWER)
187 LIST(APPEND _moc_HEADERS LightApp_OCCSelector.h)
189 IF(SALOME_USE_PV3DVIEWER)
190 IF(SALOME_USE_SALOMEOBJECT)
191 LIST(APPEND _moc_HEADERS LightApp_PV3DSelector.h)
194 IF(SALOME_USE_PLOT2DVIEWER)
195 LIST(APPEND _moc_HEADERS LightApp_Plot2dSelector.h)
197 IF(SALOME_USE_VTKVIEWER)
198 IF(SALOME_USE_SALOMEOBJECT)
199 LIST(APPEND _moc_HEADERS LightApp_VTKSelector.h)
202 IF(SALOME_USE_PYCONSOLE)
203 LIST(APPEND _moc_HEADERS LightApp_PyEditor.h)
206 # header files / no moc processing
209 LightApp_DataObject.h
211 LightApp_DataSubOwner.h
214 LightApp_EventFilter.h
215 LightApp_FileValidator.h
216 LightApp_FullScreenHelper.h
219 LightApp_UpdateFlags.h
222 # header files / to install
223 SET(LightApp_HEADERS ${_moc_HEADERS} ${_other_HEADERS})
227 # resource files / to be processed by rcc
228 SET(_rcc_RESOURCES LightApp.qrc)
230 # resource files / to be processed by lrelease
232 resources/LightApp_images.ts
233 resources/LightApp_msg_en.ts
234 resources/LightApp_msg_fr.ts
235 resources/LightApp_msg_ja.ts
238 # resource files / static
240 resources/icon_about.png
241 resources/icon_applogo.png
242 resources/icon_default.png
243 resources/icon_module.png
244 resources/icon_select.png
245 resources/icon_earth.png
246 resources/icon_life_ring.png
247 resources/icon_add_module.png
248 resources/icon_remove_module.png
249 resources/LightApp.xml
254 # sources / moc wrappings
255 QT_WRAP_MOC(_moc_SOURCES ${_moc_HEADERS})
257 # sources / rcc wrappings
258 QT_ADD_RESOURCES(_rcc_SOURCES ${_rcc_RESOURCES})
262 LightApp_AboutDlg.cxx
263 LightApp_Application.cxx
264 LightApp_DataModel.cxx
265 LightApp_DataObject.cxx
266 LightApp_DataOwner.cxx
267 LightApp_DataSubOwner.cxx
269 LightApp_Displayer.cxx
271 LightApp_EventFilter.cxx
272 LightApp_FileValidator.cxx
273 LightApp_FullScreenHelper.cxx
274 LightApp_HDFDriver.cxx
276 LightApp_ModuleAction.cxx
277 LightApp_ModuleDlg.cxx
279 LightApp_OBSelector.cxx
280 LightApp_Operation.cxx
281 LightApp_Preferences.cxx
282 LightApp_PreferencesDlg.cxx
283 LightApp_Selection.cxx
284 LightApp_SelectionMgr.cxx
285 LightApp_ShowHideOp.cxx
287 LightApp_SwitchOp.cxx
288 LightApp_WgViewModel.cxx
290 IF(SALOME_USE_GLVIEWER)
291 LIST(APPEND _other_SOURCES LightApp_GLSelector.cxx)
293 IF(SALOME_USE_GRAPHICSVIEW)
294 LIST(APPEND _other_SOURCES LightApp_GVSelector.cxx)
296 IF(SALOME_USE_OCCVIEWER)
297 LIST(APPEND _other_SOURCES LightApp_OCCSelector.cxx)
299 IF(SALOME_USE_PV3DVIEWER)
300 IF(SALOME_USE_SALOMEOBJECT)
301 LIST(APPEND _other_SOURCES LightApp_PV3DSelector.cxx)
304 IF(SALOME_USE_PLOT2DVIEWER)
305 LIST(APPEND _other_SOURCES LightApp_Plot2dSelector.cxx)
307 IF(SALOME_USE_VTKVIEWER)
308 IF(SALOME_USE_SALOMEOBJECT)
309 LIST(APPEND _other_SOURCES LightApp_VTKSelector.cxx)
312 IF(SALOME_USE_PYCONSOLE)
313 LIST(APPEND _other_SOURCES LightApp_PyEditor.cxx)
316 # sources / to compile
317 SET(LightApp_SOURCES ${_other_SOURCES} ${_moc_SOURCES} ${_rcc_SOURCES})
321 ADD_LIBRARY(LightApp ${LightApp_SOURCES})
322 TARGET_LINK_LIBRARIES(LightApp ${_link_LIBRARIES})
323 INSTALL(TARGETS LightApp EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
325 INSTALL(FILES ${LightApp_HEADERS} DESTINATION ${SALOME_INSTALL_HEADERS})
326 QT_INSTALL_TS_RESOURCES("${_ts_RESOURCES}" "${SALOME_GUI_INSTALL_RES_DATA}")
328 INSTALL(FILES ${_other_RESOURCES} DESTINATION ${SALOME_GUI_INSTALL_RES_DATA})