|
@@ -3,3 +3,20 @@ add_library (hmc5883l SHARED hmc5883l.cxx)
|
3
|
3
|
include_directories (${MAA_INCLUDE_DIR})
|
4
|
4
|
|
5
|
5
|
target_link_libraries (hmc5883l ${MAA_LIBRARIES})
|
|
6
|
+
|
|
7
|
+find_package (PythonLibs)
|
|
8
|
+
|
|
9
|
+include_directories (
|
|
10
|
+ ${PYTHON_INCLUDE_PATH}
|
|
11
|
+ ${PYTHON_INCLUDE_DIRS}
|
|
12
|
+ ${MAA_INCLUDE_DIR}
|
|
13
|
+ .
|
|
14
|
+)
|
|
15
|
+
|
|
16
|
+set_source_files_properties (pyupm_hmc5883l.i PROPERTIES CPLUSPLUS ON)
|
|
17
|
+set_source_files_properties (jsupm_hmc5883l.i PROPERTIES CPLUSPLUS ON)
|
|
18
|
+
|
|
19
|
+swig_add_module (pyupm_hmc5883l python pyupm_hmc5883l.i hmc5883l.cxx)
|
|
20
|
+swig_add_module (jsupm_hmc5883l python jsupm_hmc5883l.i hmc5883l.cxx)
|
|
21
|
+swig_link_libraries (pyupm_hmc5883l ${PYTHON_LIBRARIES} ${MAA_LIBRARIES})
|
|
22
|
+swig_link_libraries (jsupm_hmc5883l ${PYTHON_LIBRARIES} ${MAA_LIBRARIES})
|