Salome HOME
Issue #2059 point in sketch is created not on selected line of external sketchPlane...
[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 )
42
43 SET(PROJECT_SOURCES
44     GeomAPI_Circ.cpp
45     GeomAPI_Circ2d.cpp
46     GeomAPI_Interface.cpp
47     GeomAPI_XY.cpp
48     GeomAPI_XYZ.cpp
49     GeomAPI_Pnt.cpp
50     GeomAPI_Pnt2d.cpp
51     GeomAPI_Lin.cpp
52     GeomAPI_Lin2d.cpp
53     GeomAPI_Dir.cpp
54     GeomAPI_Dir2d.cpp
55     GeomAPI_Pln.cpp
56     GeomAPI_Shape.cpp
57     GeomAPI_ShapeExplorer.cpp
58     GeomAPI_ShapeIterator.cpp
59     GeomAPI_Edge.cpp
60     GeomAPI_Face.cpp
61     GeomAPI_PlanarEdges.cpp
62     GeomAPI_AISObject.cpp
63     GeomAPI_Curve.cpp
64     GeomAPI_DataMapOfShapeMapOfShapes.cpp
65     GeomAPI_DataMapOfShapeShape.cpp
66     GeomAPI_Vertex.cpp
67     GeomAPI_ICustomPrs.cpp
68     GeomAPI_Ax1.cpp
69     GeomAPI_Ax2.cpp
70     GeomAPI_Ax3.cpp
71     GeomAPI_IPresentable.cpp
72     GeomAPI_Trsf.cpp
73     GeomAPI_Angle2d.cpp
74     GeomAPI_Wire.cpp
75 )
76
77 SET(PROJECT_LIBRARIES
78     ${CAS_KERNEL}
79     ${CAS_MODELER}
80     ${CAS_VIEWER}
81     ${CAS_SHAPE}
82     ${CAS_TKTopAlgo}
83     ${CAS_TKBO}
84 )
85
86 ADD_DEFINITIONS(-DGEOMAPI_EXPORTS ${CAS_DEFINITIONS})
87 ADD_LIBRARY(GeomAPI SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS})
88
89 SET(CMAKE_SWIG_FLAGS -threads -Wall)
90
91 SET_SOURCE_FILES_PROPERTIES(GeomAPI.i PROPERTIES CPLUSPLUS ON)
92 SET_SOURCE_FILES_PROPERTIES(GeomAPI.i PROPERTIES SWIG_DEFINITIONS "-shadow")
93
94 INCLUDE_DIRECTORIES(
95   ${CAS_INCLUDE_DIRS}
96 )
97
98 TARGET_LINK_LIBRARIES(GeomAPI ${PROJECT_LIBRARIES})
99
100 SET(SWIG_SCRIPTS
101   ${CMAKE_CURRENT_BINARY_DIR}/GeomAPI.py
102 )
103
104 SET(SWIG_LINK_LIBRARIES
105   GeomAPI
106   ${PYTHON_LIBRARIES}
107 )
108
109 SWIG_ADD_MODULE(GeomAPI python GeomAPI.i ${PROJECT_HEADERS})
110 SWIG_LINK_LIBRARIES(GeomAPI ${SWIG_LINK_LIBRARIES})
111
112 IF(WIN32)
113   SET_TARGET_PROPERTIES(_GeomAPI PROPERTIES DEBUG_OUTPUT_NAME _GeomAPI_d)
114 ENDIF(WIN32)
115
116 INSTALL(TARGETS _GeomAPI DESTINATION ${SHAPER_INSTALL_SWIG})
117 INSTALL(TARGETS GeomAPI DESTINATION ${SHAPER_INSTALL_BIN})
118 INSTALL(FILES ${SWIG_SCRIPTS} DESTINATION ${SHAPER_INSTALL_SWIG})