Linking octomap to new project | octomap/octomap.h: No such file or directory
RyanWagner10000 opened this issue · 1 comments
Can't get octomap to link with personal c++ project. I followed the directions to put some lines in my CMakeLists.txt file, but no matter what I do it can't find octomap. I tried executing the sample-script given, but that still errored with the same message:
main.cpp:2:10: fatal error: octomap/octomap.h: No such file or directory
which is line:
#include <octomap/octomap.h>
Here is what my CMakeLists.txt looks like if it helps. Maybe there's a problem with linking the direct path to something? Any help would be appreciated!
cmake_minimum_required(VERSION 3.10)
# set the project name
project(convert_binvox)
# Octomap
find_package(octomap REQUIRED)
include_directories(${OCTOMAP_INCLUDE_DIRS})
link_directories(${OCTOMAP_LIBRARY_DIRS})
link_libraries(${OCTOMAP_LIBRARIES})
# add the executable
add_executable(convert_binvox main.cpp)
hey guys, i also get this error, How did you solve it?