mirror of
https://github.com/opencv/opencv.git
synced 2025-01-18 14:13:15 +08:00
Merge pull request #2050 from asmorkalov:android_mk_fix2
This commit is contained in:
commit
86aabf704f
@ -44,6 +44,7 @@ if(ANDROID)
|
||||
|
||||
# build the list of opencv libs and dependencies for all modules
|
||||
set(OPENCV_MODULES_CONFIGMAKE "")
|
||||
set(OPENCV_HAVE_GPU_MODULE_CONFIGMAKE "off")
|
||||
set(OPENCV_EXTRA_COMPONENTS_CONFIGMAKE "")
|
||||
set(OPENCV_3RDPARTY_COMPONENTS_CONFIGMAKE "")
|
||||
foreach(m ${OPENCV_MODULES_PUBLIC})
|
||||
@ -68,6 +69,12 @@ if(ANDROID)
|
||||
list(REMOVE_ITEM OPENCV_MODULES_CONFIGMAKE ${OPENCV_3RDPARTY_COMPONENTS_CONFIGMAKE})
|
||||
endif()
|
||||
|
||||
# GPU module enabled separately
|
||||
list(REMOVE_ITEM OPENCV_MODULES_CONFIGMAKE "gpu")
|
||||
if(HAVE_opencv_gpu)
|
||||
set(OPENCV_HAVE_GPU_MODULE_CONFIGMAKE "on")
|
||||
endif()
|
||||
|
||||
# convert CMake lists to makefile literals
|
||||
foreach(lst OPENCV_MODULES_CONFIGMAKE OPENCV_3RDPARTY_COMPONENTS_CONFIGMAKE OPENCV_EXTRA_COMPONENTS_CONFIGMAKE)
|
||||
ocv_list_unique(${lst})
|
||||
|
@ -13,10 +13,11 @@ OPENCV_BASEDIR:=@OPENCV_BASE_INCLUDE_DIR_CONFIGCMAKE@
|
||||
OPENCV_LOCAL_C_INCLUDES:=@OPENCV_INCLUDE_DIRS_CONFIGCMAKE@
|
||||
OPENCV_MODULES:=@OPENCV_MODULES_CONFIGMAKE@
|
||||
|
||||
OPENCV_HAVE_GPU_MODULE=@OPENCV_HAVE_GPU_MODULE_CONFIGMAKE@
|
||||
OPENCV_USE_GPU_MODULE:=
|
||||
|
||||
ifeq ($(TARGET_ARCH_ABI),armeabi-v7a)
|
||||
ifneq ($(findstring gpu,$(OPENCV_MODULES)),)
|
||||
ifeq ($(OPENCV_HAVE_GPU_MODULE),on)
|
||||
ifneq ($(CUDA_TOOLKIT_DIR),)
|
||||
OPENCV_USE_GPU_MODULE:=on
|
||||
endif
|
||||
@ -114,6 +115,9 @@ ifeq ($(OPENCV_MK_$(OPENCV_TARGET_ARCH_ABI)_ALREADY_INCLUDED),)
|
||||
|
||||
ifneq ($(OPENCV_BASEDIR),)
|
||||
OPENCV_LOCAL_C_INCLUDES += $(foreach mod, $(OPENCV_MODULES), $(OPENCV_BASEDIR)/modules/$(mod)/include)
|
||||
ifeq ($(OPENCV_USE_GPU_MODULE),on)
|
||||
OPENCV_LOCAL_C_INCLUDES += $(OPENCV_BASEDIR)/modules/gpu/include
|
||||
endif
|
||||
endif
|
||||
|
||||
#turn off module installation to prevent their redefinition
|
||||
|
Loading…
Reference in New Issue
Block a user