glx/dri2: print FPS when env var LIBGL_SHOW_FPS is 1 (v2)
glx/dri2: print FPS when env var LIBGL_SHOW_FPS is 1 (v2)

This is useful for apps which don't print FPS.
Only enabled in SwapBuffers.

v2: track state per drawable, use libGL prefix

Reviewed-by: Michel Dänzer <2c7f9fd20fbeb41ce8894ec4653d66fa7f3b6e1a@daenzer.net>

metora/MesaGLSLCompiler,zz85/glsl-optimizer,mcanthony/glsl-optimizer,zeux/glsl-optimizer,dellis1972/glsl-optimizer,tokyovigilante/glsl-optimizer,mcanthony/glsl-optimizer,jbarczak/glsl-optimizer,zz85/glsl-optimizer,wolf96/glsl-optimizer,mcanthony/glsl-optimizer,mcanthony/glsl-optimizer,wolf96/glsl-optimizer,wolf96/glsl-optimizer,zz85/glsl-optimizer,zz85/glsl-optimizer,tokyovigilante/glsl-optimizer,benaadams/glsl-optimizer,jbarczak/glsl-optimizer,bkaradzic/glsl-optimizer,zz85/glsl-optimizer,dellis1972/glsl-optimizer,metora/MesaGLSLCompiler,tokyovigilante/glsl-optimizer,djreep81/glsl-optimizer,jbarczak/glsl-optimizer,benaadams/glsl-optimizer,tokyovigilante/glsl-optimizer,mapbox/glsl-optimizer,benaadams/glsl-optimizer,bkaradzic/glsl-optimizer,bkaradzic/glsl-optimizer,dellis1972/glsl-optimizer,zeux/glsl-optimizer,benaadams/glsl-optimizer,mapbox/glsl-optimizer,djreep81/glsl-optimizer,mapbox/glsl-optimizer,djreep81/glsl-optimizer,djreep81/glsl-optimizer,jbarczak/glsl-optimizer,zeux/glsl-optimizer,mapbox/glsl-optimizer,mapbox/glsl-optimizer,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,bkaradzic/glsl-optimizer,wolf96/glsl-optimizer,benaadams/glsl-optimizer,metora/MesaGLSLCompiler,dellis1972/glsl-optimizer,zeux/glsl-optimizer,zeux/glsl-optimizer,djreep81/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,bkaradzic/glsl-optimizer,jbarczak/glsl-optimizer,benaadams/glsl-optimizer,dellis1972/glsl-optimizer