summaryrefslogtreecommitdiffstats
path: root/cmake/Modules
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2019-01-19 01:29:33 +0100
committerMauro Sardara <msardara@cisco.com>2019-01-21 12:03:48 +0100
commit9e5f41ed6ebe64a789916794626485460078c420 (patch)
treed2ac3090026ec8929558e88eca533f8787a6ff0b /cmake/Modules
parentd13d37534d9449dd54277af664310d5f957dc44a (diff)
- Code style fix
- Improved vpp binary api interface - Correction in object pool destructor - Fix error in Memif Connector Change-Id: Id1dd9219fc1ac0b3717ae019ebff17373bebc635 Signed-off-by: Mauro Sardara <msardara@cisco.com>
Diffstat (limited to 'cmake/Modules')
-rwxr-xr-xcmake/Modules/BuildMacros.cmake9
1 files changed, 8 insertions, 1 deletions
diff --git a/cmake/Modules/BuildMacros.cmake b/cmake/Modules/BuildMacros.cmake
index 14a82fab7..3630d2e26 100755
--- a/cmake/Modules/BuildMacros.cmake
+++ b/cmake/Modules/BuildMacros.cmake
@@ -19,7 +19,7 @@ macro(build_executable exec)
cmake_parse_arguments(ARG
"NO_INSTALL"
"COMPONENT"
- "SOURCES;LINK_LIBRARIES;DEPENDS;DEFINITIONS"
+ "SOURCES;LINK_LIBRARIES;DEPENDS;INCLUDE_DIRS;DEFINITIONS"
${ARGN}
)
@@ -36,6 +36,13 @@ macro(build_executable exec)
target_compile_definitions(${exec} PRIVATE ${ARG_DEFINITIONS})
endif()
+ if(ARG_INCLUDE_DIRS)
+ target_include_directories(${exec} BEFORE PUBLIC
+ ${ARG_INCLUDE_DIRS}
+ ${PROJECT_BINARY_DIR}
+ )
+ endif()
+
if(NOT ARG_NO_INSTALL)
install(TARGETS ${exec} DESTINATION bin COMPONENT ${ARG_COMPONENT})
endif()