]> SALOME platform Git repositories - modules/shaper.git/blob - src/PartSet/CMakeLists.txt
Salome HOME
Issue #2552: Intersection edition is impossible
[modules/shaper.git] / src / PartSet / CMakeLists.txt
1 ## Copyright (C) 2014-2017  CEA/DEN, EDF R&D
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
18 ## email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
19 ##
20
21 INCLUDE(Common)
22 INCLUDE(UseQtExt)
23
24 # additional include directories
25 INCLUDE_DIRECTORIES(${QT_INCLUDES})
26
27 # additional preprocessor / compiler flags
28 ADD_DEFINITIONS(${QT_DEFINITIONS})
29
30 SET(PROJECT_HEADERS
31     PartSet.h
32     PartSet_Constants.h
33     PartSet_CustomPrs.h
34     PartSet_ExternalObjectsMgr.h
35     PartSet_FilterInfinite.h
36     PartSet_Filters.h
37     PartSet_IconFactory.h
38     PartSet_MenuMgr.h
39     PartSet_Module.h
40     PartSet_MouseProcessor.h
41     PartSet_OperationPrs.h
42     PartSet_OverconstraintListener.h
43     PartSet_PreviewPlanes.h
44     PartSet_PreviewSketchPlane.h
45     PartSet_ResultSketchPrs.h
46     PartSet_SketcherMgr.h
47     PartSet_SketcherReentrantMgr.h
48     PartSet_Tools.h
49     PartSet_Validators.h
50     PartSet_WidgetEditor.h
51     PartSet_WidgetFeaturePointSelector.h
52     PartSet_WidgetFileSelector.h
53     PartSet_WidgetMultiSelector.h
54     PartSet_WidgetPoint2d.h
55     PartSet_WidgetPoint2DFlyout.h
56     PartSet_WidgetShapeSelector.h
57     PartSet_WidgetSketchCreator.h
58     PartSet_WidgetSketchLabel.h
59     PartSet_CenterPrs.h
60     PartSet_ExternalPointsMgr.h
61 )
62
63 SET(PROJECT_MOC_HEADERS
64
65     PartSet_MenuMgr.h
66     PartSet_Module.h
67     PartSet_SketcherMgr.h
68     PartSet_SketcherReentrantMgr.h
69     PartSet_WidgetEditor.h
70     PartSet_WidgetFeaturePointSelector.h
71     PartSet_WidgetFileSelector.h
72     PartSet_WidgetMultiSelector.h
73     PartSet_WidgetPoint2d.h
74     PartSet_WidgetPoint2DFlyout.h
75     PartSet_WidgetShapeSelector.h
76     PartSet_WidgetSketchCreator.h
77     PartSet_WidgetSketchLabel.h
78     PartSet_ExternalPointsMgr.h
79 )
80
81 SET(PROJECT_SOURCES
82     PartSet_CustomPrs.cpp
83     PartSet_ExternalObjectsMgr.cpp
84     PartSet_FilterInfinite.cpp
85     PartSet_Filters.cpp
86     PartSet_IconFactory.cpp
87     PartSet_MenuMgr.cpp
88     PartSet_Module.cpp
89     PartSet_OperationPrs.cpp
90     PartSet_OverconstraintListener.cpp
91     PartSet_PreviewPlanes.cpp
92     PartSet_PreviewSketchPlane.cpp
93     PartSet_ResultSketchPrs.cpp
94     PartSet_SketcherMgr.cpp
95     PartSet_SketcherReentrantMgr.cpp
96     PartSet_Tools.cpp
97     PartSet_Validators.cpp
98     PartSet_WidgetEditor.cpp
99     PartSet_WidgetFeaturePointSelector.cpp
100     PartSet_WidgetFileSelector.cpp
101     PartSet_WidgetMultiSelector.cpp
102     PartSet_WidgetPoint2d.cpp
103     PartSet_WidgetPoint2DFlyout.cpp
104     PartSet_WidgetShapeSelector.cpp
105     PartSet_WidgetSketchCreator.cpp
106     PartSet_WidgetSketchLabel.cpp
107     PartSet_CenterPrs.cpp
108     PartSet_ExternalPointsMgr.cpp
109 )
110
111 SET(PROJECT_RESOURCES
112     PartSet_icons.qrc
113 )
114
115 #SET(TEXT_RESOURCES
116 #    PartSet_msg_fr.ts
117 #)
118
119 SET(PROJECT_LIBRARIES
120     ModuleBase
121     ModelGeomAlgo
122     Config
123     GeomAPI
124     GeomDataAPI
125     SketcherPrs
126     ${QT_LIBRARIES}
127     ${CAS_KERNEL}
128     ${CAS_SHAPE}
129 )
130
131 # sources / moc wrappings
132 QT_WRAP_MOC(PROJECT_AUTOMOC ${PROJECT_MOC_HEADERS})
133
134 # sources / rcc wrappings
135 QT_ADD_RESOURCES(PROJECT_COMPILED_RESOURCES ${PROJECT_RESOURCES})
136 #QT4_ADD_TRANSLATION(QM_RESOURCES ${TEXT_RESOURCES})
137 #QT4_CREATE_TRANSLATION(QM_RESOURCES
138 #                       ${PROJECT_SOURCES}
139 #                       ${TEXT_RESOURCES}
140 #                       OPTIONS -extensions cpp -no-recursive
141 #                       )
142
143 #SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES} ${QM_RESOURCES})
144 SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES})
145 #SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES} ${PROJECT_RESOURCES})
146 SOURCE_GROUP ("Resource Files" FILES ${PROJECT_RESOURCES})
147
148 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/XGUI
149                     ${PROJECT_SOURCE_DIR}/src/Config
150                     ${PROJECT_SOURCE_DIR}/src/Events
151                     ${PROJECT_SOURCE_DIR}/src/ModuleBase
152                     ${PROJECT_SOURCE_DIR}/src/ModelAPI
153                     ${PROJECT_SOURCE_DIR}/src/ModelGeomAlgo
154                     ${PROJECT_SOURCE_DIR}/src/GeomDataAPI
155                     ${PROJECT_SOURCE_DIR}/src/GeomAlgoAPI
156                     ${PROJECT_SOURCE_DIR}/src/SketchPlugin
157                     ${PROJECT_SOURCE_DIR}/src/ExchangePlugin
158                     ${PROJECT_SOURCE_DIR}/src/SketcherPrs
159                     ${PROJECT_SOURCE_DIR}/src/FeaturesPlugin
160                     ${PROJECT_SOURCE_DIR}/src/PartSetPlugin
161                     ${PROJECT_SOURCE_DIR}/src/GeomAPI
162                     ${PROJECT_SOURCE_DIR}/src/CollectionPlugin
163                     ${CAS_INCLUDE_DIRS}
164                     ${SUIT_INCLUDE}
165 )
166
167 IF(${HAVE_SALOME})
168   INCLUDE_DIRECTORIES(${SALOME_KERNEL_INCLUDE})
169 ELSE(${HAVE_SALOME})
170   INCLUDE_DIRECTORIES(${APPELEMENTS_INCLUDE_DIR})
171 ENDIF(${HAVE_SALOME})
172
173
174 ADD_DEFINITIONS(-DPARTSET_EXPORTS ${CAS_DEFINITIONS})
175 ADD_LIBRARY(PartSet SHARED
176     ${PROJECT_SOURCES}
177     ${PROJECT_HEADERS}
178     ${PROJECT_COMPILED_RESOURCES}
179     ${PROJECT_AUTOMOC}
180 #    ${TEXT_RESOURCES}
181 #    ${QM_RESOURCES}
182 )
183
184 # The Qt5Widgets_LIBRARIES variable also includes QtGui and QtCore
185 TARGET_LINK_LIBRARIES(PartSet ${PROJECT_LIBRARIES} XGUI ModelAPI GeomAlgoAPI)
186
187 ADD_DEPENDENCIES(PartSet ModuleBase)
188
189 INSTALL(TARGETS PartSet DESTINATION ${SHAPER_INSTALL_BIN})
190 #INSTALL(FILES ${QM_RESOURCES} DESTINATION bin)