Undefined Reference Error Message

I’ve just started working with OpenGL, I use Dev C++ compiler,
I installed OpenGL as follows:

opengl32.dll,glu32.dll,gl32.dll>>>copied to System Dir
glut.h,gl.h,glu.h>>>copied to include dir
glu32.lib, opengl32.lib,glut32.lit >>>copied to lib directory

As trying to run first example of red-book,“hello.cpp”, I always face following error messages in Dev C++ compiler

undefined reference to “__glutInitWithExit@12”

It is notable that windows.h and glut.h are included.

So, where is the problem?


Possibly the compiler is not getting the pointer to this function.
I came across a post in this forum where they explain to get function pointers using some PFN… ( do not remember exactly).

Or the lib file containing the signature is not included. Try project and compiler settings first.