From 6b68ddeaa04d2eebae79a148738bfe619c58f088 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Wed, 18 Jan 2017 14:24:09 +0000 Subject: [PATCH] build: Skip GLESv1 tests if there's no GLESv1 It's pretty much pointless to build and run tests for a library that we know is not available. The Meson build already skips the GLES 1.0 test, so let's make the Autotools build do the same. --- configure.ac | 3 +++ test/Makefile.am | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 2d67726..e733267 100644 --- a/configure.ac +++ b/configure.ac @@ -119,6 +119,9 @@ fi AM_CONDITIONAL(HAS_ZNOW, test x$has_znow = xyes) +AC_CHECK_LIB([GLESv1_CM], [glFlush], [has_gles1=yes], [has_gles1=no]) +AM_CONDITIONAL(HAS_GLES1, test x$has_gles1 = xyes) + AC_CHECK_LIB([dl], [dlopen], [DLOPEN_LIBS="-ldl"]) AC_SUBST([DLOPEN_LIBS]) diff --git a/test/Makefile.am b/test/Makefile.am index adc7830..5781702 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -74,10 +74,13 @@ if BUILD_EGL EGL_TESTS = \ egl_has_extension_nocontext \ egl_gl \ - egl_gles1_without_glx \ egl_gles2_without_glx \ $() +if HAS_GLES1 +EGL_TESTS += egl_gles1_without_glx +endif + EGL_UTIL_LIB = libegl_common.la endif