[PATCH rdma-core 01/19] rdmacm: Fix missing libraries on centos6 build

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Jason Gunthorpe <jgg@xxxxxxxxxxxx>

Build fails with:

CMakeFiles/rdmacm.dir/rsocket.c.o: In function `rs_time_us':
/home/jgg/oss/rdma-core/librdmacm/rsocket.c:449: undefined reference to `clock_gettime'

Need to have -lrt on this old glibc.

Fixes: 38c49232b67a ("rsockets: Replace gettimeofday with clock_gettime")
Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxxxx>
---
 librdmacm/CMakeLists.txt | 1 +
 1 file changed, 1 insertion(+)

diff --git a/librdmacm/CMakeLists.txt b/librdmacm/CMakeLists.txt
index 4f74d4b0ac3b79..b306841ea2134e 100644
--- a/librdmacm/CMakeLists.txt
+++ b/librdmacm/CMakeLists.txt
@@ -21,6 +21,7 @@ target_link_libraries(rdmacm LINK_PUBLIC ibverbs)
 target_link_libraries(rdmacm LINK_PRIVATE
   ${NL_LIBRARIES}
   ${CMAKE_THREAD_LIBS_INIT}
+  ${RT_LIBRARIES}
   )
 
 # The preload library is a bit special, it needs to be open coded
-- 
2.22.0




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux