catkin_make error
make[2]: *** [swarm_coverage/CMakeFiles/voronoi_main.dir/src/voronoi_main.cpp.o] Error 1
make[1]: *** [swarm_coverage/CMakeFiles/voronoi_main.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
Linking CXX shared library /home/sourabha/catkin_ws/devel/lib/libgazebo_ros_multicamera.so
[ 96%] Built target gazebo_ros_multicamera
Linking CXX shared library /home/sourabha/catkin_ws/devel/lib/libgazebo_ros_prosilica.so
[ 96%] Built target gazebo_ros_prosilica
Linking CXX shared library /home/sourabha/catkin_ws/devel/lib/libgazebo_ros_openni_kinect.so
[ 96%] Built target gazebo_ros_openni_kinect
make: *** [all] Error 2
Invoking "make -j4 -l4" failed`
In response to catkin_make -j1
:
/home/sourabha/catkin_ws/src/swarm_coverage/src/voronoi_main.cpp: In function ‘void createEnv(swarm_simulator::obstacleList)’:
/home/sourabha/catkin_ws/src/swarm_coverage/src/voronoi_main.cpp:31:32: error: no matching function for call to ‘Coverage::GetBestPositions(std::vector<cv::Point_<int> >&)’
obj.GetBestPositions(locations);
^
/home/sourabha/catkin_ws/src/swarm_coverage/src/voronoi_main.cpp:31:32: note: candidate is:
In file included from /home/sourabha/catkin_ws/src/swarm_coverage/src/voronoi_main.cpp:9:0:
/home/sourabha/catkin_ws/src/swarm_coverage/include/Coverage.h:36:7: note: void Coverage::GetBestPositions(int)
void GetBestPositions(vector<Point>& positions);
^
/home/sourabha/catkin_ws/src/swarm_coverage/include/Coverage.h:36:7: note: no known conversion for argument 1 from ‘std::vector<cv::Point_<int> >’ to ‘int’
make[2]: *** [swarm_coverage/CMakeFiles/voronoi_main.dir/src/voronoi_main.cpp.o] Error 1
make[1]: *** [swarm_coverage/CMakeFiles/voronoi_main.dir/all] Error 2
make: *** [all] Error 2
Invoking "make -j1" failed
Without some more information (ROS version, how installed, etc) and a description of what you are trying to do (and where you got your sources from), this is going to be hard to diagnose.
Also: that is not the real error. Please run a
catkin_make -j1
, wait for it to fail, and copy the complete error message into your question. Use the edit link/button for that, and format using the Preformatted text button (the one with1010101
on it).In Coverage.h your compiler thinks void GetBestPositions(vector<point>& positions) is equivalent to void Coverage::GetBestPositions(int). However, when compiling your voronoi_main.cpp it understands that they are different and returns the error - no known conversion. Possible source code