Salome HOME
Add ellipse data type
[modules/shaper.git] / src / GeomAPI / CMakeLists.txt
1 ## Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 FIND_PACKAGE(SWIG REQUIRED)
4
5 INCLUDE(${SWIG_USE_FILE})
6 INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR})
7
8 SET(PROJECT_HEADERS
9     GeomAPI.h
10     GeomAPI_Circ.h
11     GeomAPI_Circ2d.h
12     GeomAPI_Interface.h
13     GeomAPI_XY.h
14     GeomAPI_XYZ.h
15     GeomAPI_Pnt.h
16     GeomAPI_Pnt2d.h
17     GeomAPI_Lin.h
18     GeomAPI_Lin2d.h
19     GeomAPI_Dir.h
20     GeomAPI_Dir2d.h
21     GeomAPI_Pln.h
22     GeomAPI_Shape.h
23     GeomAPI_ShapeExplorer.h
24     GeomAPI_ShapeIterator.h
25     GeomAPI_Edge.h
26     GeomAPI_Face.h
27     GeomAPI_PlanarEdges.h
28     GeomAPI_AISObject.h
29     GeomAPI_IPresentable.h
30     GeomAPI_Curve.h
31     GeomAPI_DataMapOfShapeMapOfShapes.h
32     GeomAPI_DataMapOfShapeShape.h
33     GeomAPI_ICustomPrs.h
34     GeomAPI_Vertex.h
35     GeomAPI_Ax1.h
36     GeomAPI_Ax2.h
37     GeomAPI_Ax3.h
38     GeomAPI_Trsf.h
39     GeomAPI_Angle2d.h
40     GeomAPI_Wire.h
41         GeomAPI_Ellipse.h
42 )
43
44 SET(PROJECT_SOURCES
45     GeomAPI_Circ.cpp
46     GeomAPI_Circ2d.cpp
47     GeomAPI_Interface.cpp
48     GeomAPI_XY.cpp
49     GeomAPI_XYZ.cpp
50     GeomAPI_Pnt.cpp
51     GeomAPI_Pnt2d.cpp
52     GeomAPI_Lin.cpp
53     GeomAPI_Lin2d.cpp
54     GeomAPI_Dir.cpp
55     GeomAPI_Dir2d.cpp
56     GeomAPI_Pln.cpp
57     GeomAPI_Shape.cpp
58     GeomAPI_ShapeExplorer.cpp
59     GeomAPI_ShapeIterator.cpp
60     GeomAPI_Edge.cpp
61     GeomAPI_Face.cpp
62     GeomAPI_PlanarEdges.cpp
63     GeomAPI_AISObject.cpp
64     GeomAPI_Curve.cpp
65     GeomAPI_DataMapOfShapeMapOfShapes.cpp
66     GeomAPI_DataMapOfShapeShape.cpp
67     GeomAPI_Vertex.cpp
68     GeomAPI_ICustomPrs.cpp
69     GeomAPI_Ax1.cpp
70     GeomAPI_Ax2.cpp
71     GeomAPI_Ax3.cpp
72     GeomAPI_IPresentable.cpp
73     GeomAPI_Trsf.cpp
74     GeomAPI_Angle2d.cpp
75     GeomAPI_Wire.cpp
76         GeomAPI_Ellipse.cpp
77 )
78
79 SET(PROJECT_LIBRARIES
80     ${CAS_KERNEL}
81     ${CAS_MODELER}
82     ${CAS_VIEWER}
83     ${CAS_SHAPE}
84     ${CAS_TKTopAlgo}
85     ${CAS_TKBO}
86 )
87
88 ADD_DEFINITIONS(-DGEOMAPI_EXPORTS ${CAS_DEFINITIONS})
89 ADD_LIBRARY(GeomAPI SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS})
90
91 SET(CMAKE_SWIG_FLAGS -threads -Wall)
92
93 SET_SOURCE_FILES_PROPERTIES(GeomAPI.i PROPERTIES CPLUSPLUS ON)
94 SET_SOURCE_FILES_PROPERTIES(GeomAPI.i PROPERTIES SWIG_DEFINITIONS "-shadow")
95
96 INCLUDE_DIRECTORIES(
97   ${CAS_INCLUDE_DIRS}
98 )
99
100 TARGET_LINK_LIBRARIES(GeomAPI ${PROJECT_LIBRARIES})
101
102 SET(SWIG_SCRIPTS
103   ${CMAKE_CURRENT_BINARY_DIR}/GeomAPI.py
104 )
105
106 SET(SWIG_LINK_LIBRARIES
107   GeomAPI
108   ${PYTHON_LIBRARIES}
109 )
110
111 SWIG_ADD_MODULE(GeomAPI python GeomAPI.i ${PROJECT_HEADERS})
112 SWIG_LINK_LIBRARIES(GeomAPI ${SWIG_LINK_LIBRARIES})
113
114 IF(WIN32)
115   SET_TARGET_PROPERTIES(_GeomAPI PROPERTIES DEBUG_OUTPUT_NAME _GeomAPI_d)
116 ENDIF(WIN32)
117
118 INSTALL(TARGETS _GeomAPI DESTINATION ${SHAPER_INSTALL_SWIG})
119 INSTALL(TARGETS GeomAPI DESTINATION ${SHAPER_INSTALL_BIN})
120 INSTALL(FILES ${SWIG_SCRIPTS} DESTINATION ${SHAPER_INSTALL_SWIG})