diff options
Diffstat (limited to 'meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts/0001-use-library-sonames-for-linking.patch')
| -rw-r--r-- | meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts/0001-use-library-sonames-for-linking.patch | 114 |
1 files changed, 114 insertions, 0 deletions
diff --git a/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts/0001-use-library-sonames-for-linking.patch b/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts/0001-use-library-sonames-for-linking.patch new file mode 100644 index 0000000000..f12abd0c1a --- /dev/null +++ b/meta-oe/recipes-graphics/vk-gl-cts/vulkan-cts/0001-use-library-sonames-for-linking.patch | |||
| @@ -0,0 +1,114 @@ | |||
| 1 | From acd25c4b8d5b7e420a7a89bdfd6551c70de828b3 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Trevor Woerner <twoerner@gmail.com> | ||
| 3 | Date: Thu, 23 Sep 2021 19:36:43 -0400 | ||
| 4 | Subject: [PATCH] use library sonames for linking | ||
| 5 | |||
| 6 | The recommended "best practices" for applications is to link to library | ||
| 7 | sonames (e.g. libGL.so.1) instead of library names (e.g. libGL.so). This | ||
| 8 | ensures that applications don't try to use libraries if an incompatible ABI | ||
| 9 | change occurs. | ||
| 10 | |||
| 11 | Upstream-Status: Submitted [https://github.com/KhronosGroup/VK-GL-CTS/pull/288] | ||
| 12 | Signed-off-by: Trevor Woerner <twoerner@gmail.com> | ||
| 13 | --- | ||
| 14 | framework/egl/egluGLContextFactory.cpp | 4 ++-- | ||
| 15 | framework/egl/wrapper/eglwLibrary.cpp | 2 +- | ||
| 16 | framework/platform/android/tcuAndroidPlatform.cpp | 2 +- | ||
| 17 | framework/platform/lnx/X11/tcuLnxX11EglDisplayFactory.cpp | 2 +- | ||
| 18 | .../platform/lnx/wayland/tcuLnxWaylandEglDisplayFactory.cpp | 2 +- | ||
| 19 | framework/platform/surfaceless/tcuSurfacelessPlatform.cpp | 6 +++--- | ||
| 20 | 6 files changed, 9 insertions(+), 9 deletions(-) | ||
| 21 | |||
| 22 | --- a/framework/egl/egluGLContextFactory.cpp | ||
| 23 | +++ b/framework/egl/egluGLContextFactory.cpp | ||
| 24 | @@ -63,7 +63,7 @@ using std::vector; | ||
| 25 | # if (DE_OS == DE_OS_WIN32) | ||
| 26 | # define DEQP_GLES2_LIBRARY_PATH "libGLESv2.dll" | ||
| 27 | # else | ||
| 28 | -# define DEQP_GLES2_LIBRARY_PATH "libGLESv2.so" | ||
| 29 | +# define DEQP_GLES2_LIBRARY_PATH "libGLESv2.so.2" | ||
| 30 | # endif | ||
| 31 | #endif | ||
| 32 | |||
| 33 | @@ -75,7 +75,7 @@ using std::vector; | ||
| 34 | # if (DE_OS == DE_OS_WIN32) | ||
| 35 | # define DEQP_OPENGL_LIBRARY_PATH "opengl32.dll" | ||
| 36 | # else | ||
| 37 | -# define DEQP_OPENGL_LIBRARY_PATH "libGL.so" | ||
| 38 | +# define DEQP_OPENGL_LIBRARY_PATH "libGL.so.1" | ||
| 39 | # endif | ||
| 40 | #endif | ||
| 41 | |||
| 42 | --- a/framework/egl/wrapper/eglwLibrary.cpp | ||
| 43 | +++ b/framework/egl/wrapper/eglwLibrary.cpp | ||
| 44 | @@ -148,7 +148,7 @@ DefaultLibrary::~DefaultLibrary (void) | ||
| 45 | const char* DefaultLibrary::getLibraryFileName (void) | ||
| 46 | { | ||
| 47 | #if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX) | ||
| 48 | - return "libEGL.so"; | ||
| 49 | + return "libEGL.so.1"; | ||
| 50 | #elif (DE_OS == DE_OS_WIN32) | ||
| 51 | return "libEGL.dll"; | ||
| 52 | #else | ||
| 53 | --- a/framework/platform/android/tcuAndroidPlatform.cpp | ||
| 54 | +++ b/framework/platform/android/tcuAndroidPlatform.cpp | ||
| 55 | @@ -57,7 +57,7 @@ static const eglu::NativeWindow::Capabil | ||
| 56 | class NativeDisplay : public eglu::NativeDisplay | ||
| 57 | { | ||
| 58 | public: | ||
| 59 | - NativeDisplay (void) : eglu::NativeDisplay(DISPLAY_CAPABILITIES), m_library("libEGL.so") {} | ||
| 60 | + NativeDisplay (void) : eglu::NativeDisplay(DISPLAY_CAPABILITIES), m_library("libEGL.so.1") {} | ||
| 61 | virtual ~NativeDisplay (void) {} | ||
| 62 | |||
| 63 | virtual EGLNativeDisplayType getLegacyNative (void) { return EGL_DEFAULT_DISPLAY; } | ||
| 64 | --- a/framework/platform/lnx/X11/tcuLnxX11EglDisplayFactory.cpp | ||
| 65 | +++ b/framework/platform/lnx/X11/tcuLnxX11EglDisplayFactory.cpp | ||
| 66 | @@ -75,7 +75,7 @@ class Library : public eglw::DefaultLibr | ||
| 67 | { | ||
| 68 | public: | ||
| 69 | Library (void) | ||
| 70 | - : eglw::DefaultLibrary("libEGL.so") | ||
| 71 | + : eglw::DefaultLibrary("libEGL.so.1") | ||
| 72 | { | ||
| 73 | } | ||
| 74 | |||
| 75 | --- a/framework/platform/lnx/wayland/tcuLnxWaylandEglDisplayFactory.cpp | ||
| 76 | +++ b/framework/platform/lnx/wayland/tcuLnxWaylandEglDisplayFactory.cpp | ||
| 77 | @@ -66,7 +66,7 @@ public: | ||
| 78 | EGL_PLATFORM_WAYLAND_KHR, | ||
| 79 | "EGL_KHR_platform_wayland") | ||
| 80 | , m_display (waylandDisplay) | ||
| 81 | - , m_library ("libEGL.so") {} | ||
| 82 | + , m_library ("libEGL.so.1") {} | ||
| 83 | |||
| 84 | ~Display(void) {} | ||
| 85 | wayland::Display& getWaylandDisplay (void) { return *m_display; } | ||
| 86 | --- a/framework/platform/surfaceless/tcuSurfacelessPlatform.cpp | ||
| 87 | +++ b/framework/platform/surfaceless/tcuSurfacelessPlatform.cpp | ||
| 88 | @@ -69,7 +69,7 @@ using std::vector; | ||
| 89 | |||
| 90 | // Default library names | ||
| 91 | #if !defined(DEQP_GLES2_LIBRARY_PATH) | ||
| 92 | -# define DEQP_GLES2_LIBRARY_PATH "libGLESv2.so" | ||
| 93 | +# define DEQP_GLES2_LIBRARY_PATH "libGLESv2.so.2" | ||
| 94 | #endif | ||
| 95 | |||
| 96 | #if !defined(DEQP_GLES3_LIBRARY_PATH) | ||
| 97 | @@ -77,7 +77,7 @@ using std::vector; | ||
| 98 | #endif | ||
| 99 | |||
| 100 | #if !defined(DEQP_OPENGL_LIBRARY_PATH) | ||
| 101 | -# define DEQP_OPENGL_LIBRARY_PATH "libGL.so" | ||
| 102 | +# define DEQP_OPENGL_LIBRARY_PATH "libGL.so.1" | ||
| 103 | #endif | ||
| 104 | |||
| 105 | #if !defined(DEQP_VULKAN_LIBRARY_PATH) | ||
| 106 | @@ -237,7 +237,7 @@ glu::RenderContext* ContextFactory::crea | ||
| 107 | } | ||
| 108 | |||
| 109 | EglRenderContext::EglRenderContext(const glu::RenderConfig& config, const tcu::CommandLine& cmdLine, const glu::RenderContext *sharedContext) | ||
| 110 | - : m_egl("libEGL.so") | ||
| 111 | + : m_egl("libEGL.so.1") | ||
| 112 | , m_contextType(config.type) | ||
| 113 | , m_eglDisplay(EGL_NO_DISPLAY) | ||
| 114 | , m_eglContext(EGL_NO_CONTEXT) | ||
