Limited API support for Python3

This commit is contained in:
Maksim Shabunin
2019-03-21 10:45:02 +03:00
parent 3f67623c26
commit d60ac98ef2
8 changed files with 636 additions and 497 deletions

View File

@@ -2,6 +2,14 @@ if(NOT PYTHON3_INCLUDE_PATH OR NOT PYTHON3_NUMPY_INCLUDE_DIRS)
ocv_module_disable(python3)
endif()
# Problem in numpy >=1.15 <1.17
if(PYTHON3_LIMITED_API
AND NOT PYTHON3_NUMPY_VERSION VERSION_LESS "1.15"
AND PYTHON3_NUMPY_VERSION VERSION_LESS "1.17"
)
set(PYTHON3_LIMITED_API OFF)
endif()
set(the_description "The python3 bindings")
set(MODULE_NAME python3)
set(MODULE_INSTALL_SUBDIR python3)