From patchwork Sat Jul 4 19:07:01 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Martin X-Patchwork-Id: 491264 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 294A4140D19 for ; Sun, 5 Jul 2015 05:07:39 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=u/aIJdrq; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 396F1A2969; Sat, 4 Jul 2015 19:07:36 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5eB30Bh4yU3L; Sat, 4 Jul 2015 19:07:33 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 525E4A2976; Sat, 4 Jul 2015 19:07:25 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id F3B181C1F38 for ; Sat, 4 Jul 2015 19:07:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id F0FE994D33 for ; Sat, 4 Jul 2015 19:07:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id m3yHqGT0MNc7 for ; Sat, 4 Jul 2015 19:07:18 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wi0-f169.google.com (mail-wi0-f169.google.com [209.85.212.169]) by hemlock.osuosl.org (Postfix) with ESMTPS id D7D5C94CF2 for ; Sat, 4 Jul 2015 19:07:17 +0000 (UTC) Received: by wiar9 with SMTP id r9so157404495wia.1 for ; Sat, 04 Jul 2015 12:07:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=JZaASaxW9AcSBSmE6cYrg6mvr4Rmhi6DeYCrxOMXdS8=; b=u/aIJdrqHVJ9+9YPt72NIffb+b4h84++q2oi75P2W4XVmdBFiSEJGRkS7DJFpz+WIP IJ6KXq4uq0nhL79C32U0wixeVtjzbyvPe5xJRyL/jHXodc7Q2LMBG1rATRy/KBBfgU2s d4tyWir8YwwkAleyxKEdLpD+4o4d8SZXF7Te5sKzfT8S9RIWH2WJu9QyIIUPpRVTXrDh LLdUoR7M/u7bfawqU27K5Jmj2it5mHm1Wvx9suhNISCuMeYKeky64jw0stvcZMrOmZVv Zes9qqWJCDeenIpd/TJdsChsTqF+m5uDITIsWfW4/KJ3eHwDs/Wk6DORhH1INOjaAWEh iu/g== X-Received: by 10.180.24.65 with SMTP id s1mr36545470wif.66.1436036836371; Sat, 04 Jul 2015 12:07:16 -0700 (PDT) Received: from bobook.localdomain (ivr94-4-82-229-165-48.fbx.proxad.net. [82.229.165.48]) by mx.google.com with ESMTPSA id ck18sm19278448wjb.47.2015.07.04.12.07.15 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 04 Jul 2015 12:07:15 -0700 (PDT) From: Samuel Martin To: buildroot@buildroot.org Date: Sat, 4 Jul 2015 21:07:01 +0200 Message-Id: <1436036821-10073-8-git-send-email-s.martin49@gmail.com> X-Mailer: git-send-email 2.4.5 In-Reply-To: <1436036821-10073-1-git-send-email-s.martin49@gmail.com> References: <1436036821-10073-1-git-send-email-s.martin49@gmail.com> Subject: [Buildroot] [PATCH v7 7/7] package/vlc: add opencv support X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" This change adds 2 patches (backported from upstream) to vlc fixing the build against opencv2 APIs. This allows to select the minimal set of opencv modules when opencv support is enabled. Signed-off-by: Samuel Martin Reviewed-by: "Yann E. MORIN" --- changes v5->v6: - update a/r/t tags - add backport url (Yann) changes v4->v5: - new patch --- ...opencv_wrapper-use-opencv2-style-includes.patch | 36 ++++++++++++++++++++++ ...cv_example-add-missing-include-statements.patch | 29 +++++++++++++++++ package/vlc/Config.in | 2 ++ package/vlc/vlc.mk | 8 ++++- 4 files changed, 74 insertions(+), 1 deletion(-) create mode 100644 package/vlc/0008-opencv_wrapper-use-opencv2-style-includes.patch create mode 100644 package/vlc/0009-opencv_example-add-missing-include-statements.patch diff --git a/package/vlc/0008-opencv_wrapper-use-opencv2-style-includes.patch b/package/vlc/0008-opencv_wrapper-use-opencv2-style-includes.patch new file mode 100644 index 0000000..0ce0206 --- /dev/null +++ b/package/vlc/0008-opencv_wrapper-use-opencv2-style-includes.patch @@ -0,0 +1,36 @@ +Backport from: https://git.videolan.org/?p=vlc.git;a=commit;h=cc236e4652255902f2c2cee3b18f83367f35a8c7 + +From cc236e4652255902f2c2cee3b18f83367f35a8c7 Mon Sep 17 00:00:00 2001 +From: Samuel Martin +Date: Sun, 24 May 2015 14:30:09 +0200 +Subject: [PATCH 8/9] opencv_wrapper: use opencv2-style includes + +If old opencv1-style legacy include directory is available, this change +becomes purely cosmetic (maybe will compile a bit faster). +It becomes an FTBFS fix when opencv1-style include directory is missing +(i.e. from opencv-3.0). + +Signed-off-by: Samuel Martin +Signed-off-by: Jean-Baptiste Kempf +--- + modules/video_filter/opencv_wrapper.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/modules/video_filter/opencv_wrapper.c b/modules/video_filter/opencv_wrapper.c +index e36e1a5..5d74241 100644 +--- a/modules/video_filter/opencv_wrapper.c ++++ b/modules/video_filter/opencv_wrapper.c +@@ -39,8 +39,8 @@ + #include + #include "filter_picture.h" + +-#include +-#include ++#include ++#include + + /***************************************************************************** + * Local prototypes +-- +2.4.2 + diff --git a/package/vlc/0009-opencv_example-add-missing-include-statements.patch b/package/vlc/0009-opencv_example-add-missing-include-statements.patch new file mode 100644 index 0000000..7b7f727 --- /dev/null +++ b/package/vlc/0009-opencv_example-add-missing-include-statements.patch @@ -0,0 +1,29 @@ +Backport from: https://git.videolan.org/?p=vlc.git;a=commit;h=b82416d7000a993b33e903095a590fe32212a85e + +From b82416d7000a993b33e903095a590fe32212a85e Mon Sep 17 00:00:00 2001 +From: Samuel Martin +Date: Sun, 24 May 2015 14:30:10 +0200 +Subject: [PATCH 9/9] opencv_example: add missing #include statements + +Signed-off-by: Samuel Martin +Signed-off-by: Jean-Baptiste Kempf +--- + modules/video_filter/opencv_example.cpp | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/modules/video_filter/opencv_example.cpp b/modules/video_filter/opencv_example.cpp +index ae3af05..998f286 100644 +--- a/modules/video_filter/opencv_example.cpp ++++ b/modules/video_filter/opencv_example.cpp +@@ -41,6 +41,8 @@ + + #include + #include ++#include ++#include + #include + + /***************************************************************************** +-- +2.4.2 + diff --git a/package/vlc/Config.in b/package/vlc/Config.in index b030a56..471f4a7 100644 --- a/package/vlc/Config.in +++ b/package/vlc/Config.in @@ -11,6 +11,8 @@ config BR2_PACKAGE_VLC depends on BR2_TOOLCHAIN_HAS_THREADS depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_7 select BR2_PACKAGE_LIBVORBIS if BR2_PACKAGE_OPUS + select BR2_PACKAGE_OPENCV_LIB_IMGPROC if BR2_PACKAGE_OPENCV + select BR2_PACKAGE_OPENCV_LIB_OBJDETECT if BR2_PACKAGE_OPENCV help VLC is a free and open source cross-platform multimedia player and framework that plays most multimedia files as well as DVD, diff --git a/package/vlc/vlc.mk b/package/vlc/vlc.mk index 4ef69aa..a553648 100644 --- a/package/vlc/vlc.mk +++ b/package/vlc/vlc.mk @@ -44,7 +44,6 @@ VLC_CONF_OPTS += \ --disable-projectm \ --disable-vsxu \ --disable-mtp \ - --disable-opencv \ --disable-mmal-codec \ --disable-mmal-vout \ --disable-dvdnav \ @@ -148,6 +147,13 @@ else VLC_CONF_OPTS += --disable-gles2 endif +ifeq ($(BR2_PACKAGE_OPENCV),y) +VLC_CONF_OPTS += --enable-opencv +VLC_DEPENDENCIES += opencv +else +VLC_CONF_OPTS += --disable-opencv +endif + ifeq ($(BR2_PACKAGE_OPUS),y) VLC_CONF_OPTS += --enable-opus VLC_DEPENDENCIES += libvorbis opus