Robotics, ROS

How to solve caffe.hpp: No such file or directory error when compiling gps_agent_pkg?

When I was make -j the gps_agent_pkg package, I met this error:

caffe_error

[100%] Building CXX object CMakeFiles/gps_agent_lib.dir/src/util.cpp.o
Building CXX object CMakeFiles/gps_agent_lib.dir/src/neuralnetworkcaffe.cpp.o
Building CXX object CMakeFiles/gps_agent_lib.dir/src/caffenncontroller.cpp.o
/home/ros/research/gps/src/gps_agent_pkg/src/caffenncontroller.cpp:1:27: fatal error: caffe/caffe.hpp: No such file or directory
#include "caffe/caffe.hpp"
^
compilation terminated.
make[2]: *** [CMakeFiles/gps_agent_lib.dir/src/caffenncontroller.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/ros/research/gps/src/gps_agent_pkg/src/neuralnetworkcaffe.cpp:1:0:
/home/ros/research/gps/src/gps_agent_pkg/include/gps_agent_pkg/neuralnetworkcaffe.h:10:27: fatal error: caffe/caffe.hpp: No such file or directory
#include "caffe/caffe.hpp"
^
compilation terminated.
In file included from /home/ros/research/gps/src/gps_agent_pkg/include/gps_agent_pkg/caffenncontroller.h:10:0,
from /home/ros/research/gps/src/gps_agent_pkg/src/robotplugin.cpp:16:
/home/ros/research/gps/src/gps_agent_pkg/include/gps_agent_pkg/neuralnetworkcaffe.h:10:27: fatal error: caffe/caffe.hpp: No such file or directory
#include "caffe/caffe.hpp"
^
compilation terminated.

And this error should be solved bymake distribute in the caffe dir. Aftermake distribute successfully in the caffe dir, I compiledgps_agent_pkg.

gps_success.png

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s