Ask Your Question
0

OpenCV configure with TBB for ARM, Ubuntu 12.10

asked 2013-02-17 14:16:58 -0600

nikkadim gravatar image

updated 2013-02-17 14:32:56 -0600

I'm trying to compile OpenCV libs with TBB support for odroid U2 (with Quad core ARM Cortex-A9 MPCore). I have no problem with compile current OpenCV (from github) without TBB. And also I have no problem to compile TBB libs from sources tbb41_20130116oss_src.tgz and I have successfully builded TBB libs:

root@odroid:~/src/tbb41_20130116oss/build/linux_armv7l_gcc_cc4.6_libc2.15_kernel3.0.63_release# ls
arena.d                    concurrent_queue.o      frontend.d           libtbbmalloc.so.2        proxy.d               scheduler.o           task_v2.d                   tbb_thread.d
arena.o                    concurrent_queue_v2.d   frontend.o           libtbbmalloc_proxy.so    proxy.o               semaphore.d           task_v2.o                   tbb_thread.o
backend.d                  concurrent_queue_v2.o   governor.d           libtbbmalloc_proxy.so.2  queuing_mutex.d       semaphore.o           tbb.def                     tbbmalloc.d
backend.o                  concurrent_vector.d     governor.o           market.d                 queuing_mutex.o       spin_mutex.d          tbb_function_replacement.d  tbbmalloc.def
backref.d                  concurrent_vector.o     itt_notify.d         market.o                 queuing_rw_mutex.d    spin_mutex.o          tbb_function_replacement.o  tbbmalloc.o
backref.o                  concurrent_vector_v2.d  itt_notify.o         mutex.d                  queuing_rw_mutex.o    spin_rw_mutex.d       tbb_main.d                  tbbmallocproxy.def
cache_aligned_allocator.d  concurrent_vector_v2.o  itt_notify_malloc.d  mutex.o                  reader_writer_lock.d  spin_rw_mutex.o       tbb_main.o                  tbbvars.csh
cache_aligned_allocator.o  condition_variable.d    itt_notify_malloc.o  observer_proxy.d         reader_writer_lock.o  spin_rw_mutex_v2.d    tbb_misc.d                  tbbvars.sh
concurrent_hash_map.d      condition_variable.o    large_objects.d      observer_proxy.o         recursive_mutex.d     spin_rw_mutex_v2.o    tbb_misc.o                  version_string.ver
concurrent_hash_map.o      critical_section.d      large_objects.o      pipeline.d               recursive_mutex.o     task.d                tbb_misc_ex.d
concurrent_monitor.d       critical_section.o      libtbb.so            pipeline.o               rml_tbb.d             task.o                tbb_misc_ex.o
concurrent_monitor.o       dynamic_link.d          libtbb.so.2          private_server.d         rml_tbb.o             task_group_context.d  tbb_statistics.d
concurrent_queue.d         dynamic_link.o          libtbbmalloc.so      private_server.o         scheduler.d           task_group_context.o  tbb_statistics.o
root@odroid:~/src/tbb41_20130116oss/build/linux_armv7l_gcc_cc4.6_libc2.15_kernel3.0.63_release#

I can compile my own programm with gcc using this TBB libs, but I can't configure OpenCV to see this TBB libs:

root@odroid:~/src/work/opencv/release# cmake -D CMAKE_BUILD_TYPE=RELEASE -D  WITH_TBB=ON -D CMAKE_INSTALL_PREFIX=/usr/local ..
-- Detected version of GNU GCC: 46 (406)
-- Found OpenEXR: /usr/lib/libIlmImf.so
-- checking for module 'gstreamer-app-0.10'
--   package 'gstreamer-app-0.10' not found
-- Looking for linux/videodev.h
-- Looking for linux/videodev.h - not found
-- Looking for linux/videodev2.h
-- Looking for linux/videodev2.h - found
-- Looking for sys/videoio.h
-- Looking for sys/videoio.h - not found
-- Looking for libavformat/avformat.h
-- Looking for libavformat/avformat.h - found
-- Looking for ffmpeg/avformat.h
-- Looking for ffmpeg/avformat.h - not found
-- checking for module 'tbb'
--   package 'tbb' not found
[...]

could you explain how I can do this? Thank you!

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
0

answered 2013-02-18 01:21:54 -0600

There are two possible solutions for your issue.

  1. If you want to use your compiled binaries of TBB you need to create pkgconfig or cmake module file for it and/or place it in the right place.

  2. You can use built-in cmake scripts for TBB. Just add "-DWITH_TBB=ON -DBUILD_TBB=ON" to OpenCV cmake command line. Cmake automatically downloads the latest supported TBB version and build it with OpenCV. In this case some additional ARM specific issues in TBB will be fixed.

edit flag offensive delete link more
0

answered 2013-02-18 01:12:51 -0600

Did you install TBB after compilation to allow CMake to find the package? Moreover, it seems you have compile TBB in root, did you change the rights of files to allow users to access to TBB?

edit flag offensive delete link more

Comments

How to install TBB after compilation on odroid xu4

vasu12360 gravatar imagevasu12360 ( 2017-02-03 03:49:10 -0600 )edit

Question Tools

Stats

Asked: 2013-02-17 14:16:58 -0600

Seen: 3,323 times

Last updated: Feb 18 '13