ori-drs / aicp_mapping

Auto-tuned Iterative Closest Point -- AICP -- Public
GNU Lesser General Public License v2.1
3 stars 6 forks source link

catkin_make error #1

Open crankler opened 5 years ago

crankler commented 5 years ago

When I try to use this package on my computer, I get this error:

aicp_mapping/aicp_core/src/overlap/octrees_overlap.cpp:166:30: error: ‘gettimeofday’ was not declared in this scope gettimeofday(&start, NULL); // start timer

aicp_mapping/aicp_core/src/utils/icpMonitor.cpp:29:92: error: cannot convert ‘std::shared_ptr<PointMatcher::Matcher>’ to ‘PointMatcher::Matcher’ in initialization PM::Matcher matcherHausdorff = PM::get().MatcherRegistrar.create("KDTreeMatcher", params);

aicp_mapping/aicp_core/src/utils/icpMonitor.cpp:105:83: error: cannot convert ‘std::shared_ptr<PointMatcher::Matcher>’ to ‘PointMatcher::Matcher’ in initialization PM::Matcher matcher = PM::get().MatcherRegistrar.create("KDTreeMatcher", params);

aicp_core/src/registration/pointmatcher_registration.cpp:75:101: error: cannot convert ‘std::shared_ptr<PointMatcher::Transformation>’ to ‘PointMatcher::Transformation’ in initialization PM::Transformation rigid_transform = PM::get().REG(Transformation).create("RigidTransformation");

So can you tell me how to fix this error? Thank you!

mauricefallon commented 5 years ago

we use "catkin build" not "catkin_make" https://catkin-tools.readthedocs.io/en/latest/verbs/catkin_build.html

We also use versions 1.3.1-0bionic of the libpointmatcher and libpointmatcher1 packages

crankler commented 5 years ago

Thank you for your help. I have try to use your way on this project ,there show this error:

Errors << aicp_core:make /home/hitnuc/aicp_ws/logs/aicp_core/build.make.000.log /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/overlap/octrees_overlap.cpp: In member function ‘void aicp::OctreesOverlap::createTree(pcl::PointCloud&, Eigen::Isometry3d, octomap::ColorOcTree, octomap::ColorOcTreeNode::Color)’: /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/overlap/octrees_overlap.cpp:166:30: error: ‘gettimeofday’ was not declared in this scope gettimeofday(&start, NULL); // start timer ^ make[2]: [CMakeFiles/aicpOverlap.dir/src/overlap/octrees_overlap.cpp.o] Error 1 make[1]: [CMakeFiles/aicpOverlap.dir/all] Error 2 /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/registration/pointmatcher_registration.cpp: In member function ‘PointMatcher::TransformationParameters aicp::PointmatcherRegistration::applyInitialization()’: /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/registration/pointmatcher_registration.cpp:75:101: error: cannot convert ‘std::shared_ptr<PointMatcher::Transformation>’ to ‘PointMatcher::Transformation’ in initialization PM::Transformation rigid_transform = PM::get().REG(Transformation).create("RigidTransformation"); ^ /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/utils/icpMonitor.cpp: In function ‘float hausdorffDistance(DP&, DP&, const char)’: /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/utils/icpMonitor.cpp:29:92: error: cannot convert ‘std::shared_ptr<PointMatcher::Matcher>’ to ‘PointMatcher::Matcher’ in initialization PM::Matcher matcherHausdorff = PM::get().MatcherRegistrar.create("KDTreeMatcher", params); ^ /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/utils/icpMonitor.cpp: In function ‘PointMatcher::Matrix distancesKNN(DP&, DP&, const char)’: /home/hitnuc/aicp_ws/src/aicp_mapping/aicp_core/src/utils/icpMonitor.cpp:105:83: error: cannot convert ‘std::shared_ptr<PointMatcher::Matcher>’ to ‘PointMatcher::Matcher’ in initialization PM::Matcher matcher = PM::get().MatcherRegistrar.create("KDTreeMatcher", params); ^ make[2]: [CMakeFiles/aicpRegistration.dir/src/registration/pointmatcher_registration.cpp.o] Error 1 make[1]: [CMakeFiles/aicpRegistration.dir/all] Error 2 make[2]: [CMakeFiles/aicpUtils.dir/src/utils/icpMonitor.cpp.o] Error 1 make[1]: [CMakeFiles/aicpUtils.dir/all] Error 2 make: *** [all] Error 2 cd /home/hitnuc/aicp_ws/build/aicp_core; catkin build --get-env aicp_core | catkin env -si /usr/bin/make --jobserver-fds=6,7 -j; cd - ............................................................................... Failed << aicp_core:make [ Exited with code 2 ]
Failed <<< aicp_core [ 54.4 seconds ]
Abandoned <<< aicp_ros [ Unrelated job failed ]
[build] Summary: 2 of 4 packages succeeded.
[build] Ignored: None.
[build] Warnings: 1 packages succeeded with warnings.
[build] Abandoned: 1 packages were abandoned.
[build] Failed: 1 packages failed.
[build] Runtime: 1 minute and 0.8 seconds total.
[build] Note: Workspace packages have changed, please re-source setup files to use them.