I have noticed that if one of my shaders can’t be compiled my application just crashes without any detailed messages. My investigation showed that the crash takes place in CCGLProgram::logForOpenGLObject during the invocation of infoFunc. Further investigation discovered that on the Windows platform (which I use for development and testing) glGetShaderiv uses __stdcall call convention, while GLInfoFunction uses default __cdecl. Moreover, it seems that with Windows’ version of glew there is no need to get the pointer to those GL-functions, thus instead of
return this->logForOpenGLObject(m_uVertShader, (GLInfoFunction)&glGetShaderiv, (GLLogFunction)&glGetShaderInfoLog);
it should be
return this->logForOpenGLObject(m_uVertShader, (GLInfoFunction)glGetShaderiv, (GLLogFunction)glGetShaderInfoLog);
I’d wish to make the fix by myself, but I have no Mac and iOS for testing the fix for cross-platform compatibility.