Salome HOME
Avoid direct link to SketchPlugin
[modules/shaper.git] / src / PartSet / CMakeLists.txt
1 INCLUDE(Common)
2
3 SET(CMAKE_AUTOMOC ON)
4
5 SET(PROJECT_HEADERS
6         PartSet.h
7         PartSet_Constants.h
8         PartSet_EditLine.h
9         PartSet_Listener.h
10         PartSet_Module.h
11         PartSet_OperationFeatureCreate.h
12         PartSet_OperationFeatureEdit.h
13         PartSet_OperationFeatureEditMulti.h
14         PartSet_OperationSketchBase.h
15         PartSet_OperationSketch.h
16         PartSet_OperationFeatureBase.h
17         PartSet_TestOCC.h
18         PartSet_Tools.h
19         PartSet_WidgetSketchLabel.h
20         PartSet_Validators.h
21 )
22
23 SET(PROJECT_SOURCES
24         PartSet_EditLine.cpp
25         PartSet_Listener.cpp
26         PartSet_Module.cpp
27         PartSet_OperationFeatureCreate.cpp
28         PartSet_OperationFeatureEdit.cpp
29         PartSet_OperationFeatureEditMulti.cpp
30         PartSet_OperationSketchBase.cpp
31         PartSet_OperationSketch.cpp
32         PartSet_OperationFeatureBase.cpp
33         PartSet_TestOCC.cpp
34         PartSet_Tools.cpp
35         PartSet_WidgetSketchLabel.cpp
36         PartSet_Validators.cpp
37 )
38
39 SET(PROJECT_RESOURCES 
40     PartSet_icons.qrc
41 )
42
43 #SET(TEXT_RESOURCES
44 #       PartSet_msg_fr.ts
45 #)
46
47 SET(PROJECT_LIBRARIES
48     ModuleBase
49     Config
50     GeomAPI
51     ${QT_LIBRARIES}
52     ${CAS_KERNEL}
53 )
54
55 SET(PROJECT_AUTOMOC 
56     ${CMAKE_CURRENT_BINARY_DIR}/PartSet_automoc.cpp
57 )
58
59 QT4_ADD_RESOURCES(PROJECT_COMPILED_RESOURCES ${PROJECT_RESOURCES})
60 #QT4_ADD_TRANSLATION(QM_RESOURCES ${TEXT_RESOURCES})
61 #QT4_CREATE_TRANSLATION(QM_RESOURCES 
62 #                                          ${PROJECT_SOURCES}
63 #                                          ${TEXT_RESOURCES}
64 #                                          OPTIONS -extensions cpp -no-recursive
65 #                                          )
66
67 #SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES} ${QM_RESOURCES})
68 SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES})
69 #SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES} ${PROJECT_RESOURCES})
70 SOURCE_GROUP ("Resource Files" FILES ${PROJECT_RESOURCES})
71
72 INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/src/XGUI 
73                     ${CMAKE_SOURCE_DIR}/src/Config
74                     ${CMAKE_SOURCE_DIR}/src/Events
75                     ${CMAKE_SOURCE_DIR}/src/ModuleBase
76                     ${CMAKE_SOURCE_DIR}/src/ModelAPI
77                     ${CMAKE_SOURCE_DIR}/src/GeomDataAPI
78                     ${CMAKE_SOURCE_DIR}/src/GeomAlgoAPI
79                     ${CMAKE_SOURCE_DIR}/src/SketchPlugin
80                     ${CMAKE_SOURCE_DIR}/src/GeomAPI
81                     ${CAS_INCLUDE_DIRS}
82                                         ${SUIT_INCLUDE}
83 )
84
85 ADD_DEFINITIONS(-DPARTSET_EXPORTS ${CAS_DEFINITIONS})
86 ADD_LIBRARY(PartSet SHARED 
87         ${PROJECT_SOURCES} 
88         ${PROJECT_HEADERS} 
89         ${PROJECT_COMPILED_RESOURCES} 
90 #       ${TEXT_RESOURCES} 
91 #       ${QM_RESOURCES}
92 )
93
94 # The Qt5Widgets_LIBRARIES variable also includes QtGui and QtCore
95 TARGET_LINK_LIBRARIES(PartSet ${PROJECT_LIBRARIES} XGUI ModelAPI GeomAlgoAPI)
96
97 ADD_DEPENDENCIES(PartSet ModuleBase)
98
99 INSTALL(TARGETS PartSet DESTINATION bin)
100 #INSTALL(FILES ${QM_RESOURCES} DESTINATION bin)