Hello Kashyap, you're doing some serious work to make everything run under Docker, thank you!
The problem still seems to be OpenGL. You said that only demos 1 to 3 run. Demo 1-3 tell SDL2 to open a window with an associated renderer (+RenderWindow from sdlutil.l), but from demo 4 onwards a window with an OpenGL context is requested (+OpenGLWindow from sdlopengl.l). The required OpenGL version is 3.3 or higher. Otherwise the shaders won't compile. I have updated the code of demo 4. Now the window is created with "(new '(+OpenGLWindow) "SDL Test 4" 400 400 3 3)", so that SDL2 is free to choose a valid visual without any requirements. The demo runs fine on my Linux PC. Can you run a quick test with demo 4 and report if it works now, please?