#------------------------------------------------------------------- # This file is part of the CMake build system for Scol # # The contents of this file are placed in the public domain. Feel # free to make use of it in any way you like. #------------------------------------------------------------------- ############################################################ # CmakeList file for Oculus Mobile plugin ############################################################ PROJECT(SOCULUSMOBILE) # define header and source files for the library set (SOCULUSMOBILE_HEADER_FILES include/vrmaths.h include/sOculusMobile.h ) if (Scol_STATIC) set (SOCULUSMOBILE_HEADER_FILES ${SOCULUSMOBILE_HEADER_FILES} include/loadScolOculusMobile.h) endif() set (SOCULUSMOBILE_SOURCE_FILES src/vrmaths.cpp src/sOculusMobile.cpp src/scolplugin.cpp ) scol_include_plugin("SOCULUSMOBILE" "${PROJECT_SOURCE_DIR}/include" "loadScolOculusMobile.h") # Add directories includes if (OCULUS_MOBILE_FOUND) find_package(OPENGLES2) include_directories(include ${OCULUS_MOBILE_INCLUDE_DIRS} ${OPENGLES2_INCLUDE_DIRS}) #add_library(vrapi SHARED IMPORTED) #set_target_properties(vrapi PROPERTIES IMPORTED_LOCATION ${OCULUS_MOBILE_LIBRARY_RELEASE}) set(LIBRARIES ${OCULUS_MOBILE_LIBRARIES} ${OPENGLES2_gl_LIBRARY} ${EGL_egl_LIBRARY}) add_definitions(-DOCULUS_MOBILE_SDK_ENABLE) else() include_directories(include) endif() # setup Scol plugin target add_library(sOculusMobile ${Scol_LIB_TYPE} ${SOCULUSMOBILE_HEADER_FILES} ${SOCULUSMOBILE_SOURCE_FILES} ) add_dependencies(sOculusMobile kernel) # set the dll version. #set_target_properties(sOculusMobile PROPERTIES VERSION ${Scol_VERSION} SOVERSION ${Scol_VERSION_MAJOR}) target_link_libraries(sOculusMobile ${LIBRARIES}) if (ANDROID) set(Scol_ANDROID_DEPENDENCIES ${Scol_ANDROID_DEPENDENCIES} sOculusMobile CACHE INTERNAL "" FORCE) message(STATUS "[${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE}] Scol_ANDROID_DEPENDENCIES: ${Scol_ANDROID_DEPENDENCIES} -- added sOculusMobile to android project deps") endif() # install Scol scol_config_plugin(sOculusMobile) #install(FILES ${SOCULUSMOBILE_HEADER_FILES} DESTINATION include/SCOL/plugins/sOculusMobile)