cmake_minimum_required(VERSION 2.6)
-project(assignment-1)
+project(opengl)
set(CMAKE_BINARY_DIR "bin")
set(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR})
-add_executable(assignment-1 assignment1.cpp)
+add_executable(main main.cpp model.cpp)
find_package(OpenGL REQUIRED)
include_directories(${OPENGL_INCLUDE_DIRS})
-target_link_libraries(assignment-1 ${OPENGL_LIBRARIES})
+target_link_libraries(main ${OPENGL_LIBRARIES})
find_package(GLUT REQUIRED)
if(NOT GLUT_FOUND)
message(ERROR "GLUT not found")
endif(NOT GLUT_FOUND)
include_directories(${GLUT_INCLUDE_DIR})
-target_link_libraries(assignment-1 ${GLUT_LIBRARIES})
+target_link_libraries(main ${GLUT_LIBRARIES})
find_package(GLEW REQUIRED)
if(NOT GLEW_FOUND)
message(ERROR "GLEW not found")
endif(NOT GLEW_FOUND)
include_directories(${GLEW_INCLUDE_DIR})
-target_link_libraries(assignment-1 ${GLEW_LIBRARIES})
+target_link_libraries(main ${GLEW_LIBRARIES})
+find_package(GLM REQUIRED)
+if(NOT GLM_FOUND)
+ message(ERROR "GLM not found")
+endif(NOT GLM_FOUND)
+include_directories(${GLM_INCLUDE_DIR})