diff options
author | Bruce Richardson <bruce.richardson@intel.com> | 2019-05-28 12:07:48 +0100 |
---|---|---|
committer | Kevin Traynor <ktraynor@redhat.com> | 2019-10-02 15:52:10 +0100 |
commit | 9e7c637c694187044aae48c90aabc8827c2b3ed6 (patch) | |
tree | a075bf47903eee352097462f66426458cd1050f9 | |
parent | 6c576d41c5c56f5af59297154d84ddc80022b688 (diff) | |
download | dpdk-stable-9e7c637c694187044aae48c90aabc8827c2b3ed6.zip dpdk-stable-9e7c637c694187044aae48c90aabc8827c2b3ed6.tar.gz dpdk-stable-9e7c637c694187044aae48c90aabc8827c2b3ed6.tar.xz |
build: add libatomic dependency for 32-bit clang
[ upstream commit c649f0b4f58e35730d773104d3ba93bf21e21505]
When compiling with clang on 32-bit platforms, we are missing copies
of 64-bit atomic functions. We can solve this by linking against
libatomic for the drivers and libs which need those atomic ops.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Luca Boccassi <bluca@debian.org>
-rw-r--r-- | drivers/event/octeontx/meson.build | 5 | ||||
-rw-r--r-- | drivers/event/opdl/meson.build | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/drivers/event/octeontx/meson.build b/drivers/event/octeontx/meson.build index 0418553..0b8ba54 100644 --- a/drivers/event/octeontx/meson.build +++ b/drivers/event/octeontx/meson.build @@ -12,3 +12,8 @@ sources = files('ssovf_worker.c', allow_experimental_apis = true deps += ['common_octeontx', 'mempool_octeontx', 'bus_vdev', 'pmd_octeontx'] + +# for clang 32-bit compiles we need libatomic for 64-bit atomic ops +if cc.get_id() == 'clang' and dpdk_conf.get('RTE_ARCH_64') == false + ext_deps += cc.find_library('atomic') +endif diff --git a/drivers/event/opdl/meson.build b/drivers/event/opdl/meson.build index cc6029c..1fe034e 100644 --- a/drivers/event/opdl/meson.build +++ b/drivers/event/opdl/meson.build @@ -9,3 +9,8 @@ sources = files( 'opdl_test.c', ) deps += ['bus_vdev'] + +# for clang 32-bit compiles we need libatomic for 64-bit atomic ops +if cc.get_id() == 'clang' and dpdk_conf.get('RTE_ARCH_64') == false + ext_deps += cc.find_library('atomic') +endif |