1)
In file included from main.cpp:8:0:
gluvi.h:10:10: fatal error: GL/glut.h: No such file or directory
#include <GL/glut.h> // ...when everyone else puts it here?
^~~~~~~~~~~
$ sudo apt-get install freeglut3-dev
2)
util.h: In function ‘double randhashd(unsigned int)’:
util.h:259:33: error: ‘UINT_MAX’ was not declared in this scope
{ return randhash(seed)/(double)UINT_MAX; }
#include <climits>
3)
array1.h: In constructor ‘Array1<T>::Array1(long unsigned int, const T*, long unsigned int)’:
array1.h:124:12: error: ‘memcpy’ is not a member of ‘std’
std::memcpy(data, data_, n*sizeof(T));
#include <cstring>
4) Does not find/recognize libGL
fincahuanaco@pisces:~/DRIVE/Research23/viscosity$ g++ testgl.cpp -lglut -lGLU -L/usr/lib -lGL
/usr/bin/ld: cannot find -lGL
collect2: error: ld returned 1 exit status
#Check symbolic link
#Update libGL link, first go to directory and update
$ cd /usr/lib/x86_64-linux-gnu
$ sudo ln -s libGL.so.1.7.0 libGL.so
#back to source directory and try again
fincahuanaco@pisces:~/DRIVE/Research23/viscosity$ ./a.out
References:
[1] First OpenGL code http://www.codebind.com/linux-tutorials/install-opengl-ubuntu-linux/
No comments:
Post a Comment