docs: public static int linkShaderProgram(GL2 gl, int[] shaders) throws ShaderCompilationException {
      int[] error = new int[1];
      int shaderprogram = gl.glCreateProgram();
      for(int shader : shaders) {
        gl.glAttachShader(shaderprogram, shader);
      }
      gl.glLinkProgram(shaderprogram);
      gl.glValidateProgram(shaderprogram);
  
      // This worked best for me to get error messages:
      gl.glGetObjectParameterivARB(shaderprogram, GL2.GL_OBJECT_INFO_LOG_LENGTH_ARB, error, 0);
      if(error[0] > 1) {
        byte[] info = new byte[error[0]];
        gl.glGetInfoLogARB(shaderprogram, info.length, error, 0, info, 0);
        String out = new String(info);
        gl.glDeleteProgram(shaderprogram);
        throw new ShaderCompilationException("Shader compilation error: " + out);
      }
      return shaderprogram;
    }