123456789101112131415161718192021222324252627282930 |
- # ---------------------------------
- # Finds module CSV
- # Adds library to target
- # Adds include path
- # ---------------------------------
- OPTION(DYNAMIC_LINK_OPENVIBE_MODULE_CSV "Dynamically link OpenViBE module CSV" ON)
-
- IF(DYNAMIC_LINK_OPENVIBE_MODULE_CSV)
- SET(OPENVIBE_MODULE_CSV_LINKING "")
- ADD_DEFINITIONS(-DCSV_Shared)
- ELSE()
- SET(OPENVIBE_MODULE_CSV_LINKING "-static")
- ADD_DEFINITIONS(-DCSV_Static)
- ENDIF()
-
- set(PATH_OPENVIBE_MODULES_CSV "PATH_OPENVIBE_MODULES_CSV-NOTFOUND")
- set(SRC_DIR ${OV_BASE_DIR}/modules/csv/include)
-
- FIND_PATH(PATH_OPENVIBE_MODULES_CSV csv/defines.h PATHS ${SRC_DIR} NO_DEFAULT_PATH)
-
- IF(PATH_OPENVIBE_MODULES_CSV)
- debug_message( " Found OpenViBE module CSV...")
- INCLUDE_DIRECTORIES(${PATH_OPENVIBE_MODULES_CSV}/)
- debug_message( " Link openvibe-module-csv${OPENVIBE_MODULE_CSV_LINKING}")
- TARGET_LINK_LIBRARIES(${PROJECT_NAME} openvibe-module-csv${OPENVIBE_MODULE_CSV_LINKING})
-
- ADD_DEFINITIONS(-DTARGET_HAS_CSV)
- ELSE()
- MESSAGE(WARNING " FAILED to find OpenViBE module CSV...")
- ENDIF()
|