forked from asterinas/trustflow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
39 lines (30 loc) · 925 Bytes
/
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
cmake_minimum_required(VERSION 3.5.1)
# Define build mode
set(BUILD_MODE
"wasm"
CACHE STRING "Select build mode for libverification(host|wasm)")
# Print build mode
message(STATUS "Build Mode: ${BUILD_MODE}")
if(BUILD_MODE STREQUAL "wasm")
set(CMAKE_TOOLCHAIN_FILE "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Emscripten.cmake")
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(WASM 1)
add_definitions(-DWASM)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -sMAIN_MODULE=2 -fPIC -fexceptions -O3")
endif()
project(trustedflow)
set(CMAKE_CXX_STANDARD 17)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
include(Abseil)
include(ApisProto)
include(Cppcodec)
include(DcapVerifier)
include(Fmtlib)
include(Openssl)
include(Protobuf)
include(SgxHeaders)
include(Yacl)
include(Spdlog)
include(CsvHeader)
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
add_subdirectory(trustedflow/attestation/verification)