##// END OF EJS Templates
Wait for the end of an acquisition to validate an operation (3)...
Wait for the end of an acquisition to validate an operation (3) If an operation is to validate, waits the end of the acquisition

File last commit:

r1069:6684c2bc54eb
r1215:7541b71e5b78
Show More
CMakeLists.txt
173 lines | 6.6 KiB | text/plain | TextLexer
Initialisation de l'application multithread avec le spimpl....
r21 ## core - CMakeLists.txt
STRING(TOLOWER ${CMAKE_PROJECT_NAME} LIBRARY_PREFFIX)
SET(SQPCORE_LIBRARY_NAME "${LIBRARY_PREFFIX}_core${DEBUG_SUFFIX}")
SET(SOURCES_DIR "${CMAKE_CURRENT_SOURCE_DIR}/src/")
SET(INCLUDES_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include/")
Alexandre Leroux
Unit tests for thresholds
r1016 SET(TESTS_RESOURCES_DIR "${CMAKE_CURRENT_SOURCE_DIR}/tests-resources")
Initialisation de l'application multithread avec le spimpl....
r21
# Include core directory
include_directories("${INCLUDES_DIR}")
# Set a variable to display a warning in the version files.
SET(SCIQLOP_CMAKE_GENERATION_WARNING "DON'T CHANGE THIS FILE. AUTOGENERATED BY CMAKE.")
# Generate the version file from the cmake version variables. The version
# variables are defined in the cmake/sciqlop_version.cmake file.
CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/resources/Version.h.in"
"${INCLUDES_DIR}/Version.h")
CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/resources/Version.cpp.in"
"${SOURCES_DIR}/Version.cpp")
Alexandre Leroux
Initializes plugin manager...
r66
# Find dependent modules
find_package(sciqlop-plugin)
INCLUDE_DIRECTORIES(${SCIQLOP-PLUGIN_INCLUDE_DIR})
Initialisation de l'application multithread avec le spimpl....
r21 #
# Find Qt modules
#
Add execute skelleton Network
r386 SCIQLOP_FIND_QT(Core Network)
Initialisation de l'application multithread avec le spimpl....
r21
#
# Compile the library library
#
Alexandre Leroux
Exports core module as a shared library...
r461
ADD_DEFINITIONS(-DCORE_LIB)
Initialisation de l'application multithread avec le spimpl....
r21 FILE (GLOB_RECURSE MODULE_SOURCES
${INCLUDES_DIR}/*.h
${SOURCES_DIR}/*.c
${SOURCES_DIR}/*.cpp
${SOURCES_DIR}/*.h)
ADD_LIBRARY(${SQPCORE_LIBRARY_NAME} ${MODULE_SOURCES})
set_property(TARGET ${SQPCORE_LIBRARY_NAME} PROPERTY CXX_STANDARD 14)
set_property(TARGET ${SQPCORE_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON)
TARGET_LINK_LIBRARIES(${SQPCORE_LIBRARY_NAME})
Add execute skelleton Network
r386 qt5_use_modules(${SQPCORE_LIBRARY_NAME} Core Network)
Configuration update to permit make install on linux
r257
Add Catalogue API dependency
r1058 # Find CATALOGUE_API
Add CatalogueAPI external project with SciQLop cmake configuration
r1062 include_directories("${CATALOGUEAPI_INCLUDE}")
TARGET_LINK_LIBRARIES(${SQPCORE_LIBRARY_NAME} ${CATALOGUEAPI_LIBRARIES})
Configuration update to permit make install on linux
r257 INSTALL(TARGETS ${SQPCORE_LIBRARY_NAME}
RUNTIME DESTINATION ${INSTALL_BINARY_DIR}
LIBRARY DESTINATION ${INSTALL_LIBRARY_DIR}
ARCHIVE DESTINATION ${INSTALL_LIBRARY_DIR}
)
Add CatalogueAPI external project with SciQLop cmake configuration
r1062 add_dependencies(${SQPCORE_LIBRARY_NAME} CatalogueAPI)
Initialisation de l'application multithread avec le spimpl....
r21 # From cmake documentation: http://www.cmake.org/cmake/help/v3.0/manual/cmake-buildsystem.7.html
# Entries in the COMPILE_DEFINITIONS are prefixed with -D or /D and added to the compile line in an unspecified order.
# The DEFINE_SYMBOL target property is also added as a compile definition as a special convenience case for SHARED and MODULE library targets
IF(BUILD_SHARED_LIBS)
SET_TARGET_PROPERTIES(${SQPCORE_LIBRARY_NAME} PROPERTIES COMPILE_DEFINITIONS "SCIQLOP_EXPORT")
ELSE()
TARGET_COMPILE_DEFINITIONS(${SQPCORE_LIBRARY_NAME} PUBLIC "SCIQLOP_STATIC_LIBRARIES")
ENDIF()
# Set the variable to parent scope so that the other projects can copy the
# dependent shared libraries
SCIQLOP_SET_TO_PARENT_SCOPE(SQPCORE_LIBRARY_NAME)
Add CatalogueAPI external project with SciQLop cmake configuration
r1062 ## Copy extern shared libraries to the lib folder
Finalize CatalogueAPI integration for windows
r1064 LIST (APPEND ${EXTERN_SHARED_LIBRARIES} ${CATALOGUEAPI_LIBRARIES})
Add config for windows compatibility of CatalogueAPI
r1060
Finalize CatalogueAPI integration for windows
r1064
SET (COPY_LIBS_DESTINATION LIBRARY)
if(APPLE)
SET (COPY_LIBS_DESTINATION RUNTIME)
endif()
add_custom_command(TARGET ${SQPCORE_LIBRARY_NAME} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy ${CATALOGUEAPI_LIBRARIES} ${EXECUTABLE_OUTPUT_PATH}
)
Add config for windows compatibility of CatalogueAPI
r1060
Initialisation de l'application multithread avec le spimpl....
r21 # Add the files to the list of files to be analyzed
LIST(APPEND CHECKSTYLE_INPUT_FILES ${MODULE_SOURCES})
SCIQLOP_SET_TO_PARENT_SCOPE(CHECKSTYLE_INPUT_FILES)
# Vera++ exclusion files
Ajout des règles vera++
r24 LIST(APPEND CHECKSTYLE_EXCLUSION_FILES ${CMAKE_CURRENT_SOURCE_DIR}/vera-exclusions/exclusions.txt)
Initialisation de l'application multithread avec le spimpl....
r21 SCIQLOP_SET_TO_PARENT_SCOPE(CHECKSTYLE_EXCLUSION_FILES)
#
# Compile the tests
#
IF(BUILD_TESTS)
INCLUDE_DIRECTORIES(${SOURCES_DIR})
FILE (GLOB_RECURSE TESTS_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/Test*.cpp)
FILE (GLOB_RECURSE TESTS_HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/Test*.h)
SET( TEST_LIBRARIES ${SQPCORE_LIBRARY_NAME})
Add CatalogueAPI external project with SciQLop cmake configuration
r1062 list(APPEND TEST_LIBRARIES ${CATALOGUEAPI_LIBRARIES})
Initialisation de l'application multithread avec le spimpl....
r21
Add the coverage target whith the test. make coverage will call the code...
r44 SET(TARGETS_COV)
Initialisation de l'application multithread avec le spimpl....
r21 FOREACH( testFile ${TESTS_SOURCES} )
Add the coverage target whith the test. make coverage will call the code...
r44 GET_FILENAME_COMPONENT( testDirectory ${testFile} DIRECTORY )
Initialisation de l'application multithread avec le spimpl....
r21 GET_FILENAME_COMPONENT( testName ${testFile} NAME_WE )
# Add to the list of sources files all the sources in the same
# directory that aren't another test
FILE (GLOB currentTestSources
${testDirectory}/*.c
${testDirectory}/*.cpp
Alexandre Leroux
commit temp
r41 ${testDirectory}/*.h)
LIST (REMOVE_ITEM currentTestSources ${TESTS_SOURCES})
# LIST (REMOVE_ITEM currentTestSources ${TESTS_HEADERS})
Initialisation de l'application multithread avec le spimpl....
r21
Alexandre Leroux
commit temp
r41 ADD_EXECUTABLE(${testName} ${testFile} ${currentTestSources})
set_property(TARGET ${testName} PROPERTY CXX_STANDARD 14)
set_property(TARGET ${testName} PROPERTY CXX_STANDARD_REQUIRED ON)
Add CatalogueAPI external project with SciQLop cmake configuration
r1062 TARGET_LINK_LIBRARIES( ${testName} ${TEST_LIBRARIES})
Alexandre Leroux
commit temp
r41 qt5_use_modules(${testName} Test)
Initialisation de l'application multithread avec le spimpl....
r21
Add the coverage target whith the test. make coverage will call the code...
r44 ADD_TEST( NAME ${testName} COMMAND ${testName} )
Initialisation de l'application multithread avec le spimpl....
r21
Alexandre Leroux
commit temp
r41 set(Coverage_NAME ${testName})
Remove coverage from windows build...
r76 if(UNIX)
SETUP_TARGET_FOR_COVERAGE(TARGET ${testName}_coverage OUTPUT ${testFile}-path NAME ${testFile} EXECUTABLE ${testName})
LIST( APPEND TARGETS_COV ${testName}_coverage)
endif(UNIX)
Add the coverage target whith the test. make coverage will call the code...
r44
ENDFOREACH( testFile )
add_custom_target(coverage)
FOREACH( target_cov ${TARGETS_COV} )
add_custom_command(TARGET coverage PRE_BUILD COMMAND make ${target_cov})
ENDFOREACH( target_cov )
Initialisation de l'application multithread avec le spimpl....
r21
LIST(APPEND testFilesToFormat ${TESTS_SOURCES})
LIST(APPEND testFilesToFormat ${TESTS_HEADERS})
LIST(APPEND FORMATTING_INPUT_FILES ${testFilesToFormat})
SCIQLOP_SET_TO_PARENT_SCOPE(FORMATTING_INPUT_FILES)
Alexandre Leroux
Unit tests for thresholds
r1016
ADD_DEFINITIONS(-DCORE_TESTS_RESOURCES_DIR="${TESTS_RESOURCES_DIR}")
Initialisation de l'application multithread avec le spimpl....
r21 ENDIF(BUILD_TESTS)
#
# Set the files that must be formatted by clang-format.
#
LIST (APPEND FORMATTING_INPUT_FILES ${MODULE_SOURCES})
SCIQLOP_SET_TO_PARENT_SCOPE(FORMATTING_INPUT_FILES)
#
# Set the directories that doxygen must browse to generate the
# documentation.
#
# Source directories:
LIST (APPEND DOXYGEN_INPUT_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/docs")
LIST (APPEND DOXYGEN_INPUT_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/src")
SCIQLOP_SET_TO_PARENT_SCOPE(DOXYGEN_INPUT_DIRS)
# Source directories to exclude from the documentation generation
#LIST (APPEND DOXYGEN_EXCLUDE_PATTERNS "${CMAKE_CURRENT_SOURCE_DIR}/path/to/subdir/*")
SCIQLOP_SET_TO_PARENT_SCOPE(DOXYGEN_EXCLUDE_PATTERNS)
#
# Set the directories with the sources to analyze and propagate the
# modification to the parent scope
#
# Source directories to analyze:
LIST (APPEND ANALYSIS_INPUT_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/src")
LIST (APPEND ANALYSIS_INPUT_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/tests")
SCIQLOP_SET_TO_PARENT_SCOPE(ANALYSIS_INPUT_DIRS)
# Source directories to exclude from the analysis
#LIST (APPEND ANALYSIS_EXCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/path/to/subdir")
SCIQLOP_SET_TO_PARENT_SCOPE(ANALYSIS_EXCLUDE_DIRS)