FILE(GLOB SRC *.cpp *.h *.def) IF(WIN32) SET(NLDRV_OGL_LIB "nel_drv_opengl_win") ELSE(WIN32) SET(NLDRV_OGL_LIB "nel_drv_opengl") ENDIF(WIN32) ADD_LIBRARY(${NLDRV_OGL_LIB} SHARED ${SRC}) INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR} ${OPENGL_INCLUDE_DIR}) TARGET_LINK_LIBRARIES(${NLDRV_OGL_LIB} nel3d nelmisc ${OPENGL_LIBRARIES}) SET_TARGET_PROPERTIES(${NLDRV_OGL_LIB} PROPERTIES VERSION ${NL_VERSION} PROJECT_LABEL "Driver, Video: OpenGL") IF(WIN32) INCLUDE_DIRECTORIES(${DXSDK_INCLUDE_DIR}) TARGET_LINK_LIBRARIES(${NLDRV_OGL_LIB} ${DXSDK_DINPUT_LIBRARY} ${DXSDK_GUID_LIBRARY}) SET_TARGET_PROPERTIES(${NLDRV_OGL_LIB} PROPERTIES COMPILE_FLAGS "/Yustdopengl.h") SET_SOURCE_FILES_PROPERTIES(stdopengl.cpp PROPERTIES COMPILE_FLAGS "/Ycstdopengl.h") SET_TARGET_PROPERTIES(${NLDRV_OGL_LIB} PROPERTIES DEBUG_POSTFIX "_d" RELEASE_POSTFIX "_r" LINK_FLAGS "/NODEFAULTLIB:libcmt") ADD_DEFINITIONS(/DDRIVER_OPENGL_EXPORTS) ENDIF(WIN32) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS ${NLDRV_OGL_LIB} LIBRARY DESTINATION lib RUNTIME DESTINATION bin COMPONENT drivers3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS ${NLDRV_OGL_LIB} RUNTIME DESTINATION maxplugin COMPONENT drivers3d) ENDIF(WITH_MAXPLUGIN)