2012-07-17 22:56:15 +00:00
|
|
|
FIND_PACKAGE(OpenGL)
|
|
|
|
FIND_PACKAGE(GLUT)
|
|
|
|
|
|
|
|
IF ( NOT GLUT_FOUND )
|
|
|
|
IF ( MSVC )
|
|
|
|
SET ( GLUT_FOUND 1 )
|
|
|
|
SET ( GLUT_INCLUDE_DIR ${Assimp_SOURCE_DIR}/samples/glut/ )
|
|
|
|
SET ( GLUT_LIBRARIES ${Assimp_SOURCE_DIR}/samples/glut/glut32.lib )
|
|
|
|
ELSE ( MSVC )
|
|
|
|
MESSAGE( WARNING "Please install glut." )
|
|
|
|
ENDIF ( MSVC )
|
|
|
|
ENDIF ( NOT GLUT_FOUND )
|
|
|
|
|
2010-10-03 12:08:21 +00:00
|
|
|
INCLUDE_DIRECTORIES(
|
|
|
|
${Assimp_SOURCE_DIR}/include
|
|
|
|
${Assimp_SOURCE_DIR}/code
|
2012-07-17 22:56:15 +00:00
|
|
|
${OPENGL_INCLUDE_DIR}
|
|
|
|
${GLUT_INCLUDE_DIR}
|
2010-10-03 12:08:21 +00:00
|
|
|
${Assimp_SOURCE_DIR}/samples/DevIL/include/
|
|
|
|
)
|
|
|
|
|
2015-01-23 18:10:36 +00:00
|
|
|
LINK_DIRECTORIES(
|
|
|
|
${Assimp_BINARY_DIR}
|
2010-10-03 12:08:21 +00:00
|
|
|
${Assimp_BINARY_DIR}/lib/
|
2014-06-01 15:33:50 +00:00
|
|
|
${Assimp_SOURCE_DIR}/samples/DevIL/lib/
|
2010-10-03 12:08:21 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
ADD_EXECUTABLE( assimp_simpletexturedogl WIN32
|
|
|
|
SimpleTexturedOpenGL/include/boost_includes.h
|
|
|
|
SimpleTexturedOpenGL/src/model_loading.cpp
|
|
|
|
)
|
|
|
|
|
2015-01-23 18:10:36 +00:00
|
|
|
SET_PROPERTY(TARGET assimp_simpletexturedogl PROPERTY DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX})
|
2010-10-03 12:08:21 +00:00
|
|
|
|
2012-07-17 22:56:15 +00:00
|
|
|
TARGET_LINK_LIBRARIES( assimp_simpletexturedogl assimp ${OPENGL_LIBRARIES} ${GLUT_LIBRARIES} DevIL.lib )
|
2010-10-03 12:08:21 +00:00
|
|
|
|
|
|
|
SET_TARGET_PROPERTIES( assimp_simpletexturedogl PROPERTIES
|
|
|
|
OUTPUT_NAME assimp_simpletexturedogl
|
|
|
|
)
|
|
|
|
|
|
|
|
INSTALL( TARGETS assimp_simpletexturedogl
|
2012-07-17 22:56:15 +00:00
|
|
|
DESTINATION "${ASSIMP_BIN_INSTALL_DIR}" COMPONENT assimp-dev
|
2015-01-23 18:10:36 +00:00
|
|
|
)
|