Skip to content

Commit 252f857

Browse files
committed
build: Do not require find_package(dpkd) when using seastar
dpdk is included to within seastar, accordingly it should not be required to have dpdk package available when using seastar as dependency. This fixes build failures when attempting to use seastar from a custom install prefix.
1 parent 289f7f8 commit 252f857

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

Diff for: CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ set (Seastar_GEN_BINARY_DIR ${Seastar_BINARY_DIR}/gen)
396396
#
397397

398398
include (SeastarDependencies)
399-
seastar_find_dependencies ()
399+
seastar_find_dependencies (BUILD)
400400

401401
# Private build dependencies not visible to consumers
402402
find_package (ragel 6.10 REQUIRED)

Diff for: cmake/SeastarDependencies.cmake

+8-1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,8 @@ endmacro ()
7575
# with the corresponding configuration for each 3rd-party dependency.
7676
#
7777
macro (seastar_find_dependencies)
78+
cmake_parse_arguments (args "BUILD" "" "" ${ARGN})
79+
7880
#
7981
# List of Seastar dependencies that is meant to be used
8082
# both in Seastar configuration and by clients which
@@ -84,7 +86,6 @@ macro (seastar_find_dependencies)
8486
# Public dependencies.
8587
Boost
8688
c-ares
87-
dpdk # No version information published.
8889
fmt
8990
lz4
9091
# Private and private/public dependencies.
@@ -103,6 +104,12 @@ macro (seastar_find_dependencies)
103104
ucontext
104105
yaml-cpp)
105106

107+
# Only expose dpdk dependency during build. Since dpdk is included to within seastar library,
108+
# there is no need to force it to be discoverable via find_package().
109+
if (args_BUILD)
110+
list (APPEND _seastar_all_dependencies dpdk)
111+
endif()
112+
106113
# Arguments to `find_package` for each 3rd-party dependency.
107114
# Note that the version specification is a "minimal" version requirement.
108115

0 commit comments

Comments
 (0)