From: Ian Romanick Date: Fri, 24 Jan 2014 02:26:29 +0000 (-0800) Subject: linker: Allow geometry shader without vertex shader for separable programs X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c557eb77225433fa9415a94fc9db3ce36374df64;p=mesa.git linker: Allow geometry shader without vertex shader for separable programs Signed-off-by: Ian Romanick Reviewed-by: Eric Anholt --- diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index de7e3cde07a..fbc03587765 100644 --- a/src/glsl/linker.cpp +++ b/src/glsl/linker.cpp @@ -2300,7 +2300,8 @@ link_shaders(struct gl_context *ctx, struct gl_shader_program *prog) /* Geometry shaders have to be linked with vertex shaders. */ if (num_shaders[MESA_SHADER_GEOMETRY] > 0 && - num_shaders[MESA_SHADER_VERTEX] == 0) { + num_shaders[MESA_SHADER_VERTEX] == 0 && + !prog->SeparateShader) { linker_error(prog, "Geometry shader must be linked with " "vertex shader\n"); goto done;