liorf icon indicating copy to clipboard operation
liorf copied to clipboard

Catkin_make Error with liorf : Undefined References

Open sribru opened this issue 11 months ago • 1 comments

I ham having trouble while trying to catkin_make the repo by installing the correct versions of gtsam (4.0.2) and cmake(3.7.2) based on the the suggested solutions from LIOSAM and liorf issues

I have attached output log file below. ase path: /root/catkin_ws Source space: /root/catkin_ws/src Build space: /root/catkin_ws/build Devel space: /root/catkin_ws/devel Install space: /root/catkin_ws/install

Running command: "cmake /root/catkin_ws/src -DCATKIN_DEVEL_PREFIX=/root/catkin_ws/devel -DCMAKE_INSTALL_PREFIX=/root/catkin_ws/install -G Unix Makefiles" in "/root/catkin_ws/build"

-- The C compiler identification is GNU 5.4.0 -- The CXX compiler identification is GNU 5.4.0 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Using CATKIN_DEVEL_PREFIX: /root/catkin_ws/devel -- Using CMAKE_PREFIX_PATH: /opt/ros/kinetic -- This workspace overlays: /opt/ros/kinetic -- Found PythonInterp: /usr/bin/python2 (found suitable version "2.7.12", minimum required is "2") -- Using PYTHON_EXECUTABLE: /usr/bin/python2 -- Using Debian Python package layout -- Using empy: /usr/bin/empy -- Using CATKIN_ENABLE_TESTING: ON -- Call enable_testing() -- Using CATKIN_TEST_RESULTS_DIR: /root/catkin_ws/build/test_results -- Found gtest sources under '/usr/src/gmock': gtests will be built -- Found gmock sources under '/usr/src/gmock': gmock will be built -- Found PythonInterp: /usr/bin/python2 (found version "2.7.12") -- Looking for pthread.h -- Looking for pthread.h - found -- Looking for pthread_create -- Looking for pthread_create - not found -- Looking for pthread_create in pthreads -- Looking for pthread_create in pthreads - not found -- Looking for pthread_create in pthread -- Looking for pthread_create in pthread - found -- Found Threads: TRUE
-- Using Python nosetests: /usr/bin/nosetests-2.7 -- catkin 0.7.29 -- BUILD_SHARED_LIBS is on -- BUILD_SHARED_LIBS is on -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -- ~~ traversing 1 packages in topological order: -- ~~ - liorf -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -- +++ processing catkin package: 'liorf' -- ==> add_subdirectory(liorf) -- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy -- Try OpenMP C flag = [-fopenmp] -- Performing Test OpenMP_FLAG_DETECTED -- Performing Test OpenMP_FLAG_DETECTED - Success -- Try OpenMP CXX flag = [-fopenmp] -- Performing Test OpenMP_FLAG_DETECTED -- Performing Test OpenMP_FLAG_DETECTED - Success -- Found OpenMP: -fopenmp
-- Checking for module 'eigen3' -- Found eigen3, version 3.2.92 -- Found eigen: /usr/include/eigen3
-- Checking for module 'flann' -- Found flann, version 1.8.4 -- Found Flann: /usr/lib/x86_64-linux-gnu/libflann_cpp_s.a
-- Checking for module 'libopenni' -- Found libopenni, version 1.5.4.0 -- Found openni: /usr/lib/libOpenNI.so
-- Checking for module 'libopenni2' -- No package 'libopenni2' found -- Could NOT find OpenNI2 (missing: OPENNI2_LIBRARY OPENNI2_INCLUDE_DIRS) -- The imported target "vtkRenderingPythonTkWidgets" references the file "/usr/lib/x86_64-linux-gnu/libvtkRenderingPythonTkWidgets.so" but this file does not exist. Possible reasons include:

  • The file was deleted, renamed, or moved to another location.
  • An install or uninstall procedure did not complete successfully.
  • The installation package was faulty and contained "/usr/lib/cmake/vtk-6.2/VTKTargets.cmake" but not all the files it references.

