Check for errors in GLSL shaders using glslandValidator

Please ignore the first 3 commits and instead review them in #956.