forked from Lainports/freebsd-ports
compatible version in sys/ipmi.h if it exists. Enable OpenIPMI mode. Initial patches by me, polishing by Dmitry (maintainer). Dmitry will be submitting these changes to the ipmitool developers. Approved by: Maintainer
45 lines
1.6 KiB
Text
45 lines
1.6 KiB
Text
diff -ruN ../ipmitool-1.8.6/config.h.in ./config.h.in
|
|
--- ../ipmitool-1.8.6/config.h.in Tue Jan 17 23:54:02 2006
|
|
+++ ./config.h.in Thu Feb 16 15:41:18 2006
|
|
@@ -24,6 +24,9 @@
|
|
/* Define to 1 if you have the <fcntl.h> header file. */
|
|
#undef HAVE_FCNTL_H
|
|
|
|
+/* Define to 1 if you have the <sys/ipmi.h> header file. */
|
|
+#undef HAVE_FREEBSD_IPMI_H
|
|
+
|
|
/* Define to 1 if you have the `gethostbyname' function. */
|
|
#undef HAVE_GETHOSTBYNAME
|
|
|
|
diff -ruN ../ipmitool-1.8.6/configure.in ./configure.in
|
|
--- ../ipmitool-1.8.6/configure.in Tue Jan 17 23:50:29 2006
|
|
+++ ./configure.in Thu Feb 16 15:48:14 2006
|
|
@@ -192,7 +192,10 @@
|
|
AC_CHECK_HEADER([linux/ipmi.h],
|
|
[AC_DEFINE(HAVE_OPENIPMI_H, [1],
|
|
[Define to 1 if you have the <linux/ipmi.h> header file.])],
|
|
- [echo "** Unable to find OpenIPMI header files. Using internal version."])
|
|
+ [AC_CHECK_HEADER([sys/ipmi.h],
|
|
+ [AC_DEFINE(HAVE_FREEBSD_IPMI_H, [1],
|
|
+ [Define to 1 if you have the <sys/ipmi.h> header file.])],
|
|
+ [echo "** Unable to find OpenIPMI header files. Using internal version."])])
|
|
|
|
dnl set RPM distro tag for use in RPM name
|
|
AC_ARG_WITH([rpm-distro],
|
|
diff -ruN ../ipmitool-1.8.6/src/plugins/open/open.c ./src/plugins/open/open.c
|
|
--- ../ipmitool-1.8.6/src/plugins/open/open.c Tue Jul 12 21:49:12 2005
|
|
+++ ./src/plugins/open/open.c Thu Feb 16 15:41:51 2006
|
|
@@ -51,9 +51,12 @@
|
|
|
|
#include <config.h>
|
|
|
|
-#ifdef HAVE_OPENIPMI_H
|
|
+#if defined(HAVE_OPENIPMI_H)
|
|
# include <linux/compiler.h>
|
|
# include <linux/ipmi.h>
|
|
+#elif defined(HAVE_FREEBSD_IPMI_H)
|
|
+/* FreeBSD OpenIPMI-compatible header */
|
|
+# include <sys/ipmi.h>
|
|
#else
|
|
# include "open.h"
|
|
#endif
|