diff --git a/CMakeLists.txt b/CMakeLists.txt index 67bc69c..f0ab1b1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,90 +1,90 @@ project( liboncilla C CXX ) cmake_minimum_required(VERSION 2.8 ) find_package(Boost) if("${CMAKE_CXX_COMPILER}" MATCHES ".*clang.*") if( "${Boost_VERSION}" VERSION_LESS "104801") message(FATAL_ERROR "There is some incompatibility with boost <= 1.48.0 (here ${Boost_MAJOR_VERSION}.${Boost_MINOR_VERSION}.${Boost_SUBMINOR_VERSION}) and C++11 features. Since your compiler (Clang) fully support C++11, you should use a more recent version of Boost to compile this library. C++11 is needed by NemoMath dependency.") endif( "${Boost_VERSION}" VERSION_LESS "104801") endif("${CMAKE_CXX_COMPILER}" MATCHES ".*clang.*") find_package(BiorobCMakeUtils 0.3.4 REQUIRED) include_all_biorob_cmake_utils() # --- user options --- option(BUILD_TESTS "Decide whether unit-tests are built" ON) option(BUILD_EXAMPLES "Decide whether the examples are built" ON) option(BUILD_DOCS "Decide whether the docygen documentation is built" OFF) find_package(RCI REQUIRED) add_definitions(${RCI_DEFINITIONS}) find_package(PkgConfig REQUIRED) pkg_check_modules(BIOROB_CPP biorob-cpp-0.2>=0.2.8 REQUIRED) # --- global definitions --- -make_std_versionning(MAJOR 0 MINOR 3 PATCH 0~rc3) +make_std_versionning(MAJOR 0 MINOR 3 PATCH 0~rc4) # Includes include_directories(${PROJECT_BINARY_DIR}/src ${PROJECT_SOURCE_DIR}/src ${BIOROB_CPP_INCLUDE_DIRS} ${RCI_INCLUDE_DIRS}) set(INCLUDE_DIR include/liboncilla-${VERSION_API}) # --- cmake config file --- configure_file(liboncillaConfig.cmake.in LibOncillaConfig.cmake @ONLY) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/LibOncillaConfig.cmake DESTINATION share/liboncilla) add_subdirectory(src) find_package(GMock) if(BUILD_TESTS AND GMOCK_FOUND) enable_testing() message(STATUS "Building tests - deactivate by adapting BUILD_TESTS") add_subdirectory(test) elseif(BUILD_TESTS AND NOT GMOCK_FOUND) message(WARNING "Could not build unit tests even though desired because Google Mock could not be installed.") endif(BUILD_TESTS AND GMOCK_FOUND) if(BUILD_EXAMPLES) add_subdirectory(examples) endif(BUILD_EXAMPLES) # --- pkgconfig file --- set(PKG_CONFIG_FILE liboncilla-${VERSION_MAJOR}.pc ) configure_file(liboncilla.pc.in ${PKG_CONFIG_FILE} @ONLY) install(FILES ${CMAKE_BINARY_DIR}/${PKG_CONFIG_FILE} DESTINATION lib/pkgconfig) # --- documentation generation --- if(BUILD_DOCS) add_subdirectory(doc) endif(BUILD_DOCS) # --- coverage --- #if(BUILD_TESTS) # enable_coverage_report(TARGETS liboncilla TESTS ${DTO_TEST_NAME} ${INTEGRATED_TEST_NAME} FILTER "*3rdparty*" "*test/*") #endif(BUILD_TESTS) # --- sloccount --- #enable_sloccount(FOLDERS src test examples) # --- cppcheck --- #generate_cppcheck(SOURCES src test examples # "${CMAKE_CURRENT_BINARY_DIR}/src" "${CMAKE_CURRENT_BINARY_DIR}/test" "${CMAKE_CURRENT_BINARY_DIR}/examples" # ENABLE_IDS style)