debugging shaders is tricky.
really, the only way to do it is with gl_FragColor output value.
you can set this equal to different variables from the different stages of the shader.
for example the first thing i did was set the varying lightintensity equal to the spec value in the vertex shader.
then is i set gl_FragColor = vec4(lightintensity, lightintensity, lightintensity,1.0) and determined that the spec value was 0 (because the output was black).
however changing "clamp" to "max" was just a lucky guess.
i still have no idea why clamp was not working.