Salome HOME
be036a0a64d3eeecd13828f895b7b70f09ad72d7
[modules/shaper.git] / src / BuildPlugin / CMakeLists.txt
1 # Copyright (C) 2014-2020  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 email : webmaster.salome@opencascade.com
18 #
19
20 INCLUDE(Common)
21 INCLUDE(UnitTest)
22
23 INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/Events
24                     ${PROJECT_SOURCE_DIR}/src/Config
25                     ${PROJECT_SOURCE_DIR}/src/ModelAPI
26                     ${PROJECT_SOURCE_DIR}/src/Locale
27                     ${PROJECT_SOURCE_DIR}/src/GeomAPI
28                     ${PROJECT_SOURCE_DIR}/src/GeomAlgoAPI
29                     ${PROJECT_SOURCE_DIR}/src/GeomDataAPI
30                     ${PROJECT_SOURCE_DIR}/src/GeomValidators
31                     ${PROJECT_SOURCE_DIR}/src/SketchPlugin
32                     ${PROJECT_SOURCE_DIR}/src/InitializationPlugin
33                     ${SUIT_INCLUDE}
34                     ${PYTHON_INCLUDE_DIR}
35 )
36
37 SET(PROJECT_HEADERS
38     BuildPlugin.h
39     BuildPlugin_Plugin.h
40     BuildPlugin_Shape.h
41     BuildPlugin_Vertex.h
42     BuildPlugin_Edge.h
43     BuildPlugin_Wire.h
44     BuildPlugin_Polyline.h
45     BuildPlugin_Interpolation.h
46     BuildPlugin_Face.h
47     BuildPlugin_Shell.h
48     BuildPlugin_Solid.h
49     BuildPlugin_CompSolid.h
50     BuildPlugin_Compound.h
51     BuildPlugin_SubShapes.h
52     BuildPlugin_Filling.h
53     BuildPlugin_Validators.h
54 )
55
56 SET(PROJECT_SOURCES
57     BuildPlugin_Plugin.cpp
58     BuildPlugin_Shape.cpp
59     BuildPlugin_Vertex.cpp
60     BuildPlugin_Edge.cpp
61     BuildPlugin_Wire.cpp
62     BuildPlugin_Polyline.cpp
63     BuildPlugin_Interpolation.cpp
64     BuildPlugin_Face.cpp
65     BuildPlugin_Shell.cpp
66     BuildPlugin_Solid.cpp
67     BuildPlugin_CompSolid.cpp
68     BuildPlugin_Compound.cpp
69     BuildPlugin_SubShapes.cpp
70     BuildPlugin_Filling.cpp
71     BuildPlugin_Validators.cpp
72 )
73
74 SET(XML_RESOURCES
75     plugin-Build.xml
76     vertex_widget.xml
77     edge_widget.xml
78     wire_widget.xml
79     polyline_widget.xml
80     interpolation_widget.xml
81     face_widget.xml
82     shell_widget.xml
83     solid_widget.xml
84     compsolid_widget.xml
85     compound_widget.xml
86     subshapes_widget.xml
87     filling_widget.xml
88 )
89
90 SET(TEXT_RESOURCES
91     BuildPlugin_msg_en.ts
92     BuildPlugin_msg_fr.ts
93 )
94
95 SOURCE_GROUP ("XML Files" FILES ${XML_RESOURCES})
96 SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES})
97
98 SET(PROJECT_LIBRARIES
99     Events
100     Config
101     ModelAPI
102     GeomAPI
103     GeomAlgoAPI
104     GeomValidators
105     ${PyInterp}
106     ${PYTHON_LIBRARIES}
107 )
108
109 ADD_DEFINITIONS(-DBUILDPLUGIN_EXPORTS)
110 ADD_LIBRARY(BuildPlugin MODULE ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${XML_RESOURCES} ${TEXT_RESOURCES})
111
112 TARGET_LINK_LIBRARIES(BuildPlugin ${PROJECT_LIBRARIES})
113
114 INSTALL(TARGETS BuildPlugin DESTINATION ${SHAPER_INSTALL_PLUGIN_FILES})
115 INSTALL(FILES ${XML_RESOURCES} ${TEXT_RESOURCES} DESTINATION ${SHAPER_INSTALL_XML_RESOURCES})
116 INSTALL(DIRECTORY icons/ DESTINATION ${SHAPER_INSTALL_XML_RESOURCES}/icons/Build)
117
118 ADD_UNIT_TESTS(TestVertex.py
119                TestVertex_ErrorMsg.py
120                TestVertex_WholeSketch_1.py
121                TestVertex_WholeSketch_2.py
122                TestEdge.py
123                TestEdge_ByPoints.py
124                TestEdge_ErrorMsg.py
125                TestEdge_WholeSketch_1.py
126                TestEdge_WholeSketch_2.py
127                TestEdge_WholeSketch_3.py
128                TestEdge_WholeSketch_4.py
129                TestWire.py
130                TestWire_ErrorMsg.py
131                TestWire_WholeSketch_1.py
132                TestWire_WholeSketch_2.py
133                TestWire_WholeSketch_3.py
134                TestWire_WholeSketch_4.py
135                TestWire_WholeSketch_5.py
136                TestWire_WholeSketch_6.py
137                TestPolyline.py
138                TestInterpolation.py
139                TestFace.py
140                TestFace_ErrorMsg.py
141                TestFace_WholeSketch_1.py
142                TestFace_WholeSketch_2.py
143                TestShell.py
144                TestShell_WholeSketch_1.py
145                TestShell_WholeSketch_2.py
146                TestSolid.py
147                TestSolid_ErrorMsg.py
148                TestCompSolid.py
149                TestCompound.py
150                TestCompound_ErrorMsg.py
151                TestCompound_History.py
152                TestSubShapes.py
153                TestSubShapes_ErrorMsg.py
154                TestFilling.py
155                TestFilling_ByEdges.py
156                TestFilling_ByWires.py
157                TestFilling_Mixed.py
158                TestFilling_ErrorMsg.py
159                Test1920.py
160                Test2398.py
161                Test2409.py
162                Test2415.py
163                Test2439.py
164                Test2454.py
165                Test3125.py
166                Test3271.py
167                Test19056.py
168                Test20469.py
169                Test20513_1.py
170                Test20513_2.py
171 )