wflinfo: Make wflinfo understand OpenGL 3.1 profiles

Strictly speaking, an OpenGL 3.1 context has no profile. But if the user
calls wflinfo like below...
    wflinfo --api=gl --version=3.1
    wflinfo --api=gl --version=3.1 --profile=none
    wflinfo --api=gl --version=3.1 --profile=core
    wflinfo --api=gl --version=3.1 --profile=compat
then we know what they way. Make wflinfo do what the user wants.

Likewise, if the user provided a profile but no version, like this...
    wflinfo --api=gl --profile=core
    wflinfo --api=gl --profile=compat
then wflinfo iterated over OpenGL context versions from 4.4 to 3.2 in
search of the given profile. Because wflinfo now understands 3.1
profiles, it iterates down to 3.1.

Because OpenGL 3.1 contexts don't have true profiles, this patch adds
gobs of special case code to pretend they do.

Fixes: https://github.com/waffle-gl/waffle/issues/4
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
glx: Set waffle_error when glXMakeCurrent fails

Jordan found this because `wflinfo -p glx -a gl -V 3.1 --profile=core`
failed on NVidia with this unhelpful message:
"Waffle error: 0x0 WAFFLE_NO_ERROR".

Reported-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>