[Midnightbsd-cvs] mports [16689] trunk/graphics/opencv: new options

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Fri Aug 29 16:02:50 EDT 2014


Revision: 16689
          http://svnweb.midnightbsd.org/mports/?rev=16689
Author:   laffer1
Date:     2014-08-29 16:02:50 -0400 (Fri, 29 Aug 2014)
Log Message:
-----------
new options

Modified Paths:
--------------
    trunk/graphics/opencv/Makefile

Added Paths:
-----------
    trunk/graphics/opencv/files/patch-modules__ts__include__opencv2__ts__ts_gtest.h
    trunk/graphics/opencv/files/patch-samples_cpp_bagofwords_classification.cpp

Modified: trunk/graphics/opencv/Makefile
===================================================================
--- trunk/graphics/opencv/Makefile	2014-08-29 20:02:04 UTC (rev 16688)
+++ trunk/graphics/opencv/Makefile	2014-08-29 20:02:50 UTC (rev 16689)
@@ -3,7 +3,7 @@
 
 PORTNAME?=	opencv
 PORTVERSION=	2.3.1
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	graphics
 MASTER_SITES=	SF/${PORTNAME}library/${PORTNAME}-unix/${PORTVERSION}
 DISTNAME=	OpenCV-${DISTVERSION}a
@@ -12,7 +12,7 @@
 COMMENT=	Open Source Computer Vision library from Intel
 LICENSE=	bsd3
 
-USESE=		pkgconfig
+USES=		pkgconfig
 WANT_GSTREAMER=	yes
 MAKE_JOBS_UNSAFE=	yes
 USE_BZIP2=	yes
@@ -27,35 +27,36 @@
 DATADIR=	${PREFIX}/share/OpenCV
 PLIST_SUB+=	VERSION=${DISTVERSION}
 
+_COMPVERSION!= ${CC} --version
+.if ${_COMPVERSION:Mclang}
+USE_CXXSTD=	gnu++11
+CXXFLAGS+=	-Wno-error -Wno-c++11-narrowing
+.endif
+
 .if !defined(_BUILDING_OPENCV_CORE) && !defined(_BUILDING_OPENCV_PYTHON)
 EXTRA_PATCHES+=	${FILESDIR}/extra-patch-opencv
 LIB_DEPENDS+=	opencv_core.2:${PORTSDIR}/graphics/opencv-core
-LDFLAGS+=	-L${LOCALBASE}/lib
+LDFLAGS+=	-L${LOCALBASE}/lib -lopencv_core
 
 PORTDOCS=	*
 
-OPTIONS=	EIGEN2	"Include Eigen 2 support" on \
-		FFMPEG	"Include FFmpeg support" off \
-		GSTREAMER	"Include Gstreamer support" off \
-		GTK	"Include GTK+ support" off \
-		JASPER	"Include JPEG 2000 support" on \
-		JPEG	"Include JPEG support" on \
-		OPENEXR	"Include OpenEXR support" off \
-		PNG	"Include PNG support" on \
-		QT4	"Build with Qt backend support" off \
-		TBB	"Include TBB support" off \
-		TIFF	"Include TIFF support" on \
-		V4L	"Include Video4Linux support" on \
-		XINE	"Include XINE support" off
+OPTIONS_DEFINE=	EIGEN2 FFMPEG GSTREAMER GTK JASPER JPEG OPENEXR PNG \
+		QT4 TBB TIFF V4L XINE EXAMPLES
+EIGEN2_DESC=	Eigen 2 support
+GTK_DESC=	GTK+ support
+OPENEXR_DESC=	OpenEXR support
+TBB_DESC=	TBB support
 
+OPTIONS_DEFAULT=	EIGEN2 JASPER JPEG PNG TIFF V4L
+
 .include <bsd.mport.options.mk>
 
-.if !defined(NOPORTEXAMPLES)
+.if ${PORT_OPTIONS:MEXAMPLES}
 CMAKE_ARGS+=	-DBUILD_EXAMPLES:BOOL=On -DINSTALL_C_EXAMPLES:BOOL=On
 PORTEXAMPLES+=	c cpp gpu
 .endif
 
