Salome HOME
gestion des includes en .ui
[modules/smesh.git] / src / SMESHGUI / CMakeLists.txt
1 # Copyright (C) 2012-2020  CEA/DEN, EDF R&D, OPEN CASCADE
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 INCLUDE(UseQtExt)
21
22 # --- options ---
23 # additional include directories
24 INCLUDE_DIRECTORIES(
25   ${QT_INCLUDES}
26   ${OGL_INCLUDE_DIRS}
27   ${OpenCASCADE_INCLUDE_DIR}
28   ${PYTHON_INCLUDE_DIRS}
29   ${KERNEL_INCLUDE_DIRS}
30   ${GUI_INCLUDE_DIRS}
31   ${QWT_INCLUDE_DIR}
32   ${GEOM_INCLUDE_DIRS}
33   ${MEDFILE_INCLUDE_DIRS}
34   ${Boost_INCLUDE_DIRS}
35   ${OMNIORB_INCLUDE_DIR}
36   ${HDF5_INCLUDE_DIRS}
37   ${PROJECT_SOURCE_DIR}/src/OBJECT
38   ${PROJECT_SOURCE_DIR}/src/SMESHFiltersSelection
39   ${PROJECT_SOURCE_DIR}/src/SMDS
40   ${PROJECT_SOURCE_DIR}/src/SMESHDS
41   ${PROJECT_SOURCE_DIR}/src/SMESHUtils
42   ${PROJECT_SOURCE_DIR}/src/Controls
43   ${PROJECT_SOURCE_DIR}/src/SMESHClient
44   ${PROJECT_SOURCE_DIR}/src/MEDWrapper
45   ${PROJECT_SOURCE_DIR}/src/ADAPTGUI
46   ${PROJECT_BINARY_DIR}
47   ${PROJECT_BINARY_DIR}/idl
48   ${PROJECT_BINARY_DIR}/src/ADAPTGUI
49 )
50
51 # additional preprocessor / compiler flags
52 ADD_DEFINITIONS(
53   ${OpenCASCADE_DEFINITIONS}
54   ${BOOST_DEFINITIONS}
55   ${OMNIORB_DEFINITIONS}
56 )
57
58 # To avoid GetObject macro definition on WIN32
59 IF(WIN32)
60   ADD_DEFINITIONS(-DNOGDI)
61 ENDIF(WIN32)
62
63 # libraries to link to
64 SET(_link_LIBRARIES
65   ${OpenCASCADE_Visualization_LIBRARIES}
66   ${GUI_SalomePrs}
67   ${GUI_suit}
68   ${GUI_SUITApp}
69   ${GUI_CAM}
70   ${GUI_std}
71   ${GEOM_GEOMBase}
72   ${GEOM_GEOMFiltersSelection}
73   ${GEOM_GEOMObject}
74   SMESHFiltersSelection
75   SMDS
76   SMESHControls
77   SMESHObject
78   ADAPTGUI
79   ADAPTImpl
80   ADAPTEngine
81 )
82
83 # --- headers ---
84
85 # header files / to be processed by moc
86 SET(_moc_HEADERS
87   SMESHGUI.h
88   SMESHGUI_PatternWidget.h
89   SMESHGUI_MeshPatternDlg.h
90   SMESHGUI_CreatePatternDlg.h
91   SMESHGUI_NodesDlg.h
92   SMESHGUI_SpinBox.h
93   SMESHGUI_TransparencyDlg.h
94   SMESHGUI_ClippingDlg.h
95   SMESHGUI_GroupDlg.h
96   SMESHGUI_RemoveNodesDlg.h
97   SMESHGUI_RemoveElementsDlg.h
98   SMESHGUI_MeshInfo.h
99   SMESHGUI_Measurements.h
100   SMESHGUI_Preferences_ScalarBarDlg.h
101   SMESHGUI_AddMeshElementDlg.h
102   SMESHGUI_GroupOnShapeDlg.h
103   SMESHGUI_FileInfoDlg.h
104   SMESHGUI_FilterDlg.h
105   SMESHGUI_FilterLibraryDlg.h
106   SMESHGUI_SingleEditDlg.h
107   SMESHGUI_MultiEditDlg.h
108   SMESHGUI_DeleteGroupDlg.h
109   SMESHGUI_GroupOpDlg.h
110   SMESHGUI_FaceGroupsSeparatedByEdgesDlg.h
111   SMESHGUI_SmoothingDlg.h
112   SMESHGUI_RenumberingDlg.h
113   SMESHGUI_ExtrusionDlg.h
114   SMESHGUI_ExtrusionAlongPathDlg.h
115   SMESHGUI_RevolutionDlg.h
116   SMESHGUI_RotationDlg.h
117   SMESHGUI_TranslationDlg.h
118   SMESHGUI_ScaleDlg.h
119   SMESHGUI_OffsetDlg.h
120   SMESHGUI_SymmetryDlg.h
121   SMESHGUI_SewingDlg.h
122   SMESHGUI_DuplicateNodesDlg.h
123   SMESHGUI_MergeDlg.h
124   SMESHGUI_CreatePolyhedralVolumeDlg.h
125   SMESHGUI_Operation.h
126   SMESHGUI_SelectionOp.h
127   SMESHGUI_Dialog.h
128   SMESHGUI_MeshDlg.h
129   SMESHGUI_MeshOp.h
130   SMESHGUI_Hypotheses.h
131   SMESHGUI_ShapeByMeshDlg.h
132   SMESHGUI_AddQuadraticElementDlg.h
133   SMESHGUI_ConvToQuadDlg.h
134   SMESHGUI_ConvToQuadOp.h
135   SMESHGUI_BuildCompoundDlg.h
136   SMESHGUI_ComputeDlg.h
137   SMESHGUI_MakeNodeAtPointDlg.h
138   SMESHGUI_MeshInfosBox.h
139   SMESHGUI_Make2DFrom3DOp.h
140   SMESHGUI_FindElemByPointDlg.h
141   SMESHGUI_MeshOrderDlg.h
142   SMESHGUI_CopyMeshDlg.h
143   SMESHGUI_MeshOrderOp.h
144   SMESHGUI_PreviewDlg.h
145   SMESHGUI_ReorientFacesDlg.h
146   SMESHGUI_PropertiesDlg.h
147   SMESHGUI_Add0DElemsOnAllNodesDlg.h
148   SMESHGUI_FieldSelectorWdg.h
149   SMESHGUI_DisplayEntitiesDlg.h
150   SMESHGUI_SplitBiQuad.h
151   SMESHGUI_IdPreview.h
152   SMESHGUI_PreVisualObj.h
153   SMESHGUI_AdaptDlg.h
154 )
155
156 # header files / no moc processing
157 SET(_other_HEADERS
158   SMESHGUI_Operations.h
159   SMESHGUI_Utils.h
160   SMESHGUI_HypothesesUtils.h
161   SMESHGUI_Selection.h
162   SMESHGUI_VTKUtils.h
163   SMESHGUI_Displayer.h
164   SMESHGUI_GEOMGenUtils.h
165   SMESHGUI_MeshUtils.h
166   SMESHGUI_FilterUtils.h
167   SMESHGUI_PatternUtils.h
168   SMESHGUI_GroupUtils.h
169   SMESHGUI_XmlHandler.h
170   SMESHGUI_Filter.h
171   SMESHGUI_MeshEditPreview.h
172   SMESHGUI_IdValidator.h
173   SMESHGUI_FileValidator.h
174   SMESHGUI_SelectionProxy.h
175   SMESH_SMESHGUI.hxx
176 )
177
178 # header files / to install
179 SET(SMESH_HEADERS ${_moc_HEADERS} ${_other_HEADERS})
180
181 # --- sources ---
182
183 # sources / moc wrappings
184 QT_WRAP_MOC(_moc_SOURCES ${_moc_HEADERS})
185
186 # sources / static
187 SET(_other_SOURCES
188   SMESHGUI.cxx
189   SMESHGUI_PatternWidget.cxx
190   SMESHGUI_MeshPatternDlg.cxx
191   SMESHGUI_CreatePatternDlg.cxx
192   SMESHGUI_NodesDlg.cxx
193   SMESHGUI_SpinBox.cxx
194   SMESHGUI_TransparencyDlg.cxx
195   SMESHGUI_ClippingDlg.cxx
196   SMESHGUI_GroupDlg.cxx
197   SMESHGUI_RemoveNodesDlg.cxx
198   SMESHGUI_RemoveElementsDlg.cxx
199   SMESHGUI_SelectionProxy.cxx
200   SMESHGUI_MeshInfo.cxx
201   SMESHGUI_Measurements.cxx
202   SMESHGUI_Preferences_ScalarBarDlg.cxx
203   SMESHGUI_AddMeshElementDlg.cxx
204   SMESHGUI_FilterDlg.cxx
205   SMESHGUI_FilterLibraryDlg.cxx
206   SMESHGUI_SingleEditDlg.cxx
207   SMESHGUI_MultiEditDlg.cxx
208   SMESHGUI_DeleteGroupDlg.cxx
209   SMESHGUI_GroupOpDlg.cxx
210   SMESHGUI_FaceGroupsSeparatedByEdgesDlg.cxx
211   SMESHGUI_SmoothingDlg.cxx
212   SMESHGUI_RenumberingDlg.cxx
213   SMESHGUI_ExtrusionDlg.cxx
214   SMESHGUI_ExtrusionAlongPathDlg.cxx
215   SMESHGUI_RevolutionDlg.cxx
216   SMESHGUI_RotationDlg.cxx
217   SMESHGUI_TranslationDlg.cxx
218   SMESHGUI_ScaleDlg.cxx
219   SMESHGUI_OffsetDlg.cxx
220   SMESHGUI_SymmetryDlg.cxx
221   SMESHGUI_SewingDlg.cxx
222   SMESHGUI_DuplicateNodesDlg.cxx
223   SMESHGUI_MergeDlg.cxx
224   SMESHGUI_CreatePolyhedralVolumeDlg.cxx
225   SMESHGUI_Operation.cxx
226   SMESHGUI_SelectionOp.cxx
227   SMESHGUI_Dialog.cxx
228   SMESHGUI_MeshDlg.cxx
229   SMESHGUI_MeshOp.cxx
230   SMESHGUI_Hypotheses.cxx
231   SMESHGUI_ShapeByMeshDlg.cxx
232   SMESHGUI_AddQuadraticElementDlg.cxx
233   SMESHGUI_ConvToQuadDlg.cxx
234   SMESHGUI_ConvToQuadOp.cxx
235   SMESHGUI_BuildCompoundDlg.cxx
236   SMESHGUI_ComputeDlg.cxx
237   SMESHGUI_MakeNodeAtPointDlg.cxx
238   SMESHGUI_GroupOnShapeDlg.cxx
239   SMESHGUI_FileInfoDlg.cxx
240   SMESHGUI_MeshInfosBox.cxx
241   SMESHGUI_Make2DFrom3DOp.cxx
242   SMESHGUI_FindElemByPointDlg.cxx
243   SMESHGUI_MeshOrderDlg.cxx
244   SMESHGUI_CopyMeshDlg.cxx
245   SMESHGUI_MeshOrderOp.cxx
246   SMESHGUI_PreviewDlg.cxx
247   SMESHGUI_ReorientFacesDlg.cxx
248   SMESHGUI_PropertiesDlg.cxx
249   SMESHGUI_Add0DElemsOnAllNodesDlg.cxx
250   SMESHGUI_Utils.cxx
251   SMESHGUI_HypothesesUtils.cxx
252   SMESHGUI_Selection.cxx
253   SMESHGUI_VTKUtils.cxx
254   SMESHGUI_Displayer.cxx
255   SMESHGUI_GEOMGenUtils.cxx
256   SMESHGUI_MeshUtils.cxx
257   SMESHGUI_FilterUtils.cxx
258   SMESHGUI_PatternUtils.cxx
259   SMESHGUI_GroupUtils.cxx
260   SMESHGUI_XmlHandler.cxx
261   SMESHGUI_Filter.cxx
262   SMESHGUI_MeshEditPreview.cxx
263   SMESHGUI_FileValidator.cxx
264   SMESHGUI_FieldSelectorWdg.cxx
265   SMESHGUI_DisplayEntitiesDlg.cxx
266   SMESHGUI_SplitBiQuad.cxx
267   SMESHGUI_PreVisualObj.cxx
268   SMESHGUI_IdPreview.cxx
269   SMESHGUI_AdaptDlg.cxx
270 )
271
272 # sources / to compile
273 SET(SMESH_SOURCES ${_other_SOURCES} ${_moc_SOURCES})
274
275 # --- resources ---
276
277 # resource files / to be processed by lrelease
278 SET(_ts_RESOURCES
279   SMESH_images.ts
280   SMESH_msg_en.ts
281   SMESH_msg_fr.ts
282   SMESH_msg_ja.ts
283 )
284
285 # --- rules ---
286
287 ADD_LIBRARY(SMESH ${SMESH_SOURCES})
288 TARGET_LINK_LIBRARIES(SMESH ${_link_LIBRARIES} )
289 INSTALL(TARGETS SMESH EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
290
291 INSTALL(FILES ${SMESH_HEADERS} DESTINATION ${SALOME_INSTALL_HEADERS})
292
293 QT_INSTALL_TS_RESOURCES("${_ts_RESOURCES}" "${SALOME_SMESH_INSTALL_RES_DATA}")