I'm not sure that my notes can fix your problem... but...
(in "main" function)
GL_DEPTH_BITS is not used for glClear (it's for glGetIntegerv that returns a value of number of bits containig depth buffer of current applied GL context)...
You can use "gl" and "glu" commands only after created and applied GL context (it's initializing by glutCreateWindow(...) on a GLUT API)... otherwise it gives you an error at glGetError() (!=0)...
Comparing of two pictures. my opinion is: "Depth buffer is not initialized (not exist) or you are using invalid parameters for visualizing the scene)..."
Check out your code (in "reshape" function):
"gluPerspective(45.0,w/h,0.0,5.0);"
Znear plane must be > 0 (make a modifications with it to 1.0)...
like this:
"gluPerspective(45.0,w/h,1.0,5.0);"
thank you very much it works very well now as u mentioned because of sending the wrong parameter to the gluPerspective routine the depth buffer was not initialized correctly.after i correct it.the model turned dark partly due to the light,but obviously the tire hided the component behind it that`s remarkable!

Find content
Not Telling