diff --git a/GNUmakefile b/GNUmakefile index 30d2b6f58..498d110e6 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -54,7 +54,8 @@ clean: install: $(BUILDDIR)/build.ninja $Q meson install -C $(BUILDDIR) --skip-subprojects -meson_opts = --buildtype=$(BUILDTYPE) --werror --warnlevel=2 -Db_sanitize=$(SANITIZE) +meson_opts = --buildtype=$(BUILDTYPE) --werror --warnlevel=2 +meson_opts += -Db_sanitize=$(SANITIZE) -Ddpdk_static=true meson_opts += $(MESON_EXTRA_OPTS) $(BUILDDIR)/build.ninja: diff --git a/debian/rules b/debian/rules index ca2d24700..3076767a8 100755 --- a/debian/rules +++ b/debian/rules @@ -9,6 +9,7 @@ meson_opts := --wrap-mode=default meson_opts += --auto-features=enabled meson_opts += -Ddpdk:platform=generic meson_opts += -Dfrr=enabled +meson_opts += -Ddpdk_static=true build = $(CURDIR)/debian/_build dest = $(CURDIR)/debian/tmp diff --git a/meson.build b/meson.build index 8562f597e..f5ec3efd6 100644 --- a/meson.build +++ b/meson.build @@ -63,7 +63,6 @@ dpdk_dep = dependency( default_options: [ 'buildtype=release', 'c_std=c11', - 'default_library=static', 'werror=false', 'enable_kmods=false', 'tests=false', @@ -73,6 +72,7 @@ dpdk_dep = dependency( 'enable_docs=false', 'developer_mode=disabled', ], + static: get_option('dpdk_static'), ) ev_core_dep = dependency('libevent_core') diff --git a/meson_options.txt b/meson_options.txt index fe8a25e63..2aea3e3d3 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -15,3 +15,8 @@ option( 'tests', type: 'feature', value: 'auto', description: 'Build unit-tests. If set to "auto", only build if cmocka is found.', ) + +option( + 'dpdk_static', type: 'boolean', value: false, + description: 'If set to true, link against static DPDK libraries.', +) diff --git a/rpm/grout.spec b/rpm/grout.spec index 53b85305a..02c8645b0 100644 --- a/rpm/grout.spec +++ b/rpm/grout.spec @@ -75,7 +75,7 @@ Requires: frr = %(sed -n "s/revision = frr-//p" subprojects/frr.wrap) FRR dplane plugin for grout %build -%meson -Ddpdk:platform=generic -Dfrr=enabled +%meson -Ddpdk:platform=generic -Dfrr=enabled -Ddpdk_static=true %meson_build %install diff --git a/subprojects/dpdk.wrap b/subprojects/dpdk.wrap index 2c46f7880..c384ea46b 100644 --- a/subprojects/dpdk.wrap +++ b/subprojects/dpdk.wrap @@ -1,6 +1,6 @@ [wrap-git] url = https://github.com/DPDK/dpdk-stable -revision = v24.11.1 +revision = v24.11.3 depth = 1 [provide]