summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--DevIL/src-ILUT/CMakeLists.txt20
1 files changed, 20 insertions, 0 deletions
diff --git a/DevIL/src-ILUT/CMakeLists.txt b/DevIL/src-ILUT/CMakeLists.txt
index a2926bec..63662bc6 100644
--- a/DevIL/src-ILUT/CMakeLists.txt
+++ b/DevIL/src-ILUT/CMakeLists.txt
@@ -20,6 +20,24 @@ endif( CMAKE_SIZEOF_VOID_P EQUAL 8 )
include_directories( include ../include )
+# Find glut
+find_package(GLUT REQUIRED)
+include_directories(${GLUT_INCLUDE_DIRS})
+link_directories(${GLUT_LIBRARY_DIRS})
+add_definitions(${GLUT_DEFINITIONS})
+if(NOT GLUT_FOUND)
+ message(ERROR " GLUT not found!")
+endif(NOT GLUT_FOUND)
+
+# Find opengl
+find_package(OpenGL REQUIRED)
+include_directories(${OpenGL_INCLUDE_DIRS})
+link_directories(${OpenGL_LIBRARY_DIRS})
+add_definitions(${OpenGL_DEFINITIONS})
+if(NOT OPENGL_FOUND)
+ message(ERROR " OPENGL not found!")
+endif(NOT OPENGL_FOUND)
+
# for windows add the .def and .rc files to the source list
if(WIN32)
add_definitions(-DALLEGRO_MSVC)
@@ -52,6 +70,8 @@ set_target_properties(ILUT PROPERTIES SOVERSION 1)
target_link_libraries(ILUT
IL
ILU
+ ${OPENGL_LIBRARIES}
+ ${GLUT_LIBRARY}
)
# generate pkg-config file