summaryrefslogtreecommitdiff
path: root/src/ipcpd/shim-udp/CMakeLists.txt
diff options
context:
space:
mode:
authordimitri staessens <dimitri.staessens@intec.ugent.be>2016-05-18 20:34:51 +0200
committerdimitri staessens <dimitri.staessens@intec.ugent.be>2016-05-18 20:53:05 +0200
commit6a4109706b20266833619d26cd89c5f9447fdd91 (patch)
tree0b2d8d6432e4f2125088279e1b2e2844fd4b7dda /src/ipcpd/shim-udp/CMakeLists.txt
parent4d348ef99bb3e3927be315ef1bdd1ae827c9a28c (diff)
downloadouroboros-6a4109706b20266833619d26cd89c5f9447fdd91.tar.gz
ouroboros-6a4109706b20266833619d26cd89c5f9447fdd91.zip
Implementation of a full flow allocator for the shim UDP.
It uses UDP port 0x0D1F on all hosts to send and receive flow allocation messages. It supports communication between server and client AP over a single shim IPCP. Implementation of full flow deallocation is pending. Both the client and the server still have to call flow_dealloc();
Diffstat (limited to 'src/ipcpd/shim-udp/CMakeLists.txt')
-rw-r--r--src/ipcpd/shim-udp/CMakeLists.txt14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/ipcpd/shim-udp/CMakeLists.txt b/src/ipcpd/shim-udp/CMakeLists.txt
index e10a8ca6..b4d9ffbd 100644
--- a/src/ipcpd/shim-udp/CMakeLists.txt
+++ b/src/ipcpd/shim-udp/CMakeLists.txt
@@ -12,6 +12,11 @@ include_directories(${CURRENT_BINARY_PARENT_DIR})
include_directories(${CMAKE_SOURCE_DIR}/include)
include_directories(${CMAKE_BINARY_DIR}/include)
+find_package(ProtobufC REQUIRED)
+include_directories(${PROTOBUF_INCLUDE_DIRS})
+protobuf_generate_c(SHIM_UDP_PROTO_SRCS SHIM_UDP_PROTO_HDRS
+ shim_udp_messages.proto)
+
# Find library needed for gethostbyname.
include(CheckFunctionExists)
CHECK_FUNCTION_EXISTS("gethostbyname" CMAKE_HAVE_GETHOSTBYNAME)
@@ -64,9 +69,12 @@ set(SHIM_UDP_SOURCES
# Add source files here
${CMAKE_CURRENT_SOURCE_DIR}/main.c)
+install(FILES ${SHIM_UDP_PROTO_HDRS} DESTINATION ${CMAKE_CURRENT_SOURCE_DIR})
+
add_executable (ipcpd-shim-udp ${SHIM_UDP_SOURCES} ${IPCP_SOURCES}
- "${CMAKE_CURRENT_BINARY_DIR}/shim_udp_config.h")
-target_link_libraries (ipcpd-shim-udp LINK_PUBLIC ouroboros)
+ ${SHIM_UDP_PROTO_SRCS} "${CMAKE_CURRENT_BINARY_DIR}/shim_udp_config.h")
+target_link_libraries (ipcpd-shim-udp LINK_PUBLIC ouroboros
+ ${PROTOBUF_C_LIBRARY})
# Enable DNS by default
if (NOT DISABLE_DNS MATCHES True)
@@ -81,4 +89,4 @@ endif (CMAKE_BUILD_TYPE MATCHES Debug)
install(TARGETS ipcpd-shim-udp RUNTIME DESTINATION bin)
# Enable once ipcp-shim-udp has tests
-add_subdirectory(tests)
+# add_subdirectory(tests)