-.if !defined(WITHOUT_EIGEN2)
+.if ${PORT_OPTIONS:MEIGEN2}
 BUILD_DEPENDS+=	${LOCALBASE}/include/eigen2/Eigen/Eigen:${PORTSDIR}/math/eigen2
 CMAKE_ARGS+=	-DWITH_EIGEN2:BOOL=On
 .else
@@ -62,7 +63,7 @@
 CMAKE_ARGS+=	-DDWITH_EIGEN2:BOOL=Off
 .endif
 
-.if defined(WITH_FFMPEG)
+.if ${PORT_OPTIONS:MFFMPEG}
 LIB_DEPENDS+=	avcodec.1:${PORTSDIR}/multimedia/ffmpeg
 CMAKE_ARGS+=	-DWITH_FFMPEG:BOOL=On
 .else
@@ -69,7 +70,7 @@
 CMAKE_ARGS+=	-DWITH_FFMPEG:BOOL=Off
 .endif
 
-.if defined(WITH_GSTREAMER)
+.if ${PORT_OPTIONS:MGSTREAMER}
 USE_GSTREAMER=	yes
 CMAKE_ARGS+=	-DWITH_GSTREAMER:BOOL=On
 .else
@@ -76,7 +77,7 @@
 CMAKE_ARGS+=	-DWITH_GSTREAMER:BOOL=Off
 .endif
 
-.if defined(WITH_GTK)
+.if ${PORT_OPTIONS:MGTK}
 USE_GNOME=	gtk20
 CMAKE_ARGS+=	-DWITH_GTK:BOOL=On
 .else
@@ -83,7 +84,7 @@
 CMAKE_ARGS+=	-DWITH_GTK:BOOL=Off
 .endif
 
-.if !defined(WITHOUT_JASPER)
+.if ${PORT_OPTIONS:MJASPER}
 LIB_DEPENDS+=	jasper.4:${PORTSDIR}/graphics/jasper
 CMAKE_ARGS+=	-DWITH_JASPER:BOOL=On
 .else
@@ -90,7 +91,7 @@
 CMAKE_ARGS+=	-DWITH_JASPER:BOOL=Off
 .endif
 
-.if !defined(WITHOUT_JPEG)
+.if ${PORT_OPTIONS:MJPEG}
 LIB_DEPENDS+=	jpeg.11:${PORTSDIR}/graphics/jpeg
 CMAKE_ARGS+=	-DWITH_JPEG:BOOL=On
 .else
@@ -97,7 +98,7 @@
 CMAKE_ARGS+=	-DWITH_JPEG:BOOL=Off
 .endif
 
-.if defined(WITH_OPENEXR)
+.if ${PORT_OPTIONS:MOPENEXR}
 LIB_DEPENDS+=	IlmImf:${PORTSDIR}/graphics/OpenEXR
 CMAKE_ARGS+=	-DWITH_OPENEXR:BOOL=On
 .else
@@ -104,7 +105,7 @@
 CMAKE_ARGS+=	-DWITH_OPENEXR:BOOL=Off
 .endif
 
-.if !defined(WITHOUT_PNG)
+.if ${PORT_OPTIONS:MPNG}
 LIB_DEPENDS+=	png15:${PORTSDIR}/graphics/png
 CMAKE_ARGS+=	-DWITH_PNG:BOOL=On
 .else
@@ -111,7 +112,7 @@
 CMAKE_ARGS+=	-DWITH_PNG:BOOL=Off
 .endif
 
-.if defined(WITH_QT4)
+.if ${PORT_OPTIONS:MQT4}
 USE_QT4+=	opengl moc_build qmake_build rcc_build uic_build qtestlib
 CMAKE_ARGS+=	-DWITH_QT:BOOL=On -DWITH_QT_OPENGL:BOOL=On
 .else
@@ -118,7 +119,7 @@
 CMAKE_ARGS+=	-DWITH_QT:BOOL=Off
 .endif
 
