|
楼主 |
发表于 2009-1-10 19:47:03
|
显示全部楼层
OpenCV在Blackfin-uClinux下的移植&问题~
使用opencv-0.9.9.tar.gz,解压后进入opencv目录,使用选项命令- ./configure --build=i686-pc-linux-gnu --host=bfin-uclinux
复制代码 通过,然后make- In file included from /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/limits.h:26,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/limits.h:122,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/syslimits.h:7,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/limits.h:11,
- from /usr/include/python2.2/Python.h:27,
- from _cv.cpp:129:
- /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/features.h:329:2: #error It appears you have defined _FILE_OFFSET_BITS=64. Unfortunately, uClibc was built without large file support enabled.
- In file included from /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/stdio.h:72,
- from /usr/include/python2.2/Python.h:42,
- from _cv.cpp:129:
- /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/bits/uClibc_stdio.h:72:2: #error Sorry... uClibc was built without large file support!
- In file included from /usr/include/python2.2/Python.h:42,
- from _cv.cpp:129:
- /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/stdio.h:83: error: `__STDIO_fpos64_t\' does not name a type
- In file included from /usr/include/python2.2/Python.h:42,
- from _cv.cpp:129:
- /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/stdio.h:701: error: `fpos_t\' has not been declared
- /usr/local/gcc-bfin-3.4-uclinux/bfin-uclinux/runtime/usr/include/stdio.h:703: error: expected `,\' or `...\' before \'*\' token
- In file included from /usr/include/python2.2/Python.h:71,
- from _cv.cpp:129:
- /usr/include/python2.2/unicodeobject.h:118:21: wchar.h: No such file or directory
- In file included from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/bfin-uclinux/bits/c++locale.h:43,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/iosfwd:46,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/bits/stl_algobase.h:70,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/bits/char_traits.h:46,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/string:47,
- from /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/stdexcept:45,
- from _cv.cpp:2694:
- /usr/local/gcc-bfin-3.4-uclinux/lib/gcc/bfin-uclinux/3.4.5/include/c++/cstdio:100: error: `::fpos_t\' has not been declared
- _cv.cpp:2473: warning: \'long int PyInt_AS_LONG(PyObject*)\' defined but not used
- _cv.cpp:2483: warning: \'double PyFloat_AS_DOUBLE(PyObject*)\' defined but not used
- make[4]: *** [_cv_la-_cv.lo] Error 1
- make[4]: Leaving directory `/home/opencv/interfaces/swig/python\'
- make[3]: *** [all-recursive] Error 1
- make[3]: Leaving directory `/home/opencv/interfaces/swig\'
- make[2]: *** [all-recursive] Error 1
- make[2]: Leaving directory `/home/opencv/interfaces\'
- make[1]: *** [all-recursive] Error 1
- make[1]: Leaving directory `/home/opencv\'
- make: *** [all] Error 2
复制代码 编译不通过,问题处在swig中
然后添加命令,去掉swig和python支持- ./configure --build=i686-pc-linux-gnu --host=bfin-uclinux --without-swig --without-python
复制代码 通过,然后make,没有报错,编译成功
然后make install,没有报错,成功
为保证结果稳定,还有一些选项如gtk等也可以取消掉 |
|