blockpp

A blockchain implementation in c++.


blockpp

/

CMakeLists.txt

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
cmake_minimum_required (VERSION 3.8 FATAL_ERROR)

set (TARGET "$ENV{APP}")
project (${TARGET})

set (CMAKE_CXX_STANDARD 14)
set (CMAKE_CXX_STANDARD_REQUIRED ON)

# set (DEBUG_FLAGS "-std=c++14 -g -O0 -Wall -Wextra -Wpedantic")
set (DEBUG_FLAGS "-Wpedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wctor-dtor-privacy -Wdisabled-optimization -Wformat=2 -Winit-self -Wlogical-op -Wmissing-declarations -Wmissing-include-dirs -Wnoexcept -Wold-style-cast -Woverloaded-virtual -Wredundant-decls -Wshadow -Wsign-conversion -Wsign-promo -Wstrict-null-sentinel -Wstrict-overflow=5 -Wswitch-default -Wundef -Wno-unused -std=c++14 -g -O0")
set (RELEASE_FLAGS "-std=c++14 -s -O3")
set (GCOV_FLAGS "-fprofile-arcs -ftest-coverage")

# set (CMAKE_CXX_FLAGS "")
# set (CMAKE_C_FLAGS "")
set (CMAKE_CXX_FLAGS_DEBUG ${DEBUG_FLAGS})
set (CMAKE_C_FLAGS_DEBUG ${DEBUG_FLAGS})
set (CMAKE_CXX_FLAGS_RELEASE ${RELEASE_FLAGS})
set (CMAKE_C_FLAGS_RELEASE ${RELEASE_FLAGS})
set (CMAKE_EXE_LINKER_FLAGS_DEBUG ${GCOV_FLAGS})

message ("CMAKE_BUILD_TYPE is ${CMAKE_BUILD_TYPE}")

include_directories(
  ./parg/include
  ./src
  ./
)

set (SOURCES
  src/main.cc
  src/blockchain.cc
  src/crypto.cc
)

set (HEADERS
)

add_executable (
  ${TARGET}
  ${SOURCES}
  ${HEADERS}
)

target_link_libraries (
  ${TARGET}
  crypto
)
Back to Top