From 3aaf8dfd1120599e1a73b4a4b2d8ff75343d8b00 Mon Sep 17 00:00:00 2001 From: Nicolae Rosia Date: Wed, 30 Jan 2019 17:43:23 +0200 Subject: [PATCH] cmake: allow FFmpeg linking on Android details: https://github.com/opencv/opencv/pull/13726 In order to help CMake and PkgConfig find FFmpeg you need to: 1) export `PKG_CONFIG_LIBDIR=${SYSROOT}` where `SYSROOT=${ANDROID_NDK}/sysroot` 2) Add `-DCMAKE_PREFIX_PATH=${FFMPEG_INSTALL_PREFIX}` 3) Append `-DCMAKE_FIND_ROOT_PATH=${FFMPEG_INSTALL_PREFIX}` --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 930e48c787..641594b00c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -255,8 +255,8 @@ OCV_OPTION(WITH_EIGEN "Include Eigen2/Eigen3 support" (NOT CV_DISABLE_OPTIMIZATI OCV_OPTION(WITH_VFW "Include Video for Windows support (deprecated, consider using MSMF)" OFF VISIBLE_IF WIN32 VERIFY HAVE_VFW) -OCV_OPTION(WITH_FFMPEG "Include FFMPEG support" ON - VISIBLE_IF NOT ANDROID AND NOT IOS AND NOT WINRT +OCV_OPTION(WITH_FFMPEG "Include FFMPEG support" (NOT ANDROID) + VISIBLE_IF NOT IOS AND NOT WINRT VERIFY HAVE_FFMPEG) OCV_OPTION(WITH_GSTREAMER "Include Gstreamer support" ON VISIBLE_IF NOT ANDROID AND NOT IOS AND NOT WINRT