Thread (10 messages) flat view 10 messages, 7 authors, 2021-10-06

Re: [dpdk-dev] [PATCH v2] ifpga/base/meson: fix looking for librt

From: Xu, Rosen <hidden>
Date: 2021-06-30 10:03:04

CC Tianfei, who is maintainer.
quoted hunk
-----Original Message-----
From: Hussin, Mohamad Noor Alim <redacted>
Sent: Wednesday, June 30, 2021 17:26
To: Xu, Rosen <redacted>
Cc: dev@dpdk.org; Hussin, Mohamad Noor Alim
[off-list ref]; Huang, Wei
[off-list ref]; stable@dpdk.org
Subject: [PATCH v2] ifpga/base/meson: fix looking for librt

Finding with "librt" keyword would give the output with full path of librt such
as /usr/lib/gcc/x86_64-linux-gnu/7/../../../x86_64-linux-gnu/librt.so
instead of -lrt in libdpdk.pc pkg-config file.

Assume find_library() will prepend "lib", thus remove "lib" from "librt"
keyword. The output will shows as -lrt.

This will cause an issue when compile DPDK app with static library as the
path of librt has been hard-coded in the libdpdk.pc file.

Fixes: e41856b515ce ("raw/ifpga/base: enhance driver reliability in multi-
process")
Cc: wei.huang@intel.com
Cc: stable@dpdk.org

Signed-off-by: Mohamad Noor Alim Hussin
[off-list ref]
---
 drivers/raw/ifpga/base/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/raw/ifpga/base/meson.build
b/drivers/raw/ifpga/base/meson.build
index 8d27c6021..ce592a13a 100644
--- a/drivers/raw/ifpga/base/meson.build
+++ b/drivers/raw/ifpga/base/meson.build
@@ -27,7 +27,7 @@ sources = [

 rtdep = dependency('librt', required: false)  if not rtdep.found()
-    rtdep = cc.find_library('librt', required: false)
+    rtdep = cc.find_library('rt', required: false)
 endif
 if not rtdep.found()
     build = false
--
2.17.1
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help