-.if defined(WITH_TBB)
+.if ${PORT_OPTIONS:MTBB}
 LIB_DEPENDS+=	tbb.4:${PORTSDIR}/devel/tbb
 CMAKE_ARGS+=	-DWITH_TBB:BOOL=On \
 		-DTBBLIB_FOUND:BOOL=1 -DTBB_FOUND:BOOL=On \
@@ -129,7 +130,7 @@
 CMAKE_ARGS+=	-DWITH_TBB:BOOL=Off
 .endif
 
-.if !defined(WITHOUT_TIFF)
+.if ${PORT_OPTIONS:MTIFF}
 LIB_DEPENDS+=	tiff.4:${PORTSDIR}/graphics/tiff
 CMAKE_ARGS+=	-DWITH_TIFF:BOOL=On
 .else
@@ -136,7 +137,7 @@
 CMAKE_ARGS+=	-DWITH_TIFF:BOOL=Off
 .endif
 
-.if !defined(WITHOUT_V4L)
+.if ${PORT_OPTIONS:MV4L}
 LIB_DEPENDS+=	v4l2.0:${PORTSDIR}/multimedia/libv4l
 BUILD_DEPENDS+=	${LOCALBASE}/include/linux/videodev2.h:${PORTSDIR}/multimedia/v4l_compat
 CMAKE_ARGS+=	-DWITH_V4L:BOOL=On \
@@ -145,7 +146,7 @@
 CMAKE_ARGS+=	-DWITH_V4L:BOOL=Off
 .endif
 
-.if defined(WITH_XINE)
+.if ${PORT_OPTIONS:MXINE}
 LIB_DEPENDS+=	xine.2:${PORTSDIR}/multimedia/libxine
 CMAKE_ARGS+=	-DWITH_XINE:BOOL=On
 .else
@@ -236,7 +237,7 @@
 		${WRKSRC}/OpenCVConfig.cmake.in > ${WRKSRC}/OpenCVConfig-core.cmake.in
 	@${LN} -sf OpenCVConfig-version.cmake.in ${WRKSRC}/OpenCVConfig-core-version.cmake.in
 .endif
-.if defined(NOPORTDOCS) || defined(_BUILDING_OPENCV_CORE) || defined(_BUILDING_OPENCV_PYTHON)
+.if ! ${PORT_OPTIONS:MDOCS} || defined(_BUILDING_OPENCV_CORE) || defined(_BUILDING_OPENCV_PYTHON)
 	@${REINPLACE_CMD} -e '/add_subdirectory(doc)/ d' \
 		${WRKSRC}/CMakeLists.txt
 .endif

