summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorNelio Laranjeiro <nelio.laranjeiro@6wind.com>2015-07-31 15:14:18 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-08-03 00:38:26 +0200
commit113c8e13c4201eee207723571f83aaf285277d75 (patch)
tree8d6de5d5e4d887f0108e560eb447293df9d9d067 /mk
parentbef06a8a0655a2d5b2d0e30bb46b3a64b1f13881 (diff)
downloaddpdk-113c8e13c4201eee207723571f83aaf285277d75.zip
dpdk-113c8e13c4201eee207723571f83aaf285277d75.tar.gz
dpdk-113c8e13c4201eee207723571f83aaf285277d75.tar.xz
mlx4: fix shared library dependency
librte_pmd_mlx4.so needs to be linked with libibverbs otherwise, the PMD is not able to open Mellanox devices and the following message is printed by testpmd at startup "librte_pmd_mlx4: cannot access device, is mlx4_ib loaded?". Applications dependency on libibverbs are moved to be only valid in static mode, in shared mode, applications do not depend on it anymore, librte_pmd_mlx4.so keeps this dependency and thus is linked with libibverbs. MLX4 cannot be supported in combined shared library because there is no clean way of adding -libverbs to the combined library. Signed-off-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com> Acked-by: Olivier Matz <olivier.matz@6wind.com>
Diffstat (limited to 'mk')
-rw-r--r--mk/rte.app.mk3
1 files changed, 3 insertions, 0 deletions
diff --git a/mk/rte.app.mk b/mk/rte.app.mk
index 97719cb..3871205 100644
--- a/mk/rte.app.mk
+++ b/mk/rte.app.mk
@@ -100,7 +100,10 @@ ifeq ($(CONFIG_RTE_LIBRTE_VHOST_USER),n)
_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lfuse
endif
+ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),n)
_LDLIBS-$(CONFIG_RTE_LIBRTE_MLX4_PMD) += -libverbs
+endif # ! CONFIG_RTE_BUILD_SHARED_LIBS
+
_LDLIBS-$(CONFIG_RTE_LIBRTE_BNX2X_PMD) += -lz
_LDLIBS-y += --start-group