aboutsummaryrefslogtreecommitdiffstats
path: root/libtransport/src/hicn
diff options
context:
space:
mode:
authormichele papalini <micpapal@cisco.com>2019-02-18 16:12:36 +0100
committermichele papalini <micpapal@cisco.com>2019-02-18 16:12:36 +0100
commitdd81185294bdda4203c747a9ce5c19a63c55dbd4 (patch)
treec6ba42069d36b526002592e92bd37d8c41d49cee /libtransport/src/hicn
parent63140cf46b43824d77206402cef13f01c2b9cdde (diff)
[HICN-69] add compiler definitions for programs using hicn
Change-Id: If20c1e487ca4d9c00ffeebe09f31b475b354e293 Signed-off-by: michele papalini <micpapal@cisco.com>
Diffstat (limited to 'libtransport/src/hicn')
-rw-r--r--libtransport/src/hicn/transport/CMakeLists.txt6
-rw-r--r--libtransport/src/hicn/transport/config.h.in1
-rw-r--r--libtransport/src/hicn/transport/core/pending_interest.h1
-rw-r--r--libtransport/src/hicn/transport/core/raw_socket_connector.h1
-rw-r--r--libtransport/src/hicn/transport/core/tcp_socket_connector.h1
-rw-r--r--libtransport/src/hicn/transport/core/udp_socket_connector.h1
6 files changed, 9 insertions, 2 deletions
diff --git a/libtransport/src/hicn/transport/CMakeLists.txt b/libtransport/src/hicn/transport/CMakeLists.txt
index c0481ad6f..e73a3407a 100644
--- a/libtransport/src/hicn/transport/CMakeLists.txt
+++ b/libtransport/src/hicn/transport/CMakeLists.txt
@@ -13,6 +13,8 @@
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
+set(ASIO_STANDALONE 1)
+
configure_file("config.h.in" "config.h" @ONLY)
install(
FILES ${CMAKE_CURRENT_BINARY_DIR}/config.h
@@ -28,7 +30,7 @@ add_subdirectory(portability)
add_subdirectory(protocols)
add_subdirectory(utils)
-set (COMPILER_DEFINITIONS "-DASIO_STANDALONE")
+set (COMPILER_DEFINITIONS "")
list(APPEND LIBTRANSPORT_INCLUDE_DIRS
${CMAKE_CURRENT_SOURCE_DIR}/../..
@@ -63,4 +65,4 @@ build_library(${LIBTRANSPORT}
if (${COMPILE_TESTS})
add_subdirectory(core/test)
add_subdirectory(transport/test)
-endif() \ No newline at end of file
+endif()
diff --git a/libtransport/src/hicn/transport/config.h.in b/libtransport/src/hicn/transport/config.h.in
index a140f4b78..02dcfa0f3 100644
--- a/libtransport/src/hicn/transport/config.h.in
+++ b/libtransport/src/hicn/transport/config.h.in
@@ -16,6 +16,7 @@
#pragma once
#cmakedefine TRANSPORT_HAVE_PTHREAD 1
+#cmakedefine ASIO_STANDALONE
#define RAAQM_CONFIG_PATH "@raaqm_config_path@"
diff --git a/libtransport/src/hicn/transport/core/pending_interest.h b/libtransport/src/hicn/transport/core/pending_interest.h
index 9a26c7b2b..3b2442d76 100644
--- a/libtransport/src/hicn/transport/core/pending_interest.h
+++ b/libtransport/src/hicn/transport/core/pending_interest.h
@@ -15,6 +15,7 @@
#pragma once
+#include <hicn/transport/config.h>
#include <hicn/transport/core/content_object.h>
#include <hicn/transport/core/interest.h>
#include <hicn/transport/core/name.h>
diff --git a/libtransport/src/hicn/transport/core/raw_socket_connector.h b/libtransport/src/hicn/transport/core/raw_socket_connector.h
index bb24d9d54..a307af8f2 100644
--- a/libtransport/src/hicn/transport/core/raw_socket_connector.h
+++ b/libtransport/src/hicn/transport/core/raw_socket_connector.h
@@ -18,6 +18,7 @@
#include <hicn/transport/core/connector.h>
#include <hicn/transport/core/name.h>
+#include <asio/steady_timer.hpp>
#include <linux/if_packet.h>
#include <net/ethernet.h>
#include <sys/socket.h>
diff --git a/libtransport/src/hicn/transport/core/tcp_socket_connector.h b/libtransport/src/hicn/transport/core/tcp_socket_connector.h
index 8dfda4eb8..ca9d2b663 100644
--- a/libtransport/src/hicn/transport/core/tcp_socket_connector.h
+++ b/libtransport/src/hicn/transport/core/tcp_socket_connector.h
@@ -15,6 +15,7 @@
#pragma once
+#include <hicn/transport/config.h>
#include <hicn/transport/core/connector.h>
#include <hicn/transport/core/name.h>
#include <hicn/transport/utils/branch_prediction.h>
diff --git a/libtransport/src/hicn/transport/core/udp_socket_connector.h b/libtransport/src/hicn/transport/core/udp_socket_connector.h
index 4704fa50b..4cde8f2eb 100644
--- a/libtransport/src/hicn/transport/core/udp_socket_connector.h
+++ b/libtransport/src/hicn/transport/core/udp_socket_connector.h
@@ -15,6 +15,7 @@
#pragma once
+#include <hicn/transport/config.h>
#include <hicn/transport/core/connector.h>
#include <hicn/transport/core/name.h>
#include <hicn/transport/utils/branch_prediction.h>