3dmm_basic icon indicating copy to clipboard operation
3dmm_basic copied to clipboard

make issue

Open soumabo opened this issue 7 years ago • 3 comments

Hi,

i got these errors when running make

../modules/CvGl/libCvGl.so : undefined reference to « gluPerspective » ../modules/CvGl/libCvGl.so : undefined reference to « gluProject » collect2: error: ld returned 1 exit status config/CMakeFiles/IRIS_3DMM.dir/build.make:251 : the recipe for the target « bin/IRIS_3DMM » has failed make: *** [bin/IRIS_3DMM] Erreur 1

any one have an idea ? Thank you

soumabo avatar May 30 '18 14:05 soumabo

the same problem do you solve it?

bettertang avatar Mar 01 '19 07:03 bettertang

I got the same problem, and I fixed it finally. The main problem is in the CvGl. Change the CMakeLists.txt in the CvGl fold:

  1. Add #########################################################

FIND GLUT

######################################################### find_package(GLUT REQUIRED) include_directories(${GLUT_INCLUDE_DIRS}) link_directories(${GLUT_LIBRARY_DIRS}) add_definitions(${GLUT_DEFINITIONS}) if(NOT GLUT_FOUND) message(ERROR " GLUT not found!") endif(NOT GLUT_FOUND)

#########################################################

FIND OPENGL

######################################################### find_package(OpenGL REQUIRED) include_directories(${OpenGL_INCLUDE_DIRS}) link_directories(${OpenGL_LIBRARY_DIRS}) message(WARNING "OpenGL_LIBRARY: ${OpenGL_LIBRARY_DIRS}")

2.Delete and Change Delete the sentence "target_link_libraries(CvGl ${OpenGL_LIBRARY_DIRS} ${GLUT_LIBRARY_DIRS} )" as "target_link_libraries(CvGl -lglut -lGLU -lGL)"

you can try it

lyx323 avatar May 06 '19 02:05 lyx323

Dear all,

In case you have an issue of compiling my code, I have updated the CMakeLists.txt of CvGL and added Docker support. Please check the updated README for more details.

Hope it help.

Best regards, Anh

anhttran avatar Jun 11 '19 23:06 anhttran