-- The imported target "vtk" references the file "/usr/bin/vtk" but this file does not exist. Possible reasons include:

  • The file was deleted, renamed, or moved to another location.
  • An install or uninstall procedure did not complete successfully.
  • The installation package was faulty and contained "/usr/lib/cmake/vtk-6.2/VTKTargets.cmake" but not all the files it references.

-- LIBUSB_1_LIBRARY (missing: LIBUSB_1_INCLUDE_DIR) -- Checking for module 'libopenni2' -- No package 'libopenni2' found -- Could NOT find OpenNI2 (missing: OPENNI2_LIBRARY OPENNI2_INCLUDE_DIRS) -- Found qhull: /usr/lib/x86_64-linux-gnu/libqhull.so
-- Found PCL_COMMON: /usr/lib/x86_64-linux-gnu/libpcl_common.so
-- Found PCL_KDTREE: /usr/lib/x86_64-linux-gnu/libpcl_kdtree.so
-- Found PCL_OCTREE: /usr/lib/x86_64-linux-gnu/libpcl_octree.so
-- Found PCL_SEARCH: /usr/lib/x86_64-linux-gnu/libpcl_search.so
-- Found PCL_SAMPLE_CONSENSUS: /usr/lib/x86_64-linux-gnu/libpcl_sample_consensus.so
-- Found PCL_FILTERS: /usr/lib/x86_64-linux-gnu/libpcl_filters.so
-- Found PCL_FEATURES: /usr/lib/x86_64-linux-gnu/libpcl_features.so
-- Found PCL_KEYPOINTS: /usr/lib/x86_64-linux-gnu/libpcl_keypoints.so
-- Found PCL_IO: /usr/lib/x86_64-linux-gnu/libpcl_io.so
-- Found PCL_GEOMETRY: /usr/include/pcl-1.7
-- Found PCL_VISUALIZATION: /usr/lib/x86_64-linux-gnu/libpcl_visualization.so
-- Found PCL_SEGMENTATION: /usr/lib/x86_64-linux-gnu/libpcl_segmentation.so
-- Found PCL_PEOPLE: /usr/lib/x86_64-linux-gnu/libpcl_people.so
-- Found PCL_SURFACE: /usr/lib/x86_64-linux-gnu/libpcl_surface.so
-- Found PCL_REGISTRATION: /usr/lib/x86_64-linux-gnu/libpcl_registration.so
-- Found PCL_TRACKING: /usr/lib/x86_64-linux-gnu/libpcl_tracking.so
-- Found PCL_RECOGNITION: /usr/lib/x86_64-linux-gnu/libpcl_recognition.so
-- Could NOT find PCL_APPS (missing: PCL_APPS_LIBRARY) -- Found PCL_IN_HAND_SCANNER: /usr/include/pcl-1.7
-- Found PCL_MODELER: /usr/include/pcl-1.7
-- Found PCL_POINT_CLOUD_EDITOR: /usr/include/pcl-1.7
-- Found PCL_OUTOFCORE: /usr/lib/x86_64-linux-gnu/libpcl_outofcore.so
-- Boost version: 1.58.0 -- Found the following Boost libraries: -- serialization -- system -- filesystem -- thread -- program_options -- date_time -- timer -- chrono -- regex -- atomic -- GTSAM include directory: /usr/local/lib/cmake/GTSAM/../../../include -- Boost version: 1.58.0 -- Found the following Boost libraries: -- timer -- chrono -- system -- Reading /home/linuxbrew/.linuxbrew/lib/cmake/GeographicLib/geographiclib-config.cmake -- GeographicLib configuration, version 2.3 -- ${{GeographicLib_LIBRARIES}} set to shared library -- liorf: 1 messages, 1 services CMake Warning at /opt/ros/kinetic/share/catkin/cmake/catkin_package.cmake:166 (message): catkin_package() DEPENDS on 'GTSAM' but neither 'GTSAM_INCLUDE_DIRS' nor 'GTSAM_LIBRARIES' is defined. Call Stack (most recent call first): /opt/ros/kinetic/share/catkin/cmake/catkin_package.cmake:102 (_catkin_package) liorf/CMakeLists.txt:54 (catkin_package)

