commit 28ca626eda5c331d94ad96b9e67f0b98177a9dbf Author: Emmanuele Bassi Date: Sat Feb 24 14:07:18 2018 +0000 tests: Add EGL test for Epoxy API We have a few public entry points that we ought to test properly. Using the EGL API is easier to set up a test case, so let's just do that. test/Makefile.am | 3 ++ test/egl_epoxy_api.c | 143 +++++++++++++++++++++++++++++++++++++++++++++++++++ test/meson.build | 1 + 3 files changed, 147 insertions(+) commit e1ffd32d83d87c2bd90812f20344f253139d5c1b Author: Emmanuele Bassi Date: Sat Feb 24 14:03:06 2018 +0000 Support encoding minor versions bigger than 10 The GL version minor numbers haven't hit 10, yet, but if they do we're going to get non-sensical encoded versions when calling epoxy_gl_version(), like we're getting right now, with the GLSL version numbers. If the minor number is larger than the multiplication factor used for the major number, we should bump up the factor to the next order of magnitude. src/dispatch_common.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) commit 1489c20770f882e2cf778190269d4abab5cc018e Author: Emmanuele Bassi Date: Sat Feb 24 14:01:46 2018 +0000 meson: Use get_supported_arguments() Instead of iterating over the list of compiler flags, we should use the get_supported_arguments() method of the compiler object, which does it for us — and maybe, in the future, will be optimised to do the checks in parallel. meson.build | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) commit 60bb7672c10494aa6521ba3a157989cccc3490a2 Author: Emmanuele Bassi Date: Sat Feb 24 13:39:16 2018 +0000 Fix epoxy_internal_gl_version() The glGetString() function takes a GLenum, so we should too. src/dispatch_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 309142f2443327b9824e49b751e954f1e39db294 Author: Emmanuele Bassi Date: Fri Feb 23 20:07:24 2018 +0000 ci: Update the version of Meson for Appveyor We require a newer version than 0.39.1. .appveyor.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) commit f6d2b1f6adce7ab86f44705889b0fafe6e91ffed Author: Emmanuele Bassi Date: Fri Feb 23 19:59:48 2018 +0000 Do not use OPENGL_LIB on Android When building on Android we end up in the Linux branch of the symbol loading logic, but the __ANDROID__ conditional does not have the OPENGL_LIB symbol defined, and that breaks the build. Closes: #152 src/dispatch_common.c | 2 ++ 1 file changed, 2 insertions(+) commit 158ce2bc816097adff5a9e2506b42a788b47c631 Author: Emmanuele Bassi Date: Fri Feb 23 16:56:52 2018 +0000 Document epoxy_set_resolver_failure_handler() src/dispatch_common.c | 7 +++++++ 1 file changed, 7 insertions(+) commit d8726f265e53ce6a1d5f11a1d261e2f8957f7c62 Author: Emmanuele Bassi Date: Fri Feb 23 16:46:55 2018 +0000 Add epoxy_glsl_version() Epoxy should provide a function that returns the version of the GL shading language in use, in the same vein as it allows to get the version of GL. Closes: #145 include/epoxy/gl.h | 1 + src/dispatch_common.c | 33 +++++++++++++++++++++++++++++---- 2 files changed, 30 insertions(+), 4 deletions(-) commit a7c3178f86afa016ddeed8ebbb668ec308b71122 Author: Emmanuele Bassi Date: Fri Feb 23 15:51:56 2018 +0000 meson: Rename the configuration options The `enable-` prefix is an Autotool-ism; idiomatic naming for Meson projects should just use the name of the option, and rely on the type to convey meaning, especially because Meson does not have `disable` aliases that avoid the explicit `enable-foo=no` cases. .travis.yml | 5 +++-- meson.build | 6 +++--- meson_options.txt | 6 +++--- 3 files changed, 9 insertions(+), 8 deletions(-) commit c794dce0a088235344851e81511c6c5a532ec36c Author: Emmanuele Bassi Date: Fri Feb 23 15:48:44 2018 +0000 docs: Update the supported GL version to 4.6 README.md | 2 +- src/dispatch_common.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit ce8cbdbe064f5fd7f3e78b6349fa86604e6189d7 Author: Emmanuele Bassi Date: Fri Feb 23 15:44:50 2018 +0000 Allow building Epoxy without X11 Epoxy can be compiled with GLX and X11 native resources on EGL. We can disable the former, but the latter is always built in when enabling EGL support. Some platforms do not support X11 at all, so we need a way to disable X11 when configuring Epoxy. configure.ac | 27 +++++++++++++++++++++------ meson.build | 9 +++++++++ meson_options.txt | 4 ++++ src/dispatch_common.h | 7 +++++++ test/meson.build | 9 +++++++-- 5 files changed, 48 insertions(+), 8 deletions(-) commit baa75c4a92bff37cb742a8c3ad42ab93e4f2a3d6 Author: Emmanuele Bassi Date: Fri Feb 23 10:52:58 2018 +0000 Add gl and egl private dependencies If the system we're building Epoxy on has GL and EGL pkg-config modules, then we should add them to the Requires.private field of the pkg-config file. The Requires.private field does not contribute to the linker flags generated by pkg-config, unless we're doing a static build; it does, however, contribute to the compiler flags generated by pkg-config, which means that platforms that specify ad hoc compiler flags for their GL and EGL implementations via pkg-config will be able to propagate them through Epoxy. Closes: #139 configure.ac | 6 ++++++ epoxy.pc.in | 1 + src/meson.build | 12 ++++++++++++ 3 files changed, 19 insertions(+) commit f8a7661f2a63c9ffe86151439b4243836c5cb82a Author: Emmanuele Bassi Date: Fri Feb 23 14:55:57 2018 +0000 meson: Remove unnecessary configuration_data object We generate the pkg-config file using Meson's pkgconfig module as of commit b1119d8fcfe646f3ff108a3bf3685dfce6f049e4, but we're still setting up a configuration_data object. meson.build | 14 -------------- 1 file changed, 14 deletions(-) commit a57fb0b171b47f0168709ee8c0194577144d599e Author: Emmanuele Bassi Date: Fri Feb 23 14:22:06 2018 +0000 ci: Add Docker image files There's no real benefit in hosting the Dockerfile in an external repository. .travis.yml | 6 +++--- .travis/Dockerfile | 31 +++++++++++++++++++++++++++++++ .travis/epoxy-run-tests.sh | 20 ++++++++++++++++++++ .travis/run-docker.sh | 12 ++++++++++++ 4 files changed, 66 insertions(+), 3 deletions(-) commit fe62e02231a4e527a896784bdb293c644a94320f Author: Emmanuele Bassi Date: Wed Feb 7 17:56:55 2018 +0000 Update registry - OpenGL: dc62ac39930726183c0f0ad007e4ce6499597664 - EGL: 0fa0d37da846998aa838ed2b784a340c28dadff3 registry/egl.xml | 132 +- registry/gl.xml | 5598 +++++++++++++++++++++++++++++++++++++++--------------- registry/glx.xml | 78 +- registry/wgl.xml | 59 +- 4 files changed, 4224 insertions(+), 1643 deletions(-) commit b1119d8fcfe646f3ff108a3bf3685dfce6f049e4 Author: Emmanuele Bassi Date: Wed Feb 7 13:12:54 2018 +0000 meson: Generate the pkg-config file Instead of using a template file, and filling in the blanks, we can use the Meson pkgconfig module to generate the pkg-config file mostly from the library object itself — including dependencies and flags. The template file remains in tree for the Autotools build. meson.build | 6 ------ src/meson.build | 63 ++++++++++++++++++++++++++++++++------------------------- 2 files changed, 35 insertions(+), 34 deletions(-) commit 0d6aaa20eafb4752dde873533a68c8ca05dec3fe Author: Emmanuele Bassi Date: Wed Feb 7 13:11:51 2018 +0000 Bump up the Meson dependency Use the latest stable release; we're going to use its features to generate the pkg-config file for Epoxy, instead of using a template file. meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 69c80df5ef6cbc6b43ac62590d4dfd7c19e0d1b5 Author: Emmanuele Bassi Date: Wed Feb 7 13:10:39 2018 +0000 Include Xlib.h when using Xlib API The common EGL testing code uses XOpenDisplay(), which means we need to explicitly include the Xlib.h header file, instead of relying on something else stringing it along. test/egl_common.c | 1 + 1 file changed, 1 insertion(+) commit d1cce9914fcd920b5f27eeda68cdfad31586a6f7 Author: Emmanuele Bassi Date: Sat May 13 17:32:17 2017 +0100 travis: Drop conditional on Linux We currently run CI on Linux only, given that the macOS builders in Travis are always fairly overwhelmed; thus, there's no need to complicate the Travis script with a conditional that is always going to be true. .travis.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) commit 64fc3ac7ce15bd18ecd75bb02f87b59ecb701816 Merge: 6bdfdce c8d7ae6 Author: Emmanuele Bassi Date: Fri Feb 23 09:36:30 2018 +0000 Merge pull request #143 from ikeydoherty/comp-warnings Fix printf family usage commit 6bdfdcef3dff741cae6d57bbd7786ed0cca2af7a Merge: 88c0c48 3b3ff24 Author: Emmanuele Bassi Date: Fri Feb 23 09:25:22 2018 +0000 Merge pull request #155 from mgorny/dl test: Fix respecting $(DLOPEN_LIBS) commit 3b3ff242deea3dbcaff3efad80b35526a8a4c529 Author: Michał Górny Date: Thu Feb 22 19:57:03 2018 +0100 test: Fix respecting $(DLOPEN_LIBS) Fix two tests that are linking to -ldl directly to use DLOPEN_LIBS. This fixes failing test build on Gentoo/FreeBSD. test/Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) commit 88c0c4858ec8d10fbc3da1db51a01e7c0623dde9 Merge: 3f1699b 237a491 Author: Emmanuele Bassi Date: Wed Feb 7 17:40:31 2018 +0000 Merge pull request #154 from nwnk/fix-dlwrap-for-glvnd test: Fix dlwrap for glvnd commit 237a491b01c3ed37346f429b69cdf19982e35873 Author: Adam Jackson Date: Wed Feb 7 12:29:12 2018 -0500 test: Fix dlwrap for glvnd Add libOpenGL to the list of libraries we'll intercept. This is harmless if glvnd is not available as the dlopen(libOpenGL.so) will fail, but without this we can't intercept glGetString, which the egl_and_glx_different_pointers_glx test needs to be able to do. Signed-off-by: Adam Jackson test/dlwrap.c | 1 + 1 file changed, 1 insertion(+) commit 3f1699b6822b429400563692efc3dbd55d765b38 Merge: 1b54e26 4e5e17e Author: Emmanuele Bassi Date: Fri Jan 19 12:43:22 2018 +0000 Merge pull request #151 from rib/wip/rib/android Check __ANDROID__ define when guarding Android code commit 4e5e17eb0a9ff387996c41d162cdcbf4f2365676 Author: Robert Bragg Date: Thu Jan 18 21:21:15 2018 +0000 Check __ANDROID__ define when guarding Android code Both gcc and clang define __ANDROID__ but not ANDROID when targeting Android so at least with the Meson build, and an NDK r16 toolchain, testing on Android failed without this change. src/dispatch_common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) commit c8d7ae6bf8f2d0946f8955d1d0f8de3a18306e23 Author: Ikey Doherty Date: Thu Oct 19 16:02:57 2017 +0100 Only use printf family when passing arguments This avoids any unnecessary allocations when simply passing static strings to be printed onto stderr, and uses the simpler fputs mechanism. Signed-off-by: Ikey Doherty src/dispatch_common.c | 3 +-- src/dispatch_wgl.c | 6 +++--- test/dlwrap.c | 30 +++++++++++++++--------------- test/egl_and_glx_different_pointers.c | 4 ++-- test/egl_gl.c | 2 +- test/glx_common.c | 7 +++---- test/glx_public_api.c | 10 +++++----- test/glx_public_api_core.c | 5 +++-- test/glx_static.c | 4 ++-- test/khronos_typedefs_nonepoxy.c | 2 +- test/wgl_common.c | 6 +++--- test/wgl_core_and_exts.c | 6 +++--- test/wgl_per_context_funcptrs.c | 10 +++++----- test/wgl_usefontbitmaps.c | 4 ++-- 14 files changed, 49 insertions(+), 50 deletions(-) commit 9dde80065fa09128885d61b0a3baaec780961880 Author: Ikey Doherty Date: Thu Oct 19 15:50:46 2017 +0100 test: Fix trivial compiler warning in dlwrap This mutes compiler warnings for `dlwrap.c` by ensuring we actually check the return status of the `asprintf` call. At this point in the test suite our possible failure here is only memory, so we'll abort. Signed-off-by: Ikey Doherty test/dlwrap.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) commit 1b54e263eb112030b59c06f5daed0f75c8653cf3 Merge: 1dc283e 4bde48e Author: Emmanuele Bassi Date: Thu Oct 19 11:11:28 2017 +0100 Merge pull request #136 from Lyude/pull/epoxy_ext_in_str Expose epoxy_extension_in_string() in public headers commit 1dc283e9a38d4d8a82e2e49b9b516276eb435c25 Merge: d1c56a0 c02a02d Author: Emmanuele Bassi Date: Wed Oct 18 16:17:00 2017 +0100 Merge pull request #141 from dcbaker/submit/fix-static-build meson: Define visibility flags for static builds commit d1c56a0585b0c554c321f7b75094b381d65d3eb3 Merge: b49d190 60271ab Author: Emmanuele Bassi Date: Wed Oct 18 16:14:24 2017 +0100 Merge pull request #140 from danem/patch-1 Fix pointer mismatch bug on Windows 10. commit c02a02d51a75517d8c2eda22d4355b4f96cee1de Author: Dylan Baker Date: Fri Oct 13 16:50:44 2017 -0700 meson: Define visibility flags for static builds It's used unconditionally, but defined only for shared builds. For static builds define it but don't populate it. meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit 60271ab67b6dabf9d9a00e3080dcb99075c717b6 Author: danem Date: Fri Oct 13 16:20:11 2017 -0700 Fix pointer mismatch bug on Windows 10. We must explicitly cast to void** src/dispatch_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit b49d190c655adf6ae6a4bb71c3fa36a329449749 Author: Emmanuele Bassi Date: Mon Sep 11 16:32:06 2017 +0100 Bump up the libepoxy version We added new API, so we need a new version. configure.ac | 2 +- meson.build | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) commit e9e0098e5c75d39d49960696f017f83a54db8e65 Merge: 0734188 7ff061a Author: Emmanuele Bassi Date: Mon Sep 11 16:30:38 2017 +0100 Merge pull request #131 from nwnk/nonfatal-resolve-handler RFC: Add epoxy_set_resolver_failure_handler() commit 073418813631ffd9d8406f0c0ab0422e1b349d2c Merge: 254769a eb92953 Author: Emmanuele Bassi Date: Mon Sep 11 16:30:23 2017 +0100 Merge pull request #137 from nigels-com/master GLEW supports EGL as of version 2.0.0 onwards commit 254769ac2c739792280967d9620a84accaeae6db Merge: 516b4fb e5372a2 Author: Emmanuele Bassi Date: Mon Sep 11 16:29:46 2017 +0100 Merge pull request #138 from nwnk/fix-libopengl-soname dispatch: Fix the libOpenGL soname commit e5372a25baa9034b6223b32a0cab838c42779a39 Author: Adam Jackson Date: Thu Sep 7 17:02:22 2017 -0400 dispatch: Fix the libOpenGL soname Brown-paper-bag-for: Adam Jackson src/dispatch_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) commit eb92953ae4341a79bc5eceef32437a6a92e032c9 Author: Nigel Stewart Date: Sat Aug 26 11:40:26 2017 +1000 GLEW supports EGL as of version 2.0.0 onwards README.md | 1 - 1 file changed, 1 deletion(-) commit 4bde48e12cd0487ec2d2ad1383a912fd35541ac2 Author: Lyude Paul Date: Thu Aug 24 14:50:19 2017 -0400 Expose epoxy_extension_in_string() in public headers The EGL_EXT_device_query extension introduces the eglQueryDeviceStringEXT() function, which can be used with an EGLDeviceEXT enumeration to receive an OpenGL extension string containing all of the device extensions supported by it. From the EGL_EXT_device_query spec's amendments to section "3.2 Devices" after "3.1 Errors": const char *eglQueryDeviceStringEXT(EGLDeviceEXT device, EGLint name); returns a pointer to a static, zero-terminated string describing some aspect of the specified EGLDeviceEXT. must be EGL_EXTENSIONS. Since OpenGL extension parsing is rather simple, and we could always run into additional cases similar to this one in the future, we expose the shared epoxy_extension_in_string() function in libepoxy's public headers so that users can save themselves the hassle of having to write their own extension parser. Signed-off-by: Lyude Paul include/epoxy/common.h | 7 +++++++ src/dispatch_common.c | 18 ++++++++++++++++++ src/dispatch_common.h | 2 -- 3 files changed, 25 insertions(+), 2 deletions(-) commit 516b4fb8d0bced1fdbb9faa633c25d958de146bc Merge: e0426c9 ebe3a53 Author: Emmanuele Bassi Date: Fri Jul 21 12:11:40 2017 +0100 Merge pull request #134 from fooishbar/add-eglcast-def Add fallback definition for EGL_CAST commit 7ff061a944119ccb1c79b9755dd6b775c9984a1c Author: Adam Jackson Date: Wed Jul 5 16:54:15 2017 -0400 Add epoxy_set_resolver_failure_handler() Signed-off-by: Adam Jackson include/epoxy/gl.h | 14 ++++++++++++++ src/dispatch_common.c | 18 ++++++++++++++++++ src/dispatch_common.h | 2 ++ src/gen_dispatch.py | 4 ++++ 4 files changed, 38 insertions(+) commit e0426c94f6d0b45452d7a5f1b60a0d569be0db47 Merge: b157a4d 7c4817f Author: Emmanuele Bassi Date: Thu Jul 13 10:38:45 2017 +0100 Merge pull request #133 from nwnk/glx-detection-paranoia Try even harder to not load GLX commit 7c4817f2eed2faf0353c1ceb5f38b500f6aff7cf Author: Adam Jackson Date: Wed Jul 12 13:26:05 2017 -0400 dispatch: Be more paranoid about detecting GLX or not This code attempts not to dlopen anything if it can find the appropriate winsys symbols in the global namespace. That's nice. However we normally do dlopen(RTLD_LOCAL) when we open lib{GLX,EGL} so those symbols will _not_ in fact be in the global namespace. The code also prefers checking GLX to EGL, which means even if we initialize EGL through epoxy, and even if we're using glvnd, we'll still dlopen libGL the first time we hit epoxy_is_desktop_gl(). There's a couple of ways to skin this cat, let's take the easy one. If either-but-not-both of the glx or egl handles in the global API state are initialized, then we know we're already in one or the other. If neither or both are initialized, then the current heuristic should work fine. Note that epoxy_is_desktop_gl() is only bothering to check for GLX to work around PowerVR's broken GLES. One suspects a better way to do that would be to check GL_VENDOR or GL_RENDERER and avoid probing the window system at all. Signed-off-by: Adam Jackson src/dispatch_common.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) commit f81274b12470a0ce8678465112998708f63c3559 Author: Adam Jackson Date: Wed Jul 12 14:03:35 2017 -0400 dispatch: Use epoxy_conservative_glx_dlsym when probing GLX This path should also only load libGLX.so if possible. Signed-off-by: Adam Jackson src/dispatch_common.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) commit 91c9ecebd963c7af1f0ef3d1333ca0a723bdd6d4 Author: Adam Jackson Date: Wed Jul 12 13:59:44 2017 -0400 dispatch: Don't reference glvnd #defines on non-glvnd systems Broke the build on OSX, oops. Resolves: https://github.com/anholt/libepoxy/issues/132 Signed-off-by: Adam Jackson src/dispatch_common.c | 2 ++ 1 file changed, 2 insertions(+) commit ebe3a53db1c0bb34e1ca963b95d1f222115f93f8 Author: Daniel Stone Date: Fri Jul 7 10:48:58 2017 +0100 Add fallback definition for EGL_CAST The EGL API update from d11104f2b5 introduced a dependency on the EGL_CAST() macro, provided by an updated eglplatform.h. Given that we don't provide eglplatform.h, add a fallback definition for if we're building against Mesa 17.0.x or similar. https://bugs.gentoo.org/show_bug.cgi?id=623926 src/gen_dispatch.py | 9 +++++++++ 1 file changed, 9 insertions(+) commit b157a4d5ca7c9f4f5a2c58d27d14d4f8de17b5bd Merge: f145ea4 759de64 Author: Emmanuele Bassi Date: Sat Jun 17 00:14:06 2017 +0100 Merge pull request #129 from nwnk/glvnd-awareness dispatch: Learn about glvnd commit 759de647298aca23b5d77f7f11e530dc99c08ca9 Author: Adam Jackson Date: Fri Jun 16 14:37:06 2017 -0400 dispatch: Learn about glvnd glvnd has the rather nice property that GLX and (desktop) GL are available in separate libraries. As an example this would allow an EGL app to use desktop GL without any X11 libraries. Fix up our dlopens to prefer the glvnd libraries if available and fall back to the old ABI if not. Signed-off-by: Adam Jackson src/dispatch_common.c | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) commit f145ea4d23dc58ebd36bbea2b04cb29fe056c97f Merge: 8d03a6a 85c1228 Author: Emmanuele Bassi Date: Mon Jun 12 14:12:28 2017 +0100 Merge pull request #128 from tschoonj/patch-1 meson.build: fix macOS common_ldflags commit 85c122899cd4c7707f757f60050849e38e138248 Author: Tom Schoonjans Date: Mon Jun 12 12:54:13 2017 +0100 meson.build: fix macOS common_ldflags Equal signs are not accepted by the macOS linker: spaces must be used instead. src/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)