egl: Don't use SDL_LoadFunction to get GL entry points on Emscripten.

This results in a dlsym() call, which causes Emscripten to panic if the game
wasn't explicitly built dlopen support. eglGetProcAddress works just fine on
this platform, so just let that codepath handle it.

--HG--
extra : rebase_source : 7cf75ced6741da7762b0bbe8e86c8ab4c70dcbd3
diff --git a/src/video/SDL_egl.c b/src/video/SDL_egl.c
index a8a1485..189ae63 100644
--- a/src/video/SDL_egl.c
+++ b/src/video/SDL_egl.c
@@ -231,6 +231,7 @@
         retval = _this->egl_data->eglGetProcAddress(proc);
     }
 
+    #ifndef __EMSCRIPTEN__  /* LoadFunction isn't needed on Emscripten and will call dlsym(), causing other problems. */
     /* Try SDL_LoadFunction() first for EGL <= 1.4, or as a fallback for >= 1.5. */
     if (!retval) {
         static char procname[64];
@@ -242,8 +243,9 @@
             retval = SDL_LoadFunction(_this->egl_data->egl_dll_handle, procname);
         }
     }
+    #endif
 
-    /* Try eglGetProcAddress if we on <= 1.4 and still searching... */
+    /* Try eglGetProcAddress if we're on <= 1.4 and still searching... */
     if (!retval && !is_egl_15_or_later && _this->egl_data->eglGetProcAddress) {
         retval = _this->egl_data->eglGetProcAddress(proc);
         if (retval) {