SpectacularAI / HybVIO

HybVIO visual-inertial odometry and SLAM system
https://arxiv.org/abs/2106.11857
GNU General Public License v3.0
450 stars 92 forks source link

Linker error #12

Closed Ador2 closed 2 years ago

Ador2 commented 2 years ago

After make is done i get this error

[100%] Linking CXX executable main
../3rdparty/mobile-cv-suite/build/host/lib/libaccelerated-arrays.a(glfw.cpp.o): In function `accelerated::opengl::(anonymous namespace)::GLFWProcessor::GLFWProcessor(bool, int, int, char const*, GLFWwindow**, accelerated::opengl::GLFWProcessorMode)::{lambda()#1}::operator()() const':
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:51: undefined reference to `glfwInit'
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:52: undefined reference to `glfwWindowHint'
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:62: undefined reference to `glfwCreateWindow'
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:63: undefined reference to `glfwTerminate'
../3rdparty/mobile-cv-suite/build/host/lib/libaccelerated-arrays.a(glfw.cpp.o): In function `accelerated::opengl::(anonymous namespace)::GLFWProcessor::~GLFWProcessor()::{lambda()#1}::operator()() const':
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:76: undefined reference to `glfwDestroyWindow'
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:77: undefined reference to `glfwTerminate'
../3rdparty/mobile-cv-suite/build/host/lib/libaccelerated-arrays.a(glfw.cpp.o): In function `accelerated::opengl::(anonymous namespace)::GLFWProcessor::enqueue(std::function<void ()> const&)::{lambda()#1}::operator()() const':
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:89: undefined reference to `glfwMakeContextCurrent'
/home/user/workspace/HybVIO/3rdparty/mobile-cv-suite/accelerated-arrays/src/opengl/glfw.cpp:91: undefined reference to `glfwPollEvents'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
CMakeFiles/main.dir/build.make:199: recipe for target 'main' failed
make[2]: *** [main] Error 1
CMakeFiles/Makefile2:70: recipe for target 'CMakeFiles/main.dir/all' failed
make[1]: *** [CMakeFiles/main.dir/all] Error 2
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2
oseiskar commented 2 years ago

Try building without GL-based visualizations, like this https://github.com/SpectacularAI/HybVIO/issues/8#issuecomment-994765475

(duplicate of #5 .... we should put the solution to the README, though...)

Ador2 commented 2 years ago

Ah, sorry, and yes you should :)