ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

usb_cam on pandaboard / fatal error: libavcodec/avcodec.h

asked 2012-06-13 07:42:01 -0600

dinamex gravatar image

updated 2014-01-28 17:12:40 -0600

ngrennan gravatar image

Hi there,

I'm trying to install the usb_cam package on my Pandaboard (Armel architecture / System Oneric 11.10-Server. I used:

$ sudo apt-get install ros-electric-bosch-drivers

which probably fails because of the armel architecture. Therefore I choosed the installation from source.

$ svn co https://bosch-ros-pkg.svn.sourceforge.net/svnroot/bosch-ros-pkg/branches/electric/stacks/bosch_drivers/
$ roscd usb_cam
$ rosmake --rosdep-install

I get the following failure message:

E: Unable to locate package yaml-cpp0.2.6-dev
E: Couldn't find any package by regex 'yaml-cpp0.2.6-dev'
Failed to install yaml-cpp!
[ rosmake ] rosdep install failed: Rosdep install failed

I installed the yaml_cpp from source with:

$ hg clone ttp://code.google.com/p/yaml-cpp/
$ svn co
$ mkdir build
$ cd build
$ cmake -DBUILD_SHARED_LIBS=ON ..
$ make
$ sudo make install

without any problems. But when I try to make the usb_cam package by:

$ rosmake usb_cam --rosdep-install

it stills produces the same failure (missing yaml_cpp)


By compiling just the usb_cam package:

$ rosmake usb_cam --no-rosdep

it produces the following failure

[rosmake-0] Starting >>> usb_cam [ make ]
[ rosmake ] Last 40 linesb_cam: 20.6 sec ]           [ 1 Active 33/34 Complete ]
{-------------------------------------------------------------------------------
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target rosbuild_premsgsrvgen
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target ROSBUILD_gensrv_cpp
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target ROSBUILD_gensrv_cpp
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target ROSBUILD_gensrv_lisp
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target ROSBUILD_gensrv_lisp
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target rospack_gensrv
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target rospack_gensrv
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target rospack_gensrv_all
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target rospack_gensrv_all
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target rospack_genmsg_libexe
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target rospack_genmsg_libexe
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target rosbuild_precompile
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [  0%] Built target rosbuild_precompile
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  Scanning dependencies of target usb_cam
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  make[3]: Entering directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  [ 50%] Building CXX object src/libusb_cam/CMakeFiles/usb_cam.dir/usb_cam.o
  /home/panda/ros_workspace/bosch_drivers/usb_cam/src/libusb_cam/usb_cam.cpp:55:32: fatal error: libavcodec/avcodec.h: No such file or directory
  compilation terminated.
  make[3]: *** [src/libusb_cam/CMakeFiles/usb_cam.dir/usb_cam.o] Error 1
  make[3]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  make[2]: *** [src/libusb_cam/CMakeFiles/usb_cam.dir/all] Error 2
  make[2]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
  make[1]: *** [all] Error 2
  make[1]: Leaving directory `/home/panda/ros_workspace/bosch_drivers/usb_cam/build'
-------------------------------------------------------------------------------}
[ rosmake ] Output from build of package usb_cam written to:
[ rosmake ]    /home/panda ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2012-06-13 08:27:28 -0600

derekjchow gravatar image

It looks like you need to install libavcodec. I don't know the exact command to install it off the top of my head, but the format will look like this:

sudo apt-get install libavcodec

The exact package name might not be libavcodec. It maybe looks something like libavcodec-VERSION-NUMBER or libavcodec-dev. In these situations you can search for packages with a command like this:

apt-cache search libavcodec

This will find all packages that have text containing "libavcodec". This should find the correct package for you to install.

edit flag offensive delete link more

Comments

That worked. I just used $sudo apt-get install libavcodec-dev libavcodec53 and compiled it afterwards. thank you very much.

dinamex gravatar image dinamex  ( 2012-06-13 12:13:58 -0600 )edit

Question Tools

Stats

Asked: 2012-06-13 07:42:01 -0600

Seen: 1,377 times

Last updated: Jun 13 '12