From 85c4f9f2eee25493001d62ca911d6d4bb89ca6a6 Mon Sep 17 00:00:00 2001 From: Nigel Stewart Date: Sat, 10 Oct 2015 10:33:33 +1000 Subject: [PATCH] Add cmake support for Regal build mode. --- build/cmake/CMakeLists.txt | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/build/cmake/CMakeLists.txt b/build/cmake/CMakeLists.txt index 425fffb..c8d4dd2 100644 --- a/build/cmake/CMakeLists.txt +++ b/build/cmake/CMakeLists.txt @@ -13,6 +13,7 @@ endif() set(CMAKE_DEBUG_POSTFIX d) option (BUILD_UTILS "utilities" ON) +option (GLEW_REGAL "Regal mode" FALSE) option (GLEW_OSMESA "OSMesa mode" FALSE) set (GLEW_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../..) @@ -42,7 +43,19 @@ set (GLEW_LIBRARIES ${OPENGL_LIBRARIES}) add_definitions (-DGLEW_NO_GLU) -#### OSMesa #### +#### Regal mode #### + +if (GLEW_REGAL) + if (WIN32) + set (REGAL_LIB_NAME regal32) + else () + set (REGAL_LIB_NAME Regal) + endif () + add_definitions (-DGLEW_REGAL) + set (GLEW_LIBRARIES ${REGAL_LIB_NAME}) +endif () + +#### OSMesa mode #### if (GLEW_OSMESA) if (WIN32)