Open vishnukumarts opened 4 years ago
Can I assume you got this due to your post in #54 ?
I have the same issue on Ubuntu 18.04 I could install all dependencies, but when trying to compile vicalib I get this:
CMakeFiles/vicalib.dir/src/vicalib-engine.cc.o: In function `visual_inertial_calibration::VicalibEngine::InitTask()':
vicalib-engine.cc:(.text+0x5db7): undefined reference to `calibu::KannalaBrandtCamera<double>::NumParams'
vicalib-engine.cc:(.text+0x5fba): undefined reference to `calibu::Rational6Camera<double>::NumParams'
vicalib-engine.cc:(.text+0x6284): undefined reference to `calibu::LinearCamera<double>::NumParams'
collect2: error: ld returned 1 exit status
CMakeFiles/vicalib.dir/build.make:204: recipe for target 'vicalib' failed
make[2]: *** [vicalib] Error 1
CMakeFiles/Makefile2:136: recipe for target 'CMakeFiles/vicalib.dir/all' failed
make[1]: *** [CMakeFiles/vicalib.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
it compiled after three fixes in vicalib-engine.cc. Since it is only a fixed amount of parameters, I just counted the amount of parameters that overwrite it and hardcoded it:
bad Eigen::VectorXd params_(calibu::KannalaBrandtCamera<double>::NumParams);
good Eigen::VectorXd params_(10);
bad Eigen::VectorXd params_(calibu::Rational6Camera<double>::NumParams);
good Eigen::VectorXd params_(10);
bad Eigen::VectorXd params_(calibu::LinearCamera<double>::NumParams);
goodEigen::VectorXd params_(4);
This doesn't really deal with the original issue, but it seems to do the trick. My guess is that somebody refactored Calibu slightly, and the newest master doesn't match anymore with this one.
after all the dependencies installed, i am finally stuck with the below error,
CMakeFiles/vicalib.dir/src/vicalib-engine.cc.o: In function::NumParams'
vicalib-engine.cc:(.text+0x5e3a): undefined reference to `calibu::Rational6Camera::NumParams'
visual_inertial_calibration::VicalibEngine::InitTask()': vicalib-engine.cc:(.text+0x5c37): undefined reference to
calibu::KannalaBrandtCamera