Open ccs-ros opened 6 years ago
Traceback (most recent call last):
File "/usr/bin/catkin", line 9, in
I have encountered the same error and solved it by simply remove the lines before line 25 in that file. There are also another two files having the same error. Besides these, you will encounter other three errors to make a successful build. I listed them here and show the solutions I used.
sudo add-apt-repository --yes ppa:xqms/opencv-nonfree
sudo apt-get update
sudo apt-get install libopencv-nonfree-dev
sudo apt-get install autoconf
sudo apt-get install libglew-dev
@yanjundream thank you! I solved my problem by using your method.And during the installation process,still encountered many error message.the final message is:
Failed << ceres_catkin:make [ Exited with code 2 ]
Failed <<< ceres_catkin [ 6 minutes and 22.5 seconds ]
[build] Summary: 9 of 18 packages succeeded.
[build] Ignored: None.
[build] Warnings: 1 packages succeeded with warnings.
[build] Abandoned: 7 packages were abandoned.
[build] Failed: 2 packages failed.
[build] Runtime: 6 minutes and 23.4 seconds total.
Does this mean that the installation was successful?
the error message is here:
/home/ccs/catkin_ws/build/dlib_catkin/dlib_src-prefix/src/dlib_src/include/DUtilsCV/Drawing.h:420:7: error: ‘line’ is not a member of ‘cv’
cv::line(m_canvas, a, b, style.color, style.thickness);
^
/home/ccs/catkin_ws/build/dlib_catkin/dlib_src-prefix/src/dlib_src/include/DUtilsCV/Drawing.h:427:5: error: ‘circle’ is not a member of ‘cv’
cv::circle(m_canvas, cv::Point(toPxX(x[0]), toPxY(y[0])), 1,
^
In file included from /home/ccs/catkin_ws/build/dlib_catkin/dlib_src-prefix/src/dlib_src/include/DUtilsCV/IO.h:17:0,
from /home/ccs/catkin_ws/build/dlib_catkin/dlib_src-prefix/src/dlib_src/include/DUtilsCV/DUtilsCV.h:47,
from /home/ccs/catkin_ws/build/dlib_catkin/dlib_src-prefix/src/dlib_src/src/DVision/FSolver.cpp:17:
/usr/include/opencv2/legacy/legacy.hpp: At global scope:
/usr/include/opencv2/legacy/legacy.hpp:1750:53: error: ‘cv::EM’ has not been declared
CvEMParams( int nclusters, int cov_mat_type=cv::EM::COV_MAT_DIAGONAL,
^
/usr/include/opencv2/legacy/legacy.hpp:1751:36: error: ‘cv::EM’ has not been declared
int start_step=cv::EM::START_AUTO_STEP,
^
/usr/include/opencv2/legacy/legacy.hpp:1767:1: error: expected class-name before ‘{’ token
{
^
/usr/include/opencv2/legacy/legacy.hpp:1770:34: error: ‘cv::EM’ has not been declared
enum { COV_MAT_SPHERICAL=cv::EM::COV_MAT_SPHERICAL,
^
/usr/include/opencv2/legacy/legacy.hpp:1771:34: error: ‘cv::EM’ has not been declared
COV_MAT_DIAGONAL =cv::EM::COV_MAT_DIAGONAL,
^
/usr/include/opencv2/legacy/legacy.hpp:1772:34: error: ‘cv::EM’ has not been declared
COV_MAT_GENERIC =cv::EM::COV_MAT_GENERIC };
^
/usr/include/opencv2/legacy/legacy.hpp:1775:29: error: ‘cv::EM’ has not been declared
enum { START_E_STEP=cv::EM::START_E_STEP,
^
/usr/include/opencv2/legacy/legacy.hpp:1776:29: error: ‘cv::EM’ has not been declared
START_M_STEP=cv::EM::START_M_STEP,
^
/usr/include/opencv2/legacy/legacy.hpp:1777:32: error: ‘cv::EM’ has not been declared
START_AUTO_STEP=cv::EM::START_AUTO_STEP };
^
/usr/include/opencv2/legacy/legacy.hpp:1825:9: error: ‘EM’ in namespace ‘cv’ does not name a type
cv::EM emObj;
^
/usr/include/opencv2/legacy/legacy.hpp: In member function ‘double CvEM::getLikelihood() const’:
/usr/include/opencv2/legacy/legacy.hpp:1807:58: error: ‘emObj’ was not declared in this scope
CV_WRAP inline double getLikelihood() const { return emObj.isTrained() ? logLikelihood : DBL_MAX; }
^
/usr/include/opencv2/legacy/legacy.hpp: At global scope:
/usr/include/opencv2/legacy/legacy.hpp:2622:1: error: expected class-name before ‘{’ token
{
^
/usr/include/opencv2/legacy/legacy.hpp:2667:17: error: ‘GenericDescriptorMatcher’ was not declared in this scope
virtual Ptr
@yanjundream my opencv version is 3.1.0
I have checked my opencv version and it is '2.4.8'. I have compiled all 18 packages successfully and I guess this means right. I suggested you use a pure ubuntu14 virtual machine to try first. Then come back to solve your version confliction problem.
@yanjundream I used the pure ubuntu14.04 to try again,and can't git clone something: Errors << ceres_catkin:make /home/ccs/my_ws/logs/ceres_catkin/build.make.005.log CMake Error at /home/ccs/my_ws/build/ceres_catkin/ceres_src-prefix/tmp/ceres_src-gitclone.cmake:40 (message): Failed to clone repository: 'https://ceres-solver.googlesource.com/ceres-solver'
make[2]: [ceres_src-prefix/src/ceres_src-stamp/ceres_src-download] Error 1 make[1]: [CMakeFiles/ceres_src.dir/all] Error 2 make: *** [all] Error 2 is this the problem of my network?or something else?
@Gaoee thank you! i solved my problem. And the message means well? here is some warning.
Warnings << ceres_catkin:make /home/ccs/my_ws/logs/ceres_catkin/build.make.007.log -- Found Eigen version 3.2.10: /home/ccs/my_ws/devel/include/eigen3
-- Found Google Flags header in: /home/ccs/my_ws/devel/include, in namespace: google -- Found Google Log (glog). Assuming glog was built with gflags support as gflags was found. This will make gflags a public dependency of Ceres. -- Building with OpenMP. -- Found tr1/unordered_map/set in std::tr1 namespace. -- Found shared_ptr in std::tr1 namespace using <tr1/memory> header. -- Building Ceres as a shared library. -- Do not build any example. CMake Warning: Manually-specified variables were not used by the project:
CMAKE_EXPORT_NO_PACKAGE_REGISTRY
make[3]: warning: -jN forced in submake: disabling jobserver mode.
make[3]: warning: -jN forced in submake: disabling jobserver mode.
cd /home/ccs/my_ws/build/ceres_catkin; catkin build --get-env ceres_catkin | catkin env -si /usr/bin/make --jobserver-fds=6,7 -j; cd -
...............................................................................
Finished <<< ceres_catkin [ 3 minutes and 27.6 seconds ]
Starting >>> dslam
Finished <<< dslam [ 10.4 seconds ]
[build] Summary: All 18 packages succeeded!
[build] Ignored: None.
[build] Warnings: 1 packages succeeded with warnings.
[build] Abandoned: None.
[build] Failed: None.
[build] Runtime: 3 minutes and 38.6 seconds total.
[build] Note: Workspace packages have changed, please re-source setup files to use them.
@yanjundream @Gaoee thanks for your initiative in resolving this! Just fixed the XMLs and updated the README . @ccs-ros I'm actually not sure whether suitesparse is really needed in dslam_open , please let me know if any issue pops up that would suggest that.
when i run the command "catkin build",it appeared.i don't know what is the meaning?And where is the "runDistributedMapper",where is the "feature/logging"?i can't find these.mybe i make a mistake when installed.i can't run the simulation!please give me some advice,thank you!