Re: [waffle] [PATCH] linux: Use full libGLES*.so.[12] SONAMEs

2015-06-02 Thread Emil Velikov
On 2 June 2015 at 18:13, Chad Versace chad.vers...@intel.com wrote:
 On Mon 01 Jun 2015, Michel Dänzer wrote:
 From: Michel Dänzer michel.daen...@amd.com

 The libGLES*.so symlinks are intended for the compile-time linker and
 not available everywhere at runtime.

 v2: * Continue using libGLES*.so on Android, the full SONAMEs aren't
   available there.
 * Remove stale comment line

 Signed-off-by: Michel Dänzer michel.daen...@amd.com

 Emil, does this patch look good to you?

It looks great - thanks Michel ! Perhaps we should apply it to the
maint branches as well ?

Reviewed-by: Emil Velikov emil.l.veli...@gmail.com

-Emil
___
waffle mailing list
waffle@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/waffle


[waffle] [PATCH] linux: Use full libGLES*.so.[12] SONAMEs

2015-05-31 Thread Michel Dänzer
From: Michel Dänzer michel.daen...@amd.com

The libGLES*.so symlinks are intended for the compile-time linker and
not available everywhere at runtime.

v2: * Continue using libGLES*.so on Android, the full SONAMEs aren't
  available there.
* Remove stale comment line

Signed-off-by: Michel Dänzer michel.daen...@amd.com
---
 man/waffle_config.3.xml |  2 +-
 man/waffle_dl.3.xml |  6 +++---
 src/waffle/linux/linux_dl.c | 13 ++---
 3 files changed, 14 insertions(+), 7 deletions(-)

diff --git a/man/waffle_config.3.xml b/man/waffle_config.3.xml
index 8dc2fae..a8cb98d 100644
--- a/man/waffle_config.3.xml
+++ b/man/waffle_config.3.xml
@@ -535,7 +535,7 @@ struct waffle_config;
   itemizedlist
 listitem
   para
-GLX supports creation of an OpenGL ES2 context only if 
libGLESv2.so is installed and if
+GLX supports creation of an OpenGL ES2 context only if 
libGLESv2.so.2 is installed and if
 GLX_EXT_create_context_es2_profile is exposed as both 
a server and client extension.
   /para
 /listitem
diff --git a/man/waffle_dl.3.xml b/man/waffle_dl.3.xml
index 463081f..ffcfad4 100644
--- a/man/waffle_dl.3.xml
+++ b/man/waffle_dl.3.xml
@@ -72,9 +72,9 @@
 para
   For example, on Linux, the constantWAFFLE_DL_*/constant enums map to
   filenamelibGL.so.1/filename,
-  filenamelibGLESv1_CM.so/filename,
-  filenamelibGLESv2.so/filename, and
-  filenamelibGLESv2.so/filename, respectively.
+  filenamelibGLESv1_CM.so.1/filename,
+  filenamelibGLESv2.so.2/filename, and
+  filenamelibGLESv2.so.2/filename, respectively.
 /para
 
 variablelist
diff --git a/src/waffle/linux/linux_dl.c b/src/waffle/linux/linux_dl.c
index 1e14684..33eb69d 100644
--- a/src/waffle/linux/linux_dl.c
+++ b/src/waffle/linux/linux_dl.c
@@ -34,7 +34,7 @@
 #include linux_dl.h
 
 struct linux_dl {
-/// @brief For example, libGLESv2.so.
+/// @brief For example, libGLESv2.so.2.
 const char *name;
 
 /// @brief The library obtained with dlopen().
@@ -50,17 +50,24 @@ linux_dl_get_name(int32_t waffle_dl)
 case WAFFLE_DL_OPENGL:
 return libGL.so.1;
 case WAFFLE_DL_OPENGL_ES1:
+#ifdef WAFFLE_HAS_ANDROID
 return libGLESv1_CM.so;
+#else
+return libGLESv1_CM.so.1;
+#endif
 case WAFFLE_DL_OPENGL_ES2:
 case WAFFLE_DL_OPENGL_ES3:
 // As of 2014-04-20, Mesa statically provides the ES2 and ES3
-// symbols symbols in libGLESv2.so and provides no ES3-only library
+// symbols symbols in libGLESv2.so.2 and provides no ES3-only 
library
 // 
-// Even though Waffle does not use the library's soname, note that
 // Mesa did not change the library's soname when it added the ES3
 // symbols. The soname was and is libGLESv2.so.2 before and after
 // ES3.
+#ifdef WAFFLE_HAS_ANDROID
 return libGLESv2.so;
+#else
+return libGLESv2.so.2;
+#endif
 default:
 wcore_error_internal(waffle_dl has bad value %#x, waffle_dl);
 return NULL;
-- 
2.1.4

___
waffle mailing list
waffle@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/waffle