gaoxiang12 / slambook

MIT License
6.84k stars 3.26k forks source link

ch9 中我在将src进行cmake编译的时候出现错误。。。有同学遇到吗? #168

Open happyrookie opened 5 years ago

happyrookie commented 5 years ago

root@MAC:/home/lee/project1/0.2/src# make Scanning dependencies of target myslam [ 14%] Building CXX object CMakeFiles/myslam.dir/frame.cpp.o /home/lee/project1/0.2/src/frame.cpp:1:26: fatal error: myslam/frame.h: 没有那个文件或目录 compilation terminated. CMakeFiles/myslam.dir/build.make:62: recipe for target 'CMakeFiles/myslam.dir/frame.cpp.o' failed make[2]: [CMakeFiles/myslam.dir/frame.cpp.o] Error 1 CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/myslam.dir/all' failed make[1]: [CMakeFiles/myslam.dir/all] Error 2 Makefile:83: recipe for target 'all' failed make: *** [all] Error 2 不知道跟frame.h有什么关系。。。

happyrookie commented 5 years ago

求大神说一下具体的编译细节是怎样的?先谢过了

happyrookie commented 5 years ago

frame.h为什么找不到呢????

jackxujh commented 5 years ago

应该在另一个目录吧——不过我想过了这么久,你应该已经找到了

happyrookie commented 5 years ago

弄明白了,要在主目录开始编译,另外出现找不到Sophus的问题,我就在kdevelop下面自定义路径然后在kdevelop下进行编译就解决了