Coder Social home page Coder Social logo

Comments (6)

danielTobon43 avatar danielTobon43 commented on August 15, 2024

Good day. I think may be the error is in the linking library part, try replacing:

##############################################################################
# TARGET LIBRARIES
##############################################################################
target_link_libraries(${PROJECT_NAME}  ${PCL_COMMON_LIBRARIES} ${PCL_IO_LIBRARIES} ${PCL_VISUALIZATION_LIBRARY})

with:

##############################################################################
# TARGET LIBRARIES
##############################################################################
target_link_libraries(${PROJECT_NAME}  ${PCL_LIBRARIES})

from dbscan-pcl-optimized.

danielTobon43 avatar danielTobon43 commented on August 15, 2024

By the way, the pcl build path should not end with "/", just: set(PCL_DIR /home/gz/pcl/release)

from dbscan-pcl-optimized.

defendergz avatar defendergz commented on August 15, 2024

hi!
thank u reply! after i modified cmakelist.txt:
in line 20:
Screenshot from 2019-04-27 16-13-13
and in line 89,added boost_system boost_filesystem ${PCL_LIBRARIES}:
Screenshot from 2019-04-27 16-14-18
i cmake .. && make correctly.and run this ./dbscan .......everything is ok.
but a few days later, it doesn't work.so i delete all dir/file in build.and recompile.
cmake .. is ok, but when run make, i got some error:
Scanning dependencies of target dbscan CMakeFiles/dbscan.dir/main.cpp.o: In function `readCloudFromFile(int, char**, std::vector<htr::Point3D, std::allocator<htr::Point3D> >&, boost::shared_ptr<pcl::PointCloud<pcl::PointXYZRGB> >&)': main.cpp:(.text+0x1322): undefined reference to `pcl::io::loadPolygonFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, pcl::PolygonMesh&)' collect2: error: ld returned 1 exit status CMakeFiles/dbscan.dir/build.make:366: recipe for target 'bin/dbscan' failed make[2]: *** [bin/dbscan] Error 1 CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/dbscan.dir/all' failed make[1]: *** [CMakeFiles/dbscan.dir/all] Error 2 Makefile:83: recipe for target 'all' failed make: *** [all] Error 2
could u plz help me fix it? thank u.

from dbscan-pcl-optimized.

danielTobon43 avatar danielTobon43 commented on August 15, 2024

Again, it is a problem of linking pcl correctly. I'm going to leave the general version of the CMakeList.txt project on GitHub. Go back to download again DBScan from the GitHub and try to compile it.

from dbscan-pcl-optimized.

danielTobon43 avatar danielTobon43 commented on August 15, 2024

When you compile the project with cmake, verify that the pcl include part (which is printed on the terminal) comes from your PCL_dir and not from the pcl of ROS

from dbscan-pcl-optimized.

danielTobon43 avatar danielTobon43 commented on August 15, 2024

If you use: ${PCL_LIBRARIES} it is not necessary the link to Boost library (pcl already does)

from dbscan-pcl-optimized.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.