diff options
author | dimitri staessens <dimitri.staessens@ugent.be> | 2017-08-21 09:11:38 +0000 |
---|---|---|
committer | Sander Vrijders <sander.vrijders@ugent.be> | 2017-08-21 09:11:38 +0000 |
commit | 5b242e7207483860143d3c84438134430ac1448f (patch) | |
tree | a04a750b802436a4e244d8224b800a2f26071091 /CMakeLists.txt | |
parent | afe8b6f496dd4e0e3aaaa5dec0d6fb32253a49f7 (diff) | |
parent | 8f58e5a3ec0e4a15fc8ae0911cc864f5dbf86c6e (diff) | |
download | ouroboros-5b242e7207483860143d3c84438134430ac1448f.tar.gz ouroboros-5b242e7207483860143d3c84438134430ac1448f.zip |
Merged in dstaesse/ouroboros/be-build (pull request #557)
build: Revise the build system
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index ba56dc33..d4060d5f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -10,14 +10,10 @@ git_version_gen() include(GNUInstallDirs) set(PACKAGE_NAME "${CMAKE_PROJECT_NAME}") -set(PACKAGE_DESCRIPTION "The Ouroboros prototype" - CACHE STRING "Package description") -set(PACKAGE_URL "None" - CACHE STRING "Package URL") -set(PACKAGE_BUGREPORT "None" - CACHE STRING "Packaged bug-report email") -set(PACKAGE_VERSION "${PACKAGE_VERSION_MAJOR}.${PACKAGE_VERSION_MINOR}" - CACHE STRING "Package version") +set(PACKAGE_DESCRIPTION "The Ouroboros prototype") +set(PACKAGE_URL "None") +set(PACKAGE_BUGREPORT "None") +set(PACKAGE_VERSION "${PACKAGE_VERSION_MAJOR}.${PACKAGE_VERSION_MINOR}") if (APPLE) set(CMAKE_MACOSX_RPATH 1) @@ -72,15 +68,11 @@ test_and_set_c_compiler_flag_global(-Wunreachable-code) test_and_set_c_compiler_flag_global(-Wdeclaration-after-statement) test_and_set_c_compiler_flag_global(-fmax-errors=5) -configure_file( - "${CMAKE_CURRENT_SOURCE_DIR}/ouroboros.pc.in" - "${CMAKE_CURRENT_BINARY_DIR}/ouroboros.pc" - @ONLY) +configure_file("${CMAKE_CURRENT_SOURCE_DIR}/ouroboros.pc.in" + "${CMAKE_CURRENT_BINARY_DIR}/ouroboros.pc" @ONLY) -if (NOT APPLE) - install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ouroboros.pc" - DESTINATION "/usr/lib/pkgconfig") -endif () +install(FILES "${CMAKE_CURRENT_BINARY_DIR}/ouroboros.pc" + DESTINATION "usr/lib/pkgconfig") enable_testing() add_custom_target(check COMMAND ${CMAKE_CTEST_COMMAND}) @@ -88,15 +80,13 @@ add_custom_target(check COMMAND ${CMAKE_CTEST_COMMAND}) find_package(ProtobufC REQUIRED) include_directories(${PROTOBUF_C_INCLUDE_DIRS}) -add_subdirectory(src) add_subdirectory(include) +add_subdirectory(src) add_subdirectory(doc) # Uninstall target -configure_file( - "${CMAKE_SOURCE_DIR}/cmake/CmakeUninstall.cmake.in" - "${CMAKE_BINARY_DIR}/cmake/CmakeUninstall.cmake" - IMMEDIATE @ONLY) +configure_file("${CMAKE_SOURCE_DIR}/cmake/CmakeUninstall.cmake.in" + "${CMAKE_BINARY_DIR}/cmake/CmakeUninstall.cmake" IMMEDIATE @ONLY) add_custom_target(uninstall COMMAND ${CMAKE_COMMAND} -P ${CMAKE_BINARY_DIR}/cmake/CmakeUninstall.cmake) |