opengles emulator: remove compilation warning.

There was very few compilation warning on Windows and Linux.
This change just fixes those warnings.

Change-Id: I0428aa3dd33b2add40aa6cd12da76910950533b8
diff --git a/tools/emulator/opengl/host/libs/GLESv1_dec/GLDecoder.cpp b/tools/emulator/opengl/host/libs/GLESv1_dec/GLDecoder.cpp
index e6ccbd9..5399445 100644
--- a/tools/emulator/opengl/host/libs/GLESv1_dec/GLDecoder.cpp
+++ b/tools/emulator/opengl/host/libs/GLESv1_dec/GLDecoder.cpp
@@ -38,7 +38,7 @@
 int GLDecoder::initGL(get_proc_func_t getProcFunc, void *getProcFuncData)
 {
     if (getProcFunc == NULL) {
-        char *libname = GLES_LIBNAME;
+        const char *libname = GLES_LIBNAME;
         if (getenv(GLES_LIBNAME_VAR) != NULL) {
             libname = getenv(GLES_LIBNAME_VAR);
         }
diff --git a/tools/emulator/opengl/host/libs/Translator/EGL/EglWindowsApi.cpp b/tools/emulator/opengl/host/libs/Translator/EGL/EglWindowsApi.cpp
index 4f8d4b4..0c6b0ee 100644
--- a/tools/emulator/opengl/host/libs/Translator/EGL/EglWindowsApi.cpp
+++ b/tools/emulator/opengl/host/libs/Translator/EGL/EglWindowsApi.cpp
@@ -428,7 +428,8 @@
    *width  = r.right  - r.left;
    *height = r.bottom - r.top;
    HDC dc = GetDC(win);
-   bool ret = SetPixelFormat(dc,cfg->nativeId(),&cfg->nativeConfig());
+   EGLNativePixelFormatType nativeConfig = cfg->nativeConfig();
+   bool ret = SetPixelFormat(dc,cfg->nativeId(),&nativeConfig);
    DeleteDC(dc);
    return ret;
 }
@@ -495,7 +496,8 @@
     HDC  dpy  = getDummyDC(display,cfg->nativeId());
 
     if(!display->isPixelFormatSet(cfg->nativeId())){
-        if(!SetPixelFormat(dpy,cfg->nativeId(),&cfg->nativeConfig())){
+        EGLNativePixelFormatType nativeConfig = cfg->nativeConfig();
+        if(!SetPixelFormat(dpy,cfg->nativeId(),&nativeConfig)){
             return NULL;
         }
         display->pixelFormatWasSet(cfg->nativeId());
diff --git a/tools/emulator/opengl/host/tools/emugen/ApiGen.cpp b/tools/emulator/opengl/host/tools/emugen/ApiGen.cpp
index 3df3107..113d13a 100644
--- a/tools/emulator/opengl/host/tools/emugen/ApiGen.cpp
+++ b/tools/emulator/opengl/host/tools/emugen/ApiGen.cpp
@@ -542,7 +542,7 @@
             classname.c_str(), m_basename.c_str(), sideString(SERVER_SIDE));
     fprintf(fp, "\tsize_t decode(void *buf, size_t bufsize, IOStream *stream);\n");
     fprintf(fp, "\n};\n\n");
-    fprintf(fp, "#endif");
+    fprintf(fp, "#endif\n");
 
     fclose(fp);
     return 0;