Files
spark/src/server/sparkd/CMakeLists.txt
T
2017-09-22 16:47:53 -04:00

42 lines
1.1 KiB
CMake

cmake_minimum_required(VERSION 3.5)
project(sparkd)
# proto sources
set (Protos)
include(${CMAKE_SOURCE_DIR}/tools/safe_dep_glob.cmake)
include(${CMAKE_SOURCE_DIR}/tools/Protobuf.cmake)
# DEPENDENCIES ------------------------------------------------------------
# protos
file(GLOB_RECURSE Protos RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.proto)
# normal cpps
file(GLOB_RECURSE Sparkd_Sources RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.cpp)
# this is used to communicate to other repositories that the build
# needs to happen again (because a file was added)
update_deps_file("${Protos};${Sparkd_Sources}")
#END DEPENDENCIES ------------------------------------------------------------
protobuf_generate_cpp( Proto_Srcs PROTO_HDRS ${Protos} )
add_executable(sparkd ${Sparkd_Sources} ${Proto_Srcs})
#include paths
target_include_directories( sparkd PUBLIC ${CMAKE_SOURCE_DIR}/src ${CMAKE_BINARY_DIR}/src)
# linking
target_link_libraries( sparkd
spark_lib
tbb
double-conversion
pugixml
-static-libgcc
-static-libstdc++
-pthread)
# copy test data
file(COPY jetfix/tests/sample_fix.dat DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/test_data)