summaryrefslogtreecommitdiff
path: root/shaping/CMakeLists.txt
blob: 6c7923c167e9be95fc1b9e25a01f49435959a62c (plain)
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
add_library(shaper src/shaper_maat.cpp src/shaper_marsio.cpp src/shaper_session.cpp src/shaper_stat.cpp src/shaper_swarmkv.cpp src/shaper.cpp src/shaper_global_stat.cpp src/shaper_aqm.cpp ${PROJECT_SOURCE_DIR}/deps/timeout/timeout.c)
target_link_libraries(shaper PUBLIC common)
target_link_libraries(shaper PUBLIC avl_tree)
target_link_libraries(shaper PUBLIC cjson)
target_link_libraries(shaper PUBLIC MESA_handle_logger)
target_link_libraries(shaper PUBLIC MESA_prof_load)
target_link_libraries(shaper PUBLIC fieldstat3)
target_link_libraries(shaper PUBLIC pthread)
target_include_directories(shaper PUBLIC ${CMAKE_CURRENT_LIST_DIR}/include)
target_include_directories(shaper PUBLIC ${PROJECT_SOURCE_DIR}/deps/timeout)
link_directories(shaper PUBLIC ${PROJECT_SOURCE_DIR}/deps/bytehound)
add_executable(shaping_engine src/main.cpp)
target_link_libraries(shaping_engine PUBLIC shaper)
target_link_libraries(shaping_engine PUBLIC maatframe)
target_link_libraries(shaping_engine PUBLIC mrzcpd)
target_link_libraries(shaping_engine PUBLIC dl bytehound) #libjemalloc-static dl)
target_link_libraries(shaping_engine PUBLIC swarmkv)

install(TARGETS shaping_engine RUNTIME DESTINATION bin COMPONENT Program)

# 在安装时创建一个子目录log
install(DIRECTORY DESTINATION ${CMAKE_INSTALL_PREFIX}/log)


add_subdirectory(test)