Skip to content

Commit

Permalink
build script support to build tools like xdpdump
Browse files Browse the repository at this point in the history
Summary:
This allows building of xdpdump via the central build-script. (follow up from
#110)

Reviewed By: avasylev

Differential Revision: D25877843

fbshipit-source-id: 7977e88a2251b4d0b98a23e90f521992c8c9bc08
  • Loading branch information
Udip Pant authored and facebook-github-bot committed Jan 12, 2021
1 parent 2ab7a0f commit fee201c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ if(DEFINED ENV{CMAKE_BUILD_EXAMPLE_GRPC})
add_subdirectory(example_grpc)
endif()

if(DEFINED ENV{CMAKE_BUILD_TOOLS})
add_subdirectory(tools)
endif()

install(
EXPORT katran-exports
FILE katran-targets.cmake
Expand Down
5 changes: 5 additions & 0 deletions build_katran.sh
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ if [ -z "$BUILD_EXAMPLE_GRPC" ]; then
export CMAKE_BUILD_EXAMPLE_GRPC="$BUILD_EXAMPLE_GRPC"
fi

if [ -n "$BUILD_TOOLS" ]; then
BUILD_TOOLS=1
export CMAKE_BUILD_TOOLS="$BUILD_TOOLS"
fi

get_dev_tools() {
if [ -f /etc/redhat-release ]; then
sudo yum install -y epel-release
Expand Down
1 change: 0 additions & 1 deletion tools/xdpdump/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ target_link_libraries(xdpdump
"${PTHREAD}"
"${LIBDC}"
"${DL}"
"libevent:libevent"
"${EVENT_CORE}"
"${LIBIBERTY}"
iphelpers
Expand Down

0 comments on commit fee201c

Please sign in to comment.