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

How catkin compile with rosbuild package?

asked 2014-07-12 10:04:37 -0600

sam gravatar image

I write the following code in catkin package :

#include <ros/ros.h>
#include <pr2_controllers_msgs/JointTrajectoryAction.h>
#include "actionlib/client/simple_action_client.h"
#include <stdlib.h>

using namespace cv; 
using namespace std;

When I compile, it shows:

/home/ira/code/ros_groovy/src/sam_pr2_lab_auto_scene_4/src/pr2_lab_auto_scene_4.cpp:8:56: fatal error: pr2_controllers_msgs/JointTrajectoryAction.h: No such file or directory
compilation terminated.
make[2]: *** [sam_pr2_lab_auto_scene_4/CMakeFiles/pr2_lab_auto_scene_4.dir/src/pr2_lab_auto_scene_4.cpp.o] Error 1
make[1]: *** [sam_pr2_lab_auto_scene_4/CMakeFiles/pr2_lab_auto_scene_4.dir/all] Error 2
make: *** [all] Error 2
Invoking "make" failed

I found that pr2_controllers_msgs package is based on rosbuild.

ira@ira:/opt/ros/groovy/stacks/pr2_controllers/pr2_controllers_msgs$ ls
action  bin  CMakeLists.txt  mainpage.dox  Makefile  manifest.xml  msg  msg_gen  ROS_NOBUILD  src  srv  srv_gen
ira@ira:/opt/ros/groovy/stacks/pr2_controllers/pr2_controllers_msgs$

How to solve it?

Thank you~

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2014-07-12 10:10:18 -0600

dornhege gravatar image

Build your package with rosbuild, too or change your depended package to catkin (which might be impossible as that seem to be a basic package).

Unfortunately, this is the only solution. catkin packages cannot depend on rosbuild packages.

edit flag offensive delete link more

Comments

So why we need catkin? Is there any simplest example that we can't do with rosbuild so that need catkin?

sam gravatar image sam  ( 2014-07-13 03:19:46 -0600 )edit

No, it's just another system that has other properties. You can build everything as before.

dornhege gravatar image dornhege  ( 2014-07-14 08:08:45 -0600 )edit

Question Tools

3 followers

Stats

Asked: 2014-07-12 10:04:37 -0600

Seen: 410 times

Last updated: Jul 12 '14