Skip to content

Commit

Permalink
CMake: refactor dependencies to use config-provided targets
Browse files Browse the repository at this point in the history
Signed-off-by: Andrei Lebedev <lebdron@gmail.com>
  • Loading branch information
lebdron committed Dec 23, 2019
1 parent bbe22b5 commit d2939bb
Show file tree
Hide file tree
Showing 52 changed files with 137 additions and 861 deletions.
15 changes: 3 additions & 12 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright Soramitsu Co., Ltd. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0

cmake_minimum_required(VERSION 3.11.4)
cmake_minimum_required(VERSION 3.14.0)

find_program(CCACHE_PROGRAM ccache)
if(CCACHE_PROGRAM)
Expand Down Expand Up @@ -113,7 +113,6 @@ option(PACKAGE_TGZ "Create TGZ package" OFF)
option(PACKAGE_RPM "Create RPM package" OFF)
option(PACKAGE_DEB "Create DEB package" OFF)
option(ENABLE_LIBS_PACKAGING "Enable libs packaging" ON)
option(USE_LIBIROHA "Use external model library" OFF)
option(USE_LIBURSA "Use Hyperledger Ursa cryptography" OFF)
option(SANITIZE_THREAD "Build with thread sanitizer" OFF)
option(SANITIZE_ADDRESS "Build with address sanitizer" OFF)
Expand Down Expand Up @@ -160,15 +159,11 @@ set(IROHA_SCHEMA_DIR "${CMAKE_CURRENT_SOURCE_DIR}/schema")
set(SM_SCHEMA_DIR "${PROJECT_SOURCE_DIR}/shared_model/schema")
set(SCHEMA_OUT_DIR ${CMAKE_BINARY_DIR}/schema)
include_directories(
${PROJECT_SOURCE_DIR}/shared_model
${PROJECT_SOURCE_DIR}/irohad
${PROJECT_SOURCE_DIR}/libs
)

# fallback to local shared_model
if (NOT USE_LIBIROHA)
include_directories(${PROJECT_SOURCE_DIR}/shared_model)
endif()

SET(IROHA_ROOT_PROJECT ON)

# Boost uses RTTI to perform some actions (such as type erasure).
Expand All @@ -188,11 +183,7 @@ add_subdirectory(schema)
add_subdirectory(libs)
add_subdirectory(irohad)
add_subdirectory(iroha-cli)

# fallback to local shared_model
if (NOT USE_LIBIROHA)
add_subdirectory(shared_model)
endif()
add_subdirectory(shared_model)

if(TESTING)
enable_testing()
Expand Down
38 changes: 0 additions & 38 deletions cmake/Modules/Findbenchmark.cmake

This file was deleted.

65 changes: 0 additions & 65 deletions cmake/Modules/Finded25519.cmake

This file was deleted.

47 changes: 0 additions & 47 deletions cmake/Modules/Findgflags.cmake

This file was deleted.

107 changes: 0 additions & 107 deletions cmake/Modules/Findgrpc.cmake

This file was deleted.

0 comments on commit d2939bb

Please sign in to comment.