mirror of
https://github.com/Perlmint/glew-cmake.git
synced 2024-11-30 02:17:07 +00:00
Regal-mode support for cmake build
This commit is contained in:
parent
bf2cd13450
commit
4718d42dde
@ -13,6 +13,7 @@ endif()
|
||||
set(CMAKE_DEBUG_POSTFIX d)
|
||||
|
||||
option (BUILD_UTILS "utilities" ON)
|
||||
option (GLEW_REGAL "Regal mode" FALSE)
|
||||
|
||||
set (GLEW_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../..)
|
||||
|
||||
@ -41,6 +42,20 @@ set (GLEW_LIBRARIES ${OPENGL_LIBRARIES})
|
||||
|
||||
add_definitions (-DGLEW_NO_GLU)
|
||||
|
||||
#### 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 ()
|
||||
|
||||
#### GLEW ####
|
||||
|
||||
include_directories (${GLEW_DIR}/include)
|
||||
|
||||
add_library (glew SHARED ${GLEW_DIR}/src/glew.c)
|
||||
|
Loading…
Reference in New Issue
Block a user