码迷,mamicode.com
首页 > 其他好文 > 详细

ZOJ3672:Gao The Sequence

时间:2014-05-13 13:45:10      阅读:327      评论:0      收藏:0      [点我收藏+]

标签:style   class   code   c   tar   ext   

安装opencv2.0

解压OpenCV-2.0.0.tar.bz2
tar xvf OpenCV-2.0.0.tar.bz2

配置
./configure --host=arm-linux \
--without-carbon \
--without-quicktime \
--without-1394libs \
--without-ffmpeg \
--without-python \
--without-swig \
--without-gtk \
--enable-static \
--enable-shared \
--disable-apps \
--without-gtk \
--prefix=$PWD/output/A31 \
--libdir=$PWD/output/A31/lib \
--includedir=$PWD/output/A31/include


error: ‘ptrdiff_t‘ does not name a type 解决方法:
Jose Luis Blanco — 2011年5月9日 上午2:13:03
I confirm this bug and that it‘s serious since it prevents other
packages to build in SID with the newest g++ 4.6.

However, it can be very easily fixed by patching one single line, as
shown in the attached patch (also copied below):

=============================
diff -w -rupN OpenCV-2.1.0//include/opencv/cxcore.hpp
opencv-2.1.0//include/opencv/cxcore.hpp
--- OpenCV-2.1.0//include/opencv/cxcore.hpp	2010-04-06 03:24:40.000000000 +0200
+++ opencv-2.1.0//include/opencv/cxcore.hpp	2011-05-08 19:56:53.759113108 +0200
@@ -66,6 +66,7 @@ namespace cv {

 using std::vector;
 using std::string;
+using std::ptrdiff_t;

 template<typename _Tp> class CV_EXPORTS Size_;
 template<typename _Tp> class CV_EXPORTS Point_;
============================

Please, could a maintainer patch this package and issue a new rebuild??

BTW: After fixing this bug OpenCV seems not to completely build due to
a similar bug in the headers of libavcodec, but perhaps they‘ve
already patched it too in SID.

Cheers,
Jose Luis

--Show footer

error: highgui/loadsave.cpp:333:28: error: ‘unlink’ was not declared in this scope   解决方法:
vi src/highgui/loadsave.cpp
加入: 
#include<unistd.h> 

ZOJ3672:Gao The Sequence,布布扣,bubuko.com

ZOJ3672:Gao The Sequence

标签:style   class   code   c   tar   ext   

原文地址:http://blog.csdn.net/libin56842/article/details/25659695

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!