-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathCMakeLists.txt
executable file
·27 lines (20 loc) · 1.15 KB
/
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
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake")
cmake_minimum_required(VERSION 3.13)
project(SafeLearn LANGUAGES CXX)
set(ABY_PATH "ABSOLUTE_PATH_TO_ABY")
find_package(GMP REQUIRED)
find_package(Threads REQUIRED)
find_package(Boost 1.66.0 REQUIRED COMPONENTS thread system)
set(MPCAggregationFiles "mpcaggregator/MPCAggregator.cpp")
set(NonMPCRelatedUtilsFile "utils/ClientServerConnector.cpp" "utils/Utils.cpp")
set(NonMainCPPFiles ${MPCAggregationFiles} ${NonMPCRelatedUtilsFile})
set(ABY_LIB_PATH "${ABY_PATH}/lib")
set(NON_ABY_LIBRARIES gmpxx gmp pthread boost_system crypto dl backtrace)
set(ABY_LIBRARIES "${ABY_LIB_PATH}/libaby.a" "${ABY_LIB_PATH}/libencrypto_utils.a" "${ABY_LIB_PATH}/libotextension.a" "${ABY_LIB_PATH}/librelic_s.a")
set(COMPILE_OPTIONS PUBLIC -Wall -Wextra -g3 -std=c++17)
add_executable(fedavg_aggregation FedAvgModelAggregationTest.cpp ${NonMainCPPFiles})
include_directories(fedavg_aggregation "${ABY_PATH}/include")
target_link_libraries(fedavg_aggregation ${ABY_LIBRARIES})
target_link_libraries(fedavg_aggregation ${NON_ABY_LIBRARIES})
target_compile_options(fedavg_aggregation ${COMPILE_OPTIONS})
set(CMAKE_CXX_STANDARD 17)