Added checks for ib libs and headers
authorPeter Somogyi <psomogyi@gamax.hu>
Fri, 15 Dec 2006 15:58:49 +0000 (16:58 +0100)
committerPeter Somogyi <psomogyi@gamax.hu>
Fri, 15 Dec 2006 15:58:49 +0000 (16:58 +0100)
(This used to be ctdb commit 0fecfdea111f2f5d25eadce04c5f35dffca29b26)

ctdb/ib/config.m4

index f023f76f56441d3ac31ec44e87f9ad5b2e35b031..e84b7448a76b436f5010e0a677daf0f8844d1d2a 100644 (file)
@@ -10,6 +10,19 @@ if eval "test x$enable_infiniband = xyes"; then
        INFINIBAND_WRAPPER_OBJ="ib/ibwrapper.o"
        INFINIBAND_LIBS="-lrdmacm -libverbs"
        INFINIBAND_BINS="bin/ibwrapper_test"
+
+       AC_CHECK_HEADERS(infiniband/verbs.h, [], [
+               echo "ERROR: you need infiniband/verbs.h when ib enabled!"
+               exit -1])
+       AC_CHECK_HEADERS(rdma/rdma_cma.h, [], [
+               echo "ERROR: you need rdma/rdma_cma.h when ib enabled!"
+               exit -1])
+       AC_CHECK_LIB(ibverbs, ibv_create_qp, [], [
+               echo "ERROR: you need libibverbs when ib enabled!"
+               exit -1])
+       AC_CHECK_LIB(rdmacm, rdma_connect, [], [
+               echo "ERROR: you need librdmacm when ib enabled!"
+               exit -1])
 fi
 
 AC_SUBST(HAVE_INFINIBAND)