summaryrefslogtreecommitdiff
path: root/lib/librte_vhost
diff options
context:
space:
mode:
authorTimothy Redaelli <tredaelli@redhat.com>2018-10-16 22:47:16 +0200
committerFerruh Yigit <ferruh.yigit@intel.com>2018-10-26 22:14:05 +0200
commit1726e9994c77cddd40a2982a1a01ceaf18a83403 (patch)
tree8f73669a353cd0b2b9e9d9d9d987cd73714496e4 /lib/librte_vhost
parent3e77031be855e3bc8c70c2eaf219709cfd7426b0 (diff)
downloaddpdk-1726e9994c77cddd40a2982a1a01ceaf18a83403.zip
dpdk-1726e9994c77cddd40a2982a1a01ceaf18a83403.tar.gz
dpdk-1726e9994c77cddd40a2982a1a01ceaf18a83403.tar.xz
vhost/crypto: fix shared lib build without cryptodev
Currently it's not possible to build DPDK as shared library with cryptodev disabled since vhost is trying to link with rte_crypto, but rte_crypto and rte_hash are only needed when you build vhost_crypto and so only when cryptodev is enabled. This patch fix this by linking rte_vhost with rte_crypto and rte_hash only when cryptodev is enabled. Fixes: b4ca81298613 ("vhost/crypto: fix build without cryptodev") Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: stable@dpdk.org Signed-off-by: Timothy Redaelli <tredaelli@redhat.com> Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Diffstat (limited to 'lib/librte_vhost')
-rw-r--r--lib/librte_vhost/Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/librte_vhost/Makefile b/lib/librte_vhost/Makefile
index 531cf48..5dd3189 100644
--- a/lib/librte_vhost/Makefile
+++ b/lib/librte_vhost/Makefile
@@ -19,8 +19,7 @@ LDLIBS += -lpthread
ifeq ($(CONFIG_RTE_LIBRTE_VHOST_NUMA),y)
LDLIBS += -lnuma
endif
-LDLIBS += -lrte_eal -lrte_mempool -lrte_mbuf -lrte_ethdev -lrte_net \
- -lrte_cryptodev -lrte_hash
+LDLIBS += -lrte_eal -lrte_mempool -lrte_mbuf -lrte_ethdev -lrte_net
# all source are stored in SRCS-y
SRCS-$(CONFIG_RTE_LIBRTE_VHOST) := fd_man.c iotlb.c socket.c vhost.c \
@@ -31,6 +30,7 @@ SYMLINK-$(CONFIG_RTE_LIBRTE_VHOST)-include += rte_vhost.h rte_vdpa.h
# only compile vhost crypto when cryptodev is enabled
ifeq ($(CONFIG_RTE_LIBRTE_CRYPTODEV),y)
+LDLIBS += -lrte_cryptodev -lrte_hash
SRCS-$(CONFIG_RTE_LIBRTE_VHOST) += vhost_crypto.c
SYMLINK-$(CONFIG_RTE_LIBRTE_VHOST)-include += rte_vhost_crypto.h
endif