1234567891011121314151617181920212223242526272829 |
- # ---------------------------------
- # Finds module System
- # Adds library to target
- # Adds include path
- # ---------------------------------
- OPTION(DYNAMIC_LINK_OPENVIBE_MODULE_SYSTEM "Dynamically link OpenViBE module System" ON)
-
- IF(DYNAMIC_LINK_OPENVIBE_MODULE_SYSTEM)
- SET(OPENVIBE_MODULE_SYSTEM_LINKING "")
- ADD_DEFINITIONS(-DSystem_Shared)
- ELSE()
- SET(OPENVIBE_MODULE_SYSTEM_LINKING "-static")
- ADD_DEFINITIONS(-DSystem_Static)
- ENDIF()
-
- set(PATH_OPENVIBE_MODULES_SYSTEM "PATH_OPENVIBE_MODULES_SYSTEM-NOTFOUND")
- set(SRC_DIR ${OV_BASE_DIR}/modules/system/include)
-
- FIND_PATH(PATH_OPENVIBE_MODULES_SYSTEM system/defines.h PATHS ${SRC_DIR} NO_DEFAULT_PATH)
- IF(PATH_OPENVIBE_MODULES_SYSTEM)
- debug_message( " Found OpenViBE module System...")
- INCLUDE_DIRECTORIES(${PATH_OPENVIBE_MODULES_SYSTEM}/)
-
- TARGET_LINK_LIBRARIES(${PROJECT_NAME} openvibe-module-system${OPENVIBE_MODULE_SYSTEM_LINKING})
-
- ADD_DEFINITIONS(-DTARGET_HAS_System)
- ELSE(PATH_OPENVIBE_MODULES_SYSTEM)
- MESSAGE(WARNING " FAILED to find OpenViBE module System...")
- ENDIF(PATH_OPENVIBE_MODULES_SYSTEM)
|