summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2015-10-21 17:18:27 +0300
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-12-06 22:15:14 +0100
commit5f9115e58cc6f304ff4ade694cf5823d32887d1a (patch)
treed416551b1b1275367adbc4cf14276a9aacf79b74 /mk
parenta08634a224066c31376ac67cf26ffeac8ed86f0c (diff)
downloaddpdk-5f9115e58cc6f304ff4ade694cf5823d32887d1a.zip
dpdk-5f9115e58cc6f304ff4ade694cf5823d32887d1a.tar.gz
dpdk-5f9115e58cc6f304ff4ade694cf5823d32887d1a.tar.xz
mk: fix shared library dependencies of drivers
Similar to commit 113c8e13c4201eee207723571f83aaf285277d75, but for bnx2x, pcap, sze2data and xenvirt PMDs. Requiring applications to know about library internal details like dependencies to external helper libraries is a limitation of static linkage, shared libraries should always know their own dependencies for sane operation. This is especially highlighted with dlopen()'ed items, having applications link against about plugin internal dependencies goes on the side of absurd. Note that linking with a shared combined library still requires to know the internal dependencies. Signed-off-by: Panu Matilainen <pmatilai@redhat.com> Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Diffstat (limited to 'mk')
-rw-r--r--mk/rte.app.mk12
1 files changed, 4 insertions, 8 deletions
diff --git a/mk/rte.app.mk b/mk/rte.app.mk
index 3f56852..90ec33d 100644
--- a/mk/rte.app.mk
+++ b/mk/rte.app.mk
@@ -90,10 +90,6 @@ _LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lrte_vhost
endif # ! CONFIG_RTE_BUILD_COMBINE_LIBS
-_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_PCAP) += -lpcap
-
-_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_SZEDATA2) += -lsze2
-
ifeq ($(CONFIG_RTE_LIBRTE_VHOST_NUMA),y)
_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lnuma
endif
@@ -106,13 +102,13 @@ endif
# The combined library fails also to store this information.
# So linking with static or combined library requires explicit dependencies.
ifneq ($(CONFIG_RTE_BUILD_COMBINE_LIBS)$(CONFIG_RTE_BUILD_SHARED_LIB),ny)
+_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_PCAP) += -lpcap
+_LDLIBS-$(CONFIG_RTE_LIBRTE_BNX2X_PMD) += -lz
_LDLIBS-$(CONFIG_RTE_LIBRTE_MLX4_PMD) += -libverbs
_LDLIBS-$(CONFIG_RTE_LIBRTE_MLX5_PMD) += -libverbs
-endif # CONFIG_RTE_BUILD_COMBINE_LIBS or not CONFIG_RTE_BUILD_SHARED_LIBS
-
-_LDLIBS-$(CONFIG_RTE_LIBRTE_BNX2X_PMD) += -lz
-
+_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_SZEDATA2) += -lsze2
_LDLIBS-$(CONFIG_RTE_LIBRTE_PMD_XENVIRT) += -lxenstore
+endif # CONFIG_RTE_BUILD_COMBINE_LIBS or not CONFIG_RTE_BUILD_SHARED_LIBS
_LDLIBS-y += --start-group