-- Configuring done CMake Warning at liorf/CMakeLists.txt:99 (add_executable): Cannot generate a safe runtime search path for target liorf_mapOptmization because files in some directories may conflict with libraries in implicit directories:

runtime library [libz.so.1] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
  /home/linuxbrew/.linuxbrew/lib

Some of these libraries may not be found correctly.

-- Generating done -- Build files have been written to: /root/catkin_ws/build

Running command: "make -j32 -l32" in "/root/catkin_ws/build"

Scanning dependencies of target tf2_msgs_generate_messages_py Scanning dependencies of target _liorf_generate_messages_check_deps_save_map Scanning dependencies of target nav_msgs_generate_messages_cpp Scanning dependencies of target geometry_msgs_generate_messages_cpp Scanning dependencies of target sensor_msgs_generate_messages_cpp Scanning dependencies of target _liorf_generate_messages_check_deps_cloud_info Scanning dependencies of target liorf_imuPreintegration Scanning dependencies of target std_msgs_generate_messages_cpp Scanning dependencies of target visualization_msgs_generate_messages_nodejs Scanning dependencies of target visualization_msgs_generate_messages_py Scanning dependencies of target nav_msgs_generate_messages_eus Scanning dependencies of target nav_msgs_generate_messages_nodejs Scanning dependencies of target nav_msgs_generate_messages_lisp Scanning dependencies of target visualization_msgs_generate_messages_cpp Scanning dependencies of target visualization_msgs_generate_messages_lisp Scanning dependencies of target pcl_msgs_generate_messages_lisp Scanning dependencies of target pcl_msgs_generate_messages_py Scanning dependencies of target pcl_msgs_generate_messages_nodejs Scanning dependencies of target pcl_msgs_generate_messages_cpp Scanning dependencies of target rosgraph_msgs_generate_messages_eus Scanning dependencies of target tf2_msgs_generate_messages_cpp Scanning dependencies of target pcl_msgs_generate_messages_eus Scanning dependencies of target tf_generate_messages_cpp Scanning dependencies of target rosgraph_msgs_generate_messages_lisp Scanning dependencies of target actionlib_generate_messages_eus Scanning dependencies of target roscpp_generate_messages_nodejs Scanning dependencies of target tf_generate_messages_eus Scanning dependencies of target roscpp_generate_messages_eus [ 0%] Built target tf2_msgs_generate_messages_py Scanning dependencies of target std_msgs_generate_messages_eus Scanning dependencies of target roscpp_generate_messages_lisp [ 0%] Built target geometry_msgs_generate_messages_cpp Scanning dependencies of target rosgraph_msgs_generate_messages_cpp [ 0%] Built target nav_msgs_generate_messages_cpp [ 0%] Built target sensor_msgs_generate_messages_cpp [ 0%] Built target visualization_msgs_generate_messages_py [ 0%] Built target std_msgs_generate_messages_cpp Scanning dependencies of target rosgraph_msgs_generate_messages_py [ 0%] Built target visualization_msgs_generate_messages_nodejs [ 0%] Built target nav_msgs_generate_messages_nodejs [ 0%] Built target nav_msgs_generate_messages_lisp [ 0%] Built target nav_msgs_generate_messages_eus [ 0%] Built target pcl_msgs_generate_messages_py [ 0%] Built target pcl_msgs_generate_messages_lisp [ 0%] Built target visualization_msgs_generate_messages_lisp [ 0%] Built target tf2_msgs_generate_messages_cpp [ 0%] Built target visualization_msgs_generate_messages_cpp [ 0%] Built target pcl_msgs_generate_messages_cpp [ 0%] Built target pcl_msgs_generate_messages_nodejs [ 0%] Built target tf_generate_messages_eus [ 0%] Built target actionlib_generate_messages_eus [ 0%] Built target rosgraph_msgs_generate_messages_eus [ 0%] Built target pcl_msgs_generate_messages_eus [ 0%] Built target roscpp_generate_messages_nodejs [ 0%] Built target rosgraph_msgs_generate_messages_lisp [ 0%] Built target tf_generate_messages_cpp [ 0%] Built target roscpp_generate_messages_lisp [ 0%] Built target roscpp_generate_messages_eus [ 0%] Built target std_msgs_generate_messages_eus [ 0%] Built target rosgraph_msgs_generate_messages_cpp [ 0%] Built target rosgraph_msgs_generate_messages_py Scanning dependencies of target tf_generate_messages_lisp Scanning dependencies of target std_msgs_generate_messages_lisp Scanning dependencies of target geometry_msgs_generate_messages_lisp Scanning dependencies of target tf_generate_messages_py Scanning dependencies of target geometry_msgs_generate_messages_py Scanning dependencies of target tf2_msgs_generate_messages_nodejs Scanning dependencies of target roscpp_generate_messages_cpp Scanning dependencies of target std_msgs_generate_messages_nodejs Scanning dependencies of target geometry_msgs_generate_messages_eus Scanning dependencies of target actionlib_msgs_generate_messages_py Scanning dependencies of target roscpp_generate_messages_py Scanning dependencies of target tf_generate_messages_nodejs Scanning dependencies of target std_msgs_generate_messages_py Scanning dependencies of target sensor_msgs_generate_messages_nodejs Scanning dependencies of target nav_msgs_generate_messages_py Scanning dependencies of target geometry_msgs_generate_messages_nodejs Scanning dependencies of target rosgraph_msgs_generate_messages_nodejs Scanning dependencies of target tf2_msgs_generate_messages_lisp Scanning dependencies of target sensor_msgs_generate_messages_lisp Scanning dependencies of target sensor_msgs_generate_messages_py Scanning dependencies of target actionlib_generate_messages_cpp Scanning dependencies of target sensor_msgs_generate_messages_eus Scanning dependencies of target actionlib_msgs_generate_messages_cpp [ 0%] Built target std_msgs_generate_messages_lisp Scanning dependencies of target actionlib_generate_messages_nodejs [ 0%] Built target geometry_msgs_generate_messages_lisp [ 0%] Built target tf_generate_messages_py [ 0%] Built target tf_generate_messages_lisp Scanning dependencies of target actionlib_generate_messages_py Scanning dependencies of target actionlib_generate_messages_lisp [ 0%] Built target geometry_msgs_generate_messages_py Scanning dependencies of target actionlib_msgs_generate_messages_eus [ 0%] Built target roscpp_generate_messages_cpp [ 0%] Built target tf2_msgs_generate_messages_nodejs [ 0%] Built target std_msgs_generate_messages_nodejs Scanning dependencies of target actionlib_msgs_generate_messages_lisp [ 0%] Built target geometry_msgs_generate_messages_eus [ 0%] Built target actionlib_msgs_generate_messages_py [ 0%] Built target roscpp_generate_messages_py Scanning dependencies of target visualization_msgs_generate_messages_eus [ 0%] Built target sensor_msgs_generate_messages_nodejs [ 0%] Built target std_msgs_generate_messages_py [ 0%] Built target nav_msgs_generate_messages_py [ 0%] Built target rosgraph_msgs_generate_messages_nodejs [ 0%] Built target geometry_msgs_generate_messages_nodejs [ 0%] Built target sensor_msgs_generate_messages_lisp [ 0%] Built target tf2_msgs_generate_messages_lisp [ 0%] Built target sensor_msgs_generate_messages_py [ 0%] Built target actionlib_generate_messages_nodejs [ 0%] Built target actionlib_msgs_generate_messages_cpp [ 0%] Built target sensor_msgs_generate_messages_eus [ 0%] Built target actionlib_generate_messages_cpp [ 0%] Built target actionlib_generate_messages_lisp [ 0%] Built target tf_generate_messages_nodejs [ 0%] Built target actionlib_generate_messages_py [ 0%] Built target actionlib_msgs_generate_messages_eus [ 0%] Built target actionlib_msgs_generate_messages_lisp [ 0%] Built target visualization_msgs_generate_messages_eus Scanning dependencies of target tf2_msgs_generate_messages_eus Scanning dependencies of target _catkin_empty_exported_target Scanning dependencies of target actionlib_msgs_generate_messages_nodejs [ 0%] Built target _liorf_generate_messages_check_deps_save_map [ 0%] Built target tf2_msgs_generate_messages_eus [ 0%] Built target _liorf_generate_messages_check_deps_cloud_info [ 0%] Built target _catkin_empty_exported_target [ 0%] Built target actionlib_msgs_generate_messages_nodejs Scanning dependencies of target liorf_generate_messages_cpp Scanning dependencies of target liorf_generate_messages_lisp Scanning dependencies of target liorf_generate_messages_nodejs Scanning dependencies of target liorf_generate_messages_py Scanning dependencies of target liorf_generate_messages_eus [ 4%] Generating Lisp code from liorf/cloud_info.msg [ 13%] Generating Lisp code from liorf/save_map.srv [ 13%] Generating C++ code from liorf/save_map.srv [ 17%] Generating Javascript code from liorf/cloud_info.msg [ 21%] Generating Python from MSG liorf/cloud_info [ 26%] Generating C++ code from liorf/cloud_info.msg [ 30%] Generating EusLisp code from liorf/cloud_info.msg [ 34%] Generating Javascript code from liorf/save_map.srv [ 39%] Generating Python code from SRV liorf/save_map [ 43%] Generating EusLisp code from liorf/save_map.srv [ 47%] Generating EusLisp manifest code for liorf [ 47%] Built target liorf_generate_messages_nodejs [ 47%] Built target liorf_generate_messages_lisp [ 56%] Generating Python srv init.py for liorf [ 56%] Generating Python msg init.py for liorf [ 60%] Building CXX object liorf/CMakeFiles/liorf_imuPreintegration.dir/src/imuPreintegration.cpp.o [ 65%] Building CXX object liorf/CMakeFiles/liorf_imuPreintegration.dir/lib/common_lib.cpp.o [ 65%] Built target liorf_generate_messages_cpp Scanning dependencies of target liorf_imageProjection Scanning dependencies of target liorf_mapOptmization :0:15: warning: ISO C++11 requires whitespace after the macro name :0:15: warning: ISO C++11 requires whitespace after the macro name [ 65%] Built target liorf_generate_messages_py [ 73%] Building CXX object liorf/CMakeFiles/liorf_imageProjection.dir/src/imageProjection.cpp.o [ 73%] Building CXX object liorf/CMakeFiles/liorf_imageProjection.dir/lib/common_lib.cpp.o :0:15: warning: ISO C++11 requires whitespace after the macro name :0:15: warning: ISO C++11 requires whitespace after the macro name [ 82%] Building CXX object liorf/CMakeFiles/liorf_mapOptmization.dir/lib/common_lib.cpp.o [ 82%] Building CXX object liorf/CMakeFiles/liorf_mapOptmization.dir/src/mapOptmization.cpp.o [ 86%] Building CXX object liorf/CMakeFiles/liorf_mapOptmization.dir/include/Scancontext.cpp.o :0:15: warning: ISO C++11 requires whitespace after the macro name :0:15: warning: ISO C++11 requires whitespace after the macro name :0:15: warning: ISO C++11 requires whitespace after the macro name [ 86%] Built target liorf_generate_messages_eus Scanning dependencies of target liorf_generate_messages [ 86%] Built target liorf_generate_messages /root/catkin_ws/src/liorf/include/Scancontext.cpp: In function ‘float xy2theta(const float&, const float&)’: /root/catkin_ws/src/liorf/include/Scancontext.cpp:36:1: warning: control reaches end of non-void function [-Wreturn-type] } // xy2theta ^ /root/catkin_ws/src/liorf/src/mapOptmization.cpp: In member function ‘bool mapOptimization::saveMapService(liorf::save_mapRequest&, liorf::save_mapResponse&)’: /root/catkin_ws/src/liorf/src/mapOptmization.cpp:389:11: warning: variable ‘unused’ set but not used [-Wunused-but-set-variable] int unused = system((std::string("exec rm -r ") + saveMapDirectory).c_str()); ^ /root/catkin_ws/src/liorf/src/mapOptmization.cpp: In member function ‘void mapOptimization::performSCLoopClosure()’: /root/catkin_ws/src/liorf/src/mapOptmization.cpp:639:15: warning: unused variable ‘yawDiffRad’ [-Wunused-variable] float yawDiffRad = detectResult.second; // not use for v1 (because pcl icp withi initial somthing wrong...) ^ /root/catkin_ws/src/liorf/src/mapOptmization.cpp: In member function ‘void mapOptimization::publishFrames()’: /root/catkin_ws/src/liorf/src/mapOptmization.cpp:1768:37: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (lastSLAMInfoPubSize != cloudKeyPoses6D->size()) ^ [ 91%] Linking CXX executable /root/catkin_ws/devel/lib/liorf/liorf_imageProjection [ 91%] Built target liorf_imageProjection [ 95%] Linking CXX executable /root/catkin_ws/devel/lib/liorf/liorf_imuPreintegration [ 95%] Built target liorf_imuPreintegration [100%] Linking CXX executable /root/catkin_ws/devel/lib/liorf/liorf_mapOptmization /home/linuxbrew/.linuxbrew/lib/liblzma.so.5: undefined reference to pthread_condattr_setclock@GLIBC_2.34' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to hypot@GLIBC_2.35' /home/linuxbrew/.linuxbrew/lib/liblzma.so.5: undefined reference to pthread_create@GLIBC_2.34' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to __libc_single_threaded@GLIBC_2.32' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to log2@GLIBC_2.29' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to pow@GLIBC_2.29' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to exp2@GLIBC_2.29' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to exp@GLIBC_2.29' /home/linuxbrew/.linuxbrew/lib/liblzma.so.5: undefined reference to pthread_sigmask@GLIBC_2.32' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to hypotf@GLIBC_2.35' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to std::__throw_bad_array_new_length()@GLIBCXX_3.4.29' /home/linuxbrew/.linuxbrew/lib/libuuid.so.1: undefined reference to getrandom@GLIBC_2.25' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to log@GLIBC_2.29' /home/linuxbrew/.linuxbrew/lib/liblzma.so.5: undefined reference to pthread_join@GLIBC_2.34' /home/linuxbrew/.linuxbrew/lib/libGeographicLib.so.26.0.0: undefined reference to `expf@GLIBC_2.27' collect2: error: ld returned 1 exit status liorf/CMakeFiles/liorf_mapOptmization.dir/build.make:506: recipe for target '/root/catkin_ws/devel/lib/liorf/liorf_mapOptmization' failed make[2]: *** [/root/catkin_ws/devel/lib/liorf/liorf_mapOptmization] Error 1 CMakeFiles/Makefile2:589: recipe for target 'liorf/CMakeFiles/liorf_mapOptmization.dir/all' failed make[1]: *** [liorf/CMakeFiles/liorf_mapOptmization.dir/all] Error 2 Makefile:138: recipe for target 'all' failed make: *** [all] Error 2 Invoking "make -j32 -l32" failed

sribru avatar Mar 18 '24 19:03 sribru

I'm sorry, I haven't encountered this problem

YJZLuckyBoy avatar Apr 29 '24 11:04 YJZLuckyBoy