From: Ian Romanick Date: Thu, 12 May 2016 01:24:32 +0000 (-0700) Subject: glsl: Allow shader interface blocks in GLSL ES X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=660240da9e801c5e62ecce373464290ae1048c70;p=mesa.git glsl: Allow shader interface blocks in GLSL ES Signed-off-by: Ian Romanick Reviewed-by: Timothy Arceri Reviewed-by: Alejandro PiƱeiro --- diff --git a/src/compiler/glsl/glsl_parser_extras.cpp b/src/compiler/glsl/glsl_parser_extras.cpp index 916fca83e22..843998dc9fc 100644 --- a/src/compiler/glsl/glsl_parser_extras.cpp +++ b/src/compiler/glsl/glsl_parser_extras.cpp @@ -895,10 +895,16 @@ _mesa_ast_process_interface_block(YYLTYPE *locp, "required for defining uniform blocks"); } } else { - if (state->es_shader || state->language_version < 150) { - _mesa_glsl_error(locp, state, - "#version 150 required for using " - "interface blocks"); + if (!state->has_shader_io_blocks()) { + if (state->es_shader) { + _mesa_glsl_error(locp, state, + "GL_OES_shader_io_blocks or #version 320 " + "required for using interface blocks"); + } else { + _mesa_glsl_error(locp, state, + "#version 150 required for using " + "interface blocks"); + } } }