Yeah, this looks like a bug on our side too. Another workaround appears to be setting the binary retriveable hint to true with glProgramParameteri(prog, GL_PROGRAM_BINARY_RETRIEVABLE_HINT, GL_TRUE) before linking, which is recommended anyway. We'll go see if we can fix it to do something reasonable even if the hint is false.
Thank you for the reply!
But I do call glProgramParameteri(prog, GL_PROGRAM_BINARY_RETRIEVABLE_HINT, GL_TRUE) before the linking (see the attached source) and still glGetProgramiv(prog, GL_PROGRAM_BINARY_LENGTH, &v) gives 0 after the shaders are detached
I also call glProgramParameteri(prog, GL_PROGRAM_SEPARABLE, GL_TRUE), but this is not important. The bug happens with normal (non-separable) program objects too. I have tested the standard case where the program object is not separable and has one vertex- and one fragment shader - the bug persists.