🔧 build(infra build): refactor build parameters
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
add_library(packet
|
||||
add_library(packet_parser
|
||||
packet_utils.c
|
||||
packet_parser.c
|
||||
packet_builder.c
|
||||
packet_filter.c
|
||||
packet_dump.c
|
||||
checksum.c)
|
||||
target_include_directories(packet PUBLIC ${CMAKE_CURRENT_LIST_DIR})
|
||||
target_include_directories(packet PUBLIC ${CMAKE_SOURCE_DIR}/deps/uthash)
|
||||
target_include_directories(packet PUBLIC ${CMAKE_SOURCE_DIR}/include)
|
||||
target_include_directories(packet PUBLIC ${CMAKE_SOURCE_DIR}/infra/core)
|
||||
target_link_libraries(packet tuple log dablooms)
|
||||
target_include_directories(packet_parser PUBLIC ${CMAKE_CURRENT_LIST_DIR})
|
||||
target_include_directories(packet_parser PUBLIC ${CMAKE_SOURCE_DIR}/deps/uthash)
|
||||
target_include_directories(packet_parser PUBLIC ${CMAKE_SOURCE_DIR}/include)
|
||||
target_include_directories(packet_parser PUBLIC ${CMAKE_SOURCE_DIR}/infra/core)
|
||||
target_link_libraries(packet_parser tuple log dablooms)
|
||||
|
||||
add_subdirectory(test)
|
||||
@@ -1,59 +1,59 @@
|
||||
add_executable(gtest_tunnel gtest_tunnel.cpp)
|
||||
target_link_libraries(gtest_tunnel packet gtest)
|
||||
target_link_libraries(gtest_tunnel packet_parser gtest)
|
||||
|
||||
add_executable(gtest_udp_utils gtest_udp_utils.cpp)
|
||||
target_link_libraries(gtest_udp_utils packet gtest)
|
||||
target_link_libraries(gtest_udp_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_tcp_utils gtest_tcp_utils.cpp)
|
||||
target_link_libraries(gtest_tcp_utils packet gtest)
|
||||
target_link_libraries(gtest_tcp_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_ip4_utils gtest_ip4_utils.cpp)
|
||||
target_link_libraries(gtest_ip4_utils packet gtest)
|
||||
target_link_libraries(gtest_ip4_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_ip6_utils gtest_ip6_utils.cpp)
|
||||
target_link_libraries(gtest_ip6_utils packet gtest)
|
||||
target_link_libraries(gtest_ip6_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_mpls_utils gtest_mpls_utils.cpp)
|
||||
target_link_libraries(gtest_mpls_utils packet gtest)
|
||||
target_link_libraries(gtest_mpls_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_eth_utils gtest_eth_utils.cpp)
|
||||
target_link_libraries(gtest_eth_utils packet gtest)
|
||||
target_link_libraries(gtest_eth_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_vlan_utils gtest_vlan_utils.cpp)
|
||||
target_link_libraries(gtest_vlan_utils packet gtest)
|
||||
target_link_libraries(gtest_vlan_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_vxlan_utils gtest_vxlan_utils.cpp)
|
||||
target_link_libraries(gtest_vxlan_utils packet gtest)
|
||||
target_link_libraries(gtest_vxlan_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_gre0_utils gtest_gre0_utils.cpp)
|
||||
target_link_libraries(gtest_gre0_utils packet gtest)
|
||||
target_link_libraries(gtest_gre0_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_gre1_utils gtest_gre1_utils.cpp)
|
||||
target_link_libraries(gtest_gre1_utils packet gtest)
|
||||
target_link_libraries(gtest_gre1_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_l2tp_utils gtest_l2tp_utils.cpp)
|
||||
target_link_libraries(gtest_l2tp_utils packet gtest)
|
||||
target_link_libraries(gtest_l2tp_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_gtp1_utils gtest_gtp1_utils.cpp)
|
||||
target_link_libraries(gtest_gtp1_utils packet gtest)
|
||||
target_link_libraries(gtest_gtp1_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_gtp2_utils gtest_gtp2_utils.cpp)
|
||||
target_link_libraries(gtest_gtp2_utils packet gtest)
|
||||
target_link_libraries(gtest_gtp2_utils packet_parser gtest)
|
||||
|
||||
add_executable(gtest_packet_frag gtest_packet_frag.cpp)
|
||||
target_link_libraries(gtest_packet_frag packet gtest)
|
||||
target_link_libraries(gtest_packet_frag packet_parser gtest)
|
||||
|
||||
add_executable(gtest_packet_parser gtest_packet_parser.cpp)
|
||||
target_link_libraries(gtest_packet_parser packet gtest)
|
||||
target_link_libraries(gtest_packet_parser packet_parser gtest)
|
||||
|
||||
add_executable(gtest_packet_builder gtest_packet_builder.cpp)
|
||||
target_link_libraries(gtest_packet_builder packet gtest)
|
||||
target_link_libraries(gtest_packet_builder packet_parser gtest)
|
||||
|
||||
add_executable(gtest_packet_filter gtest_packet_filter.cpp)
|
||||
target_link_libraries(gtest_packet_filter packet gtest)
|
||||
target_link_libraries(gtest_packet_filter packet_parser gtest)
|
||||
|
||||
add_executable(gtest_packet_ldbc gtest_packet_ldbc.cpp)
|
||||
target_link_libraries(gtest_packet_ldbc packet gtest)
|
||||
target_link_libraries(gtest_packet_ldbc packet_parser gtest)
|
||||
|
||||
include(GoogleTest)
|
||||
gtest_discover_tests(gtest_tunnel)
|
||||
|
||||
Reference in New Issue
Block a user