Added: trunk/graphics/opencv/files/patch-modules__ts__include__opencv2__ts__ts_gtest.h
===================================================================
--- trunk/graphics/opencv/files/patch-modules__ts__include__opencv2__ts__ts_gtest.h	                        (rev 0)
+++ trunk/graphics/opencv/files/patch-modules__ts__include__opencv2__ts__ts_gtest.h	2014-08-29 20:02:50 UTC (rev 16689)
@@ -0,0 +1,268 @@
+--- ./modules/ts/include/opencv2/ts/ts_gtest.h.orig	2013-09-01 01:03:57.000000000 +0100
++++ ./modules/ts/include/opencv2/ts/ts_gtest.h	2013-09-01 01:03:38.000000000 +0100
+@@ -53,6 +53,7 @@
+ 
+ #include <limits>
+ #include <vector>
++#include <unistd.h>
+ 
+ // Copyright 2005, Google Inc.
+ // All rights reserved.
+@@ -543,7 +544,7 @@
+ // Author: wan at google.com (Zhanyong Wan)
+ 
+ // Implements a subset of TR1 tuple needed by Google Test and Google Mock.
+-
++#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ 1
+ #ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_
+ #define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_
+ 
+@@ -1504,11 +1505,31 @@
+ // <tr1/functional>.  Hence the following #define is a hack to prevent
+ // <tr1/functional> from being included.
+ #define _TR1_FUNCTIONAL 1
++#if __has_include(<tuple>)
++#include <tuple>
++namespace gtest {
++	using ::std::tuple;
++}
++#else
+ #include <tr1/tuple>
++namespace gtest {
++	using ::std::tr1::tuple;
++}
++#endif
+ #undef _TR1_FUNCTIONAL  // Allows the user to #include
+                         // <tr1/functional> if he chooses to.
+ #else
+-#include <tr1/tuple>  // NOLINT
++#if __has_include(<tuple>)
++#include <tuple>
++namespace gtest {
++	using ::std::tuple;
++}
++#else
++#include <tr1/tuple>
++namespace gtest {
++	using ::std::tr1::tuple;
++}
++#endif
+ #endif  // !GTEST_HAS_RTTI && GTEST_GCC_VER_ < 40302
+ 
+ #else
+@@ -11951,9 +11972,9 @@
+ //
+ template <typename T1, typename T2>
+ class CartesianProductGenerator2
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2> > {
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2> ParamType;
++  typedef gtest::tuple<T1, T2> ParamType;
+ 
+   CartesianProductGenerator2(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2)
+@@ -12066,9 +12087,9 @@
+ 
+ template <typename T1, typename T2, typename T3>
+ class CartesianProductGenerator3
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3> > {
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3> ParamType;
++  typedef gtest::tuple<T1, T2, T3> ParamType;
+ 
+   CartesianProductGenerator3(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3)
+@@ -12198,9 +12219,9 @@
+ 
+ template <typename T1, typename T2, typename T3, typename T4>
+ class CartesianProductGenerator4
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4> > {
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4> ParamType;
+ 
+   CartesianProductGenerator4(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -12349,9 +12370,9 @@
+ 
+ template <typename T1, typename T2, typename T3, typename T4, typename T5>
+ class CartesianProductGenerator5
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5> > {
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5> ParamType;
+ 
+   CartesianProductGenerator5(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -12517,10 +12538,10 @@
+ template <typename T1, typename T2, typename T3, typename T4, typename T5,
+     typename T6>
+ class CartesianProductGenerator6
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5,
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5,
+         T6> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5, T6> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5, T6> ParamType;
+ 
+   CartesianProductGenerator6(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -12703,10 +12724,10 @@
+ template <typename T1, typename T2, typename T3, typename T4, typename T5,
+     typename T6, typename T7>
+ class CartesianProductGenerator7
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6,
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5, T6,
+         T7> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5, T6, T7> ParamType;
+ 
+   CartesianProductGenerator7(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -12906,10 +12927,10 @@
+ template <typename T1, typename T2, typename T3, typename T4, typename T5,
+     typename T6, typename T7, typename T8>
+ class CartesianProductGenerator8
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6,
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5, T6,
+         T7, T8> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8> ParamType;
+ 
+   CartesianProductGenerator8(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -13128,10 +13149,10 @@
+ template <typename T1, typename T2, typename T3, typename T4, typename T5,
+     typename T6, typename T7, typename T8, typename T9>
+ class CartesianProductGenerator9
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6,
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5, T6,
+         T7, T8, T9> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9> ParamType;
+ 
+   CartesianProductGenerator9(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -13367,10 +13388,10 @@
+ template <typename T1, typename T2, typename T3, typename T4, typename T5,
+     typename T6, typename T7, typename T8, typename T9, typename T10>
+ class CartesianProductGenerator10
+-    : public ParamGeneratorInterface< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6,
++    : public ParamGeneratorInterface< gtest::tuple<T1, T2, T3, T4, T5, T6,
+         T7, T8, T9, T10> > {
+  public:
+-  typedef ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> ParamType;
++  typedef gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> ParamType;
+ 
+   CartesianProductGenerator10(const ParamGenerator<T1>& g1,
+       const ParamGenerator<T2>& g2, const ParamGenerator<T3>& g3,
+@@ -13632,8 +13653,8 @@
+ CartesianProductHolder2(const Generator1& g1, const Generator2& g2)
+       : g1_(g1), g2_(g2) {}
+   template <typename T1, typename T2>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2> >(
++  operator ParamGenerator< gtest::tuple<T1, T2> >() const {
++    return ParamGenerator< gtest::tuple<T1, T2> >(
+         new CartesianProductGenerator2<T1, T2>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_)));
+@@ -13654,8 +13675,8 @@
+     const Generator3& g3)
+       : g1_(g1), g2_(g2), g3_(g3) {}
+   template <typename T1, typename T2, typename T3>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3> >(
++  operator ParamGenerator< gtest::tuple<T1, T2, T3> >() const {
++    return ParamGenerator< gtest::tuple<T1, T2, T3> >(
+         new CartesianProductGenerator3<T1, T2, T3>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13679,8 +13700,8 @@
+     const Generator3& g3, const Generator4& g4)
+       : g1_(g1), g2_(g2), g3_(g3), g4_(g4) {}
+   template <typename T1, typename T2, typename T3, typename T4>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4> >(
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4> >() const {
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4> >(
+         new CartesianProductGenerator4<T1, T2, T3, T4>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13706,8 +13727,8 @@
+     const Generator3& g3, const Generator4& g4, const Generator5& g5)
+       : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5> >(
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5> >() const {
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5> >(
+         new CartesianProductGenerator5<T1, T2, T3, T4, T5>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13737,8 +13758,8 @@
+       : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5,
+       typename T6>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6> >(
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6> >() const {
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6> >(
+         new CartesianProductGenerator6<T1, T2, T3, T4, T5, T6>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13770,9 +13791,9 @@
+       : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5,
+       typename T6, typename T7>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6,
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6,
+       T7> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7> >(
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7> >(
+         new CartesianProductGenerator7<T1, T2, T3, T4, T5, T6, T7>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13808,9 +13829,9 @@
+           g8_(g8) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5,
+       typename T6, typename T7, typename T8>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7,
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7,
+       T8> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8> >(
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8> >(
+         new CartesianProductGenerator8<T1, T2, T3, T4, T5, T6, T7, T8>(
+         static_cast<ParamGenerator<T1> >(g1_),
+         static_cast<ParamGenerator<T2> >(g2_),
+@@ -13849,9 +13870,9 @@
+           g9_(g9) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5,
+       typename T6, typename T7, typename T8, typename T9>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
+       T9> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
+         T9> >(
+         new CartesianProductGenerator9<T1, T2, T3, T4, T5, T6, T7, T8, T9>(
+         static_cast<ParamGenerator<T1> >(g1_),
+@@ -13893,9 +13914,9 @@
+           g9_(g9), g10_(g10) {}
+   template <typename T1, typename T2, typename T3, typename T4, typename T5,
+       typename T6, typename T7, typename T8, typename T9, typename T10>
+-  operator ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
++  operator ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
+       T9, T10> >() const {
+-    return ParamGenerator< ::std::tr1::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
++    return ParamGenerator< gtest::tuple<T1, T2, T3, T4, T5, T6, T7, T8,
+         T9, T10> >(
+         new CartesianProductGenerator10<T1, T2, T3, T4, T5, T6, T7, T8, T9,
+             T10>(

Added: trunk/graphics/opencv/files/patch-samples_cpp_bagofwords_classification.cpp
===================================================================
--- trunk/graphics/opencv/files/patch-samples_cpp_bagofwords_classification.cpp	                        (rev 0)
+++ trunk/graphics/opencv/files/patch-samples_cpp_bagofwords_classification.cpp	2014-08-29 20:02:50 UTC (rev 16689)
@@ -0,0 +1,11 @@
+--- samples/cpp/bagofwords_classification.cpp.orig	2011-09-12 20:20:43.000000000 +0200
++++ samples/cpp/bagofwords_classification.cpp	2013-09-12 14:57:38.068066669 +0200
+@@ -1814,7 +1814,7 @@
+ void VocData::readFileToString(const string filename, string& file_contents)
+ {
+     std::ifstream ifs(filename.c_str());
+-    if (ifs == false) CV_Error(CV_StsError,"could not open text file");
++    if (!ifs.is_open()) CV_Error(CV_StsError,"could not open text file");
+ 
+     stringstream oss;
+     oss << ifs.rdbuf();



More information about the Midnightbsd-cvs mailing list