-
-
Save LaurentGomila/556168679ad8b5d6560e to your computer and use it in GitHub Desktop.
Quick and dirty CMake file for GLEW 1.6.0 (used on Windows - probably not portable)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set(CMAKE_C_OUTPUT_EXTENSION .o) | |
cmake_minimum_required(VERSION 2.8) | |
# set a default build type if none was provided | |
# this has to be done before the project() instruction! | |
if(NOT CMAKE_BUILD_TYPE) | |
set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build (Debug or Release)" FORCE) | |
endif() | |
# project name | |
project(glew) | |
# add an option for choosing the build type (shared or static) | |
set(BUILD_SHARED_LIBS TRUE CACHE BOOL "TRUE to build jpeg as shared libraries, FALSE to build it as static libraries") | |
if (NOT BUILD_SHARED_LIBS) | |
add_definitions(-DGLEW_STATIC) | |
endif() | |
# source files | |
set(SRC | |
src/glew.c | |
) | |
include_directories(include) | |
# define the target | |
add_library(glew ${SRC}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment