chili-epfl / attention-tracker

136 stars 97 forks source link

benchmark_head_pose_estimation_single_frame.cpp:(.text.startup+0x751): undefined reference to `USER_ERROR__missing_dlib_all_source_cpp_file__OR__inconsistent_use_of_DEBUG_or_ENABLE_ASSERTS_preprocessor_directives_' #21

Open tofisa opened 7 years ago

tofisa commented 7 years ago

Hi

I tried to build gazr . firstly there was problem in the cmake file . I changed this line in gazr cmakelists

find_package(dlib REQUIRED) include_directories(${dlib_INCLUDE_DIRS})

to set(DLIB_PATH "" CACHE PATH "Path to DLIB") include(/home/tofi/dlib/dlib/cmake)

cmake .. completed without errors . make showing this errors :

[ 1%] Built target gazr Linking CXX executable gazr_benchmark_head_pose_single_frame CMakeFiles/gazr_benchmark_head_pose_single_frame.dir/tools/benchmark_head_pose_estimation_single_frame.cpp.o: In function _GLOBAL__sub_I_main': benchmark_head_pose_estimation_single_frame.cpp:(.text.startup+0x751): undefined reference toUSER_ERROR__missing_dlib_all_source_cpp_fileORinconsistent_use_of_DEBUG_or_ENABLE_ASSERTS_preprocessordirectives' libgazr.so: undefined reference to dlib::base64::decode(std::istream&, std::ostream&) const' libgazr.so: undefined reference todlib::entropy_decoder_kernel_2::decode(unsigned int, unsigned int)' libgazr.so: undefined reference to dlib::entropy_decoder_kernel_2::set_stream(std::istream&)' libgazr.so: undefined reference todlib::base64::base64()' libgazr.so: undefined reference to dlib::entropy_decoder_kernel_2::get_target(unsigned int)' libgazr.so: undefined reference todlib::base64::~base64()' libgazr.so: undefined reference to dlib::entropy_decoder_kernel_2::~entropy_decoder_kernel_2()' libgazr.so: undefined reference todlib::entropy_decoder_kernel_2::entropy_decoder_kernel_2()' collect2: error: ld returned 1 exit status make[2]: [gazr_benchmark_head_pose_single_frame] Error 1 make[1]: [CMakeFiles/gazr_benchmark_head_pose_single_frame.dir/all] Error 2 make: *** [all] Error 2

severin-lemaignan commented 7 years ago

You should not need to change anything in the CMakeLists. Just make sure dlib is correctly installed (on Ubuntu/Debian, you can simply sudo apt install libdlib-dev)

tofisa commented 7 years ago

I installed dlib manually , and it is working ubunto 14.

sudo apt install libdlib-dev shows E: Unable to locate package libdlib-dev. Also attention tracker runs without problems