[Piglit] [PATCH 01/18] cmake: Add options BUILD_GLES{1, 2} tests [v2]

Chad Versace chad.versace at linux.intel.com
Tue May 22 18:01:41 PDT 2012

Default value for each is OFF.

Before this patch, Piglit automatically built the GLES1 tests if libEGL
and libGLESv1_CM were found. Ditto for GLES2 and libGLESv2. If these
libraries were installed on the system, it was impossible to disable the

This patch adds options to explicitly enable the tests.

v2: Fix typo GLES1 -> GLES2.

Reviewed-by: Jordan Justen <jordan.l.justen at intel.com>
Reviewed-by: Anuj Phogat <anuj.phogat at gmail.com>
Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
 CMakeLists.txt                  |    4 ++++
 cmake/target_api/CMakeLists.txt |   11 +++++++++--
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5f84117..d196126 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,6 +14,10 @@ find_package(GLUT REQUIRED)
 find_package(PNG REQUIRED)
+option(BUILD_GLES1_TESTS "Build tests for OpenGL ES1" OFF)
+option(BUILD_GLES2_TESTS "Build tests for OpenGL ES2" OFF)
 	option(BUILD_GLX_TESTS "Build tests that require GLX" ON)
diff --git a/cmake/target_api/CMakeLists.txt b/cmake/target_api/CMakeLists.txt
index f0c0e13..57b28c7 100644
--- a/cmake/target_api/CMakeLists.txt
+++ b/cmake/target_api/CMakeLists.txt
@@ -23,6 +23,13 @@
 #     Chad Versace <chad.versace at intel.com>
+	add_subdirectory(gles1)
+	add_subdirectory(gles2)

More information about the Piglit mailing list