1 # Copyright (C) 2012-2015 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
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_PLOT2DVIEWER)
62 INCLUDE_DIRECTORIES(${QWT_INCLUDE_DIR})
63 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/Plot2d)
64 IF(SALOME_USE_SALOMEOBJECT)
65 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SPlot2d)
68 IF(SALOME_USE_VTKVIEWER)
69 INCLUDE_DIRECTORIES(${VTK_INCLUDE_DIRS})
70 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/VTKViewer)
71 IF(SALOME_USE_SALOMEOBJECT)
72 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/SVTK)
75 IF(SALOME_USE_QXGRAPHVIEWER)
76 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/QxScene)
78 IF(SALOME_USE_PVVIEWER)
79 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/PVViewer)
81 IF(SALOME_USE_PYCONSOLE)
83 ${PYTHON_INCLUDE_DIRS}
84 ${PROJECT_SOURCE_DIR}/src/PyConsole
85 ${PROJECT_SOURCE_DIR}/src/PyConsoleBase
86 ${PROJECT_SOURCE_DIR}/src/PyInterp
87 ${PROJECT_SOURCE_DIR}/src/SUITApp
91 # additional preprocessor / compiler flags
92 ADD_DEFINITIONS(${CAS_DEFINITIONS} ${QT_DEFINITIONS} ${HDF5_DEFINITIONS})
93 IF(SALOME_USE_PLOT2DVIEWER)
94 ADD_DEFINITIONS(${QWT_DEFINITIONS})
96 IF(SALOME_USE_PYCONSOLE)
97 ADD_DEFINITIONS(${PYTHON_DEFINITIONS})
100 # libraries to link to
105 CASCatch qtx suit std SalomeStyle SalomePrs CAM LogWindow ObjBrowser Event
106 ${KERNEL_SalomeHDFPersist} ${KERNEL_SALOMELocalTrace}
108 IF(SALOME_USE_SALOMEOBJECT)
109 LIST(APPEND _link_LIBRARIES SalomeObject)
111 IF(SALOME_USE_GLVIEWER)
112 LIST(APPEND _link_LIBRARIES GLViewer)
114 IF(SALOME_USE_GRAPHICSVIEW)
115 LIST(APPEND _link_LIBRARIES GraphicsView)
117 IF(SALOME_USE_PYVIEWER)
118 LIST(APPEND _link_LIBRARIES PyEditor PyViewer)
120 IF(SALOME_USE_OCCVIEWER)
121 LIST(APPEND _link_LIBRARIES OCCViewer)
122 IF(SALOME_USE_SALOMEOBJECT)
123 LIST(APPEND _link_LIBRARIES SOCC)
126 IF(SALOME_USE_PLOT2DVIEWER)
127 LIST(APPEND _link_LIBRARIES Plot2d)
128 IF(SALOME_USE_SALOMEOBJECT)
129 LIST(APPEND _link_LIBRARIES SPlot2d)
132 IF(SALOME_USE_VTKVIEWER)
133 LIST(APPEND _link_LIBRARIES VTKViewer)
134 IF(SALOME_USE_SALOMEOBJECT)
135 LIST(APPEND _link_LIBRARIES SVTK)
138 IF(SALOME_USE_QXGRAPHVIEWER)
139 LIST(APPEND _link_LIBRARIES QxScene)
141 IF(SALOME_USE_PVVIEWER)
142 LIST(APPEND _link_LIBRARIES PVViewer)
144 IF(SALOME_USE_PYCONSOLE)
145 LIST(APPEND _link_LIBRARIES PyInterp PyConsole SUITApp)
150 # header files / to be processed by moc
153 LightApp_Application.h
157 LightApp_ModuleAction.h
160 LightApp_OBSelector.h
162 LightApp_Preferences.h
163 LightApp_PreferencesDlg.h
164 LightApp_SelectionMgr.h
165 LightApp_ShowHideOp.h
168 LightApp_WgViewModel.h
170 IF(SALOME_USE_GLVIEWER)
171 LIST(APPEND _moc_HEADERS LightApp_GLSelector.h)
173 IF(SALOME_USE_GRAPHICSVIEW)
174 LIST(APPEND _moc_HEADERS LightApp_GVSelector.h)
176 IF(SALOME_USE_OCCVIEWER)
177 LIST(APPEND _moc_HEADERS LightApp_OCCSelector.h)
179 IF(SALOME_USE_PLOT2DVIEWER)
180 LIST(APPEND _moc_HEADERS LightApp_Plot2dSelector.h)
182 IF(SALOME_USE_VTKVIEWER)
183 IF(SALOME_USE_SALOMEOBJECT)
184 LIST(APPEND _moc_HEADERS LightApp_VTKSelector.h)
188 # header files / no moc processing
191 LightApp_DataObject.h
193 LightApp_DataSubOwner.h
196 LightApp_EventFilter.h
197 LightApp_FullScreenHelper.h
200 LightApp_UpdateFlags.h
202 IF(SALOME_USE_PYCONSOLE)
203 LIST(APPEND _other_HEADERS LightApp_PyInterp.h)
206 # header files / to install
207 SET(LightApp_HEADERS ${_moc_HEADERS} ${_other_HEADERS})
211 # resource files / to be processed by rcc
212 SET(_rcc_RESOURCES LightApp.qrc)
214 # resource files / to be processed by lrelease
216 resources/LightApp_images.ts
217 resources/LightApp_msg_en.ts
218 resources/LightApp_msg_fr.ts
219 resources/LightApp_msg_ja.ts
222 # resource files / static
224 resources/icon_about.png
225 resources/icon_applogo.png
226 resources/icon_default.png
227 resources/icon_module.png
228 resources/icon_module_big.png
229 resources/icon_select.png
230 resources/LightApp.ini
231 resources/LightApp.xml
236 # sources / rcc wrappings
237 QT4_ADD_RESOURCES(_rcc_SOURCES ${_rcc_RESOURCES})
239 # sources / moc wrappings
240 QT4_WRAP_CPP(_moc_SOURCES ${_moc_HEADERS})
244 LightApp_AboutDlg.cxx
245 LightApp_Application.cxx
246 LightApp_DataModel.cxx
247 LightApp_DataObject.cxx
248 LightApp_DataOwner.cxx
249 LightApp_DataSubOwner.cxx
251 LightApp_Displayer.cxx
253 LightApp_EventFilter.cxx
254 LightApp_FullScreenHelper.cxx
255 LightApp_HDFDriver.cxx
257 LightApp_ModuleAction.cxx
258 LightApp_ModuleDlg.cxx
260 LightApp_OBSelector.cxx
261 LightApp_Operation.cxx
262 LightApp_Preferences.cxx
263 LightApp_PreferencesDlg.cxx
264 LightApp_Selection.cxx
265 LightApp_SelectionMgr.cxx
266 LightApp_ShowHideOp.cxx
268 LightApp_SwitchOp.cxx
269 LightApp_WgViewModel.cxx
271 IF(SALOME_USE_GLVIEWER)
272 LIST(APPEND _other_SOURCES LightApp_GLSelector.cxx)
274 IF(SALOME_USE_GRAPHICSVIEW)
275 LIST(APPEND _other_SOURCES LightApp_GVSelector.cxx)
277 IF(SALOME_USE_OCCVIEWER)
278 LIST(APPEND _other_SOURCES LightApp_OCCSelector.cxx)
280 IF(SALOME_USE_PLOT2DVIEWER)
281 LIST(APPEND _other_SOURCES LightApp_Plot2dSelector.cxx)
283 IF(SALOME_USE_VTKVIEWER)
284 IF(SALOME_USE_SALOMEOBJECT)
285 LIST(APPEND _other_SOURCES LightApp_VTKSelector.cxx)
288 IF(SALOME_USE_PYCONSOLE)
289 LIST(APPEND _other_SOURCES LightApp_PyInterp.cxx)
292 # sources / to compile
293 SET(LightApp_SOURCES ${_other_SOURCES} ${_moc_SOURCES} ${_rcc_SOURCES})
297 ADD_LIBRARY(LightApp ${LightApp_SOURCES})
298 TARGET_LINK_LIBRARIES(LightApp ${_link_LIBRARIES})
299 INSTALL(TARGETS LightApp EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
301 INSTALL(FILES ${LightApp_HEADERS} DESTINATION ${SALOME_INSTALL_HEADERS})
302 QT4_INSTALL_TS_RESOURCES("${_ts_RESOURCES}" "${SALOME_GUI_INSTALL_RES_DATA}")
304 INSTALL(FILES ${_other_RESOURCES} DESTINATION ${SALOME_GUI_INSTALL_RES_DATA})