stereolabs/zed-openpose

/usr/lib/libgflags.so.2.2: error adding symbols: DSO missing from command line

alexismurari opened this issue · 2 comments

I am trying to build the program on a Jetson Nano with ubuntu 18.04.

Here you can find the output:

Consolidate compiler generated dependencies of target zed_openpose
[ 33%] Linking CXX executable zed_openpose
/usr/bin/ld: CMakeFiles/zed_openpose.dir/src/main.o: undefined reference to symbol ‘ZN6google14FlagRegistererC1IbEEPKcS3_S3_PT_S5’
//usr/lib/aarch64-linux-gnu/libgflags.so.2.2: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
CMakeFiles/zed_openpose.dir/build.make:144: recipe for target ‘zed_openpose’ failed
make[2]: *** [zed_openpose] Error 1
CMakeFiles/Makefile2:82: recipe for target ‘CMakeFiles/zed_openpose.dir/all’ failed
make[1]: *** [CMakeFiles/zed_openpose.dir/all] Error 2
Makefile:90: recipe for target ‘all’ failed
make: *** [all] Error 2

I tried to reinstall caffe and gflags but I am still getting the same issue.

Thank you for your help and time.

Hi,
the ${GFLAGS_LIBRARY} probably does not contains the gflags library in the CMakeList.txt here :
https://github.com/stereolabs/zed-openpose/blob/master/CMakeLists.txt#L47

You can add directly gflags in the list of library in the target link like this :

target_link_libraries(${execName}
                        ${OpenPose_LIBS} ${GLOG_LIBRARY} gflags ${GFLAGS_LIBRARY} ${Caffe_LIBS}
                        ${ZED_LIBRARIES}
                        ${GLUT_LIBRARY}
                        ${GLEW_LIBRARIES}
                        ${SPECIAL_OS_LIBS}
                        ${OPENGL_LIBRARIES}
                        ${OpenCV_LIBRARIES}
                        ${CUDA_CUDA_LIBRARY} ${CUDA_CUDART_LIBRARY} ${CUDA_NPP_LIBRARIES_ZED} )

This should work.

It worked!

Thank you for your help!