summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorThomas Monjalon <thomas.monjalon@6wind.com>2015-12-06 19:19:24 +0100
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-12-06 22:15:14 +0100
commita08634a224066c31376ac67cf26ffeac8ed86f0c (patch)
treec314989838a73e163bfbea820a87f2214414ca7c /mk
parent50de12a0809c86c3742a46ddb0b0802b762dbbf2 (diff)
downloaddpdk-a08634a224066c31376ac67cf26ffeac8ed86f0c.zip
dpdk-a08634a224066c31376ac67cf26ffeac8ed86f0c.tar.gz
dpdk-a08634a224066c31376ac67cf26ffeac8ed86f0c.tar.xz
mk: prepare dependencies in shared libraries not combined
Some DPDK libraries have a dependency. The Mellanox drivers embed this declaration in shared library case. So the application do not need to know the dependency when linking. But it cannot work with static libraries or the combined one. Note that Mellanox drivers are currently not supported in a shared combined library case. Most of the DPDK libraries declare their dependencies to be linked with the application in every cases, even when using drivers as shared library plugins. This patch improves the condition used for Mellanox drivers, so that it can be applied to other drivers without breaking the shared combined library case. Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
Diffstat (limited to 'mk')
-rw-r--r--mk/rte.app.mk10
1 files changed, 5 insertions, 5 deletions
diff --git a/mk/rte.app.mk b/mk/rte.app.mk
index d7e2964..3f56852 100644
--- a/mk/rte.app.mk
+++ b/mk/rte.app.mk
@@ -102,13 +102,13 @@ ifeq ($(CONFIG_RTE_LIBRTE_VHOST_USER),n)
_LDLIBS-$(CONFIG_RTE_LIBRTE_VHOST) += -lfuse
endif
-ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),n)
+# The static libraries do not know their dependencies.
+# 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_MLX4_PMD) += -libverbs
-endif # ! CONFIG_RTE_BUILD_SHARED_LIBS
-
-ifeq ($(CONFIG_RTE_BUILD_SHARED_LIB),n)
_LDLIBS-$(CONFIG_RTE_LIBRTE_MLX5_PMD) += -libverbs
-endif # ! CONFIG_RTE_BUILD_SHARED_LIBS
+endif # CONFIG_RTE_BUILD_COMBINE_LIBS or not CONFIG_RTE_BUILD_SHARED_LIBS
_LDLIBS-$(CONFIG_RTE_LIBRTE_BNX2X_PMD) += -lz