Skip to content

Instantly share code, notes, and snippets.

@mcihad
Created September 2, 2019 17:38
Show Gist options
  • Save mcihad/9172eb07c25f46bcccc4592baec74e4a to your computer and use it in GitHub Desktop.
Save mcihad/9172eb07c25f46bcccc4592baec74e4a to your computer and use it in GitHub Desktop.
SDL CMakeLists
cmake_minimum_required(VERSION 3.14)
project(cppproje)
find_package(OpenGL REQUIRED)
find_package(GLUT REQUIRED)
find_package(SDL2 REQUIRED)
include_directories(${SDL2_INCLUDE_DIRS} ${OPENGL_INCLUDE_DIRS} ${GLUT_INCLUDE_DIRS} )
set(CMAKE_CXX_STANDARD 17)
add_executable(cppproje main.cpp)
target_link_libraries(cppproje ${SDL2_LIBRARIES} ${OPENGL_LIBRARIES} ${GLUT_LIBRARY} )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment