Merge https://github.com/nigels-com/glew.git into master HEAD at Fri Dec 23 17:46:58 GMT 2016

This commit is contained in:
omniavinco 2016-12-24 02:46:58 +09:00
commit f0d8d60cce
2 changed files with 8 additions and 3 deletions

View File

@ -54,6 +54,8 @@ Targets: `all, glew.lib (sub-targets: glew.lib.shared, glew.lib.static), glew
Variables: `SYSTEM=linux-clang, GLEW_DEST=/usr/local, STRIP=`
_Note: may need to make **auto** folder_
#### Using cmake
*CMake 2.8.12 or higher is required.*
@ -149,7 +151,7 @@ OpenGL implementation and GLEW support for that. Please include the output of
## Code Generation
A Unix or Mac environment is neded for building GLEW from scratch to
A Unix or Mac environment is needed for building GLEW from scratch to
include new extensions, or customize the code generation. The extension
data is regenerated from the top level source directory with:

View File

@ -44,8 +44,10 @@ else ()
endif ()
find_package (OpenGL REQUIRED)
find_package (X11)
#X11 is only required when builing utils/
if(BUILD_UTILS)
find_package (X11)
endif()
set (GLEW_LIBRARIES ${OPENGL_LIBRARIES})
add_definitions (-DGLEW_NO_GLU)
@ -101,6 +103,7 @@ if (MSVC)
target_compile_options (glew_s PRIVATE -GS-)
# remove stdlib dependency
target_link_libraries (glew LINK_PRIVATE -nodefaultlib -noentry)
string(REGEX REPLACE "/RTC(su|[1su])" "" CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
elseif (WIN32 AND ((CMAKE_C_COMPILER_ID MATCHES "GNU") OR (CMAKE_C_COMPILER_ID MATCHES "Clang")))
# remove stdlib dependency on windows with GCC and Clang (for similar reasons
# as to MSVC - to allow it to be used with any Windows compiler)