[openfabrics-ewg] [PATCH OFED-1.1-rc7] libehca configure.in and config.h.in: fix missing check of libsysfs.h
Hoang-Nam Nguyen
hnguyen at de.ibm.com
Wed Oct 18 09:55:36 PDT 2006
Hello,
below is a patch of configure.in and config.h.in in libehca. It checks
the presence of libsysfs.h properly. Unfortunately I recognized this bug
lately after I've fixed the "openib.spec" issues and tested ofed on
a clean system.
Thanks!
Nam
Signed-off-by: Hoang-Nam Nguyen <hnguyen at de.ibm.com>
---
config.h.in | 3 +++
configure.in | 5 +++++
2 files changed, 8 insertions(+)
diff -Nurp openib-1.1/src/userspace/libehca/config.h.in openib-1.1_patch/src/userspace/libehca/config.h.in
--- openib-1.1/src/userspace/libehca/config.h.in 2006-10-05 15:07:36.000000000 +0200
+++ openib-1.1_patch/src/userspace/libehca/config.h.in 2006-10-18 17:31:37.000000000 +0200
@@ -27,6 +27,9 @@
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
+/* Define to 1 if you have the <sysfs/libsysfs.h> header file. */
+#undef HAVE_SYSFS_LIBSYSFS_H
+
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
diff -Nurp openib-1.1/src/userspace/libehca/configure.in openib-1.1_patch/src/userspace/libehca/configure.in
--- openib-1.1/src/userspace/libehca/configure.in 2006-10-05 15:07:03.000000000 +0200
+++ openib-1.1_patch/src/userspace/libehca/configure.in 2006-10-18 17:31:37.000000000 +0200
@@ -25,9 +25,14 @@ AC_CHECK_LIB(ibverbs,
[],
AC_MSG_ERROR([libibverbs not installed]))
+dnl Checks for header files.
+AC_CHECK_HEADER(infiniband/driver.h, [],
+ AC_MSG_ERROR([<infiniband/driver.h> not found. libehca requires libibverbs.]))
+
dnl Checks for library functions
AC_CHECK_FUNCS(ibv_read_sysfs_file)
fi
+AC_CHECK_HEADERS(sysfs/libsysfs.h)
dnl Checks for programs.
AC_PROG_CC
-------------- next part --------------
diff -Nurp openib-1.1/src/userspace/libehca/config.h.in openib-1.1_patch/src/userspace/libehca/config.h.in
--- openib-1.1/src/userspace/libehca/config.h.in 2006-10-05 15:07:36.000000000 +0200
+++ openib-1.1_patch/src/userspace/libehca/config.h.in 2006-10-18 17:31:37.000000000 +0200
@@ -27,6 +27,9 @@
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
+/* Define to 1 if you have the <sysfs/libsysfs.h> header file. */
+#undef HAVE_SYSFS_LIBSYSFS_H
+
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
diff -Nurp openib-1.1/src/userspace/libehca/configure.in openib-1.1_patch/src/userspace/libehca/configure.in
--- openib-1.1/src/userspace/libehca/configure.in 2006-10-05 15:07:03.000000000 +0200
+++ openib-1.1_patch/src/userspace/libehca/configure.in 2006-10-18 17:31:37.000000000 +0200
@@ -25,9 +25,14 @@ AC_CHECK_LIB(ibverbs,
[],
AC_MSG_ERROR([libibverbs not installed]))
+dnl Checks for header files.
+AC_CHECK_HEADER(infiniband/driver.h, [],
+ AC_MSG_ERROR([<infiniband/driver.h> not found. libehca requires libibverbs.]))
+
dnl Checks for library functions
AC_CHECK_FUNCS(ibv_read_sysfs_file)
fi
+AC_CHECK_HEADERS(sysfs/libsysfs.h)
dnl Checks for programs.
AC_PROG_CC
More information about the ewg
mailing list