A second attempt, this time with less suck :).

Brian

On Fri, 22 Feb 2008, Brian W. Barrett wrote:

Oops..  forgot to test the C++ bindings, which of course broke.  Let me
try again and I'll send a better patch.

brian

On Fri, 22 Feb 2008, Brian W. Barrett wrote:

On Thu, 21 Feb 2008, Jeff Squyres wrote:

While I agree that having AC actually define them to a value is a Good
Thing (better than just defining it to be empty), I do see the pickle
that it has put us in.  :-\  I don't see an obvious solution.

I do :).  Try the attached patch.  It sneaks in at the last minute and
defines (for example) both SIZEOF_BOOL and OMPI_SIZEOF_BOOL.  mpi.h only has
the define for OMPI_SIZEOF_BOOL.  opal_config.h has both, but a note saying
not to use the OMPI_ version.  Seems to work.

Brian

_______________________________________________
users mailing list
us...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/users

Index: include/mpi.h.in
===================================================================
--- include/mpi.h.in	(revision 17548)
+++ include/mpi.h.in	(working copy)
@@ -33,6 +33,21 @@
    ompi_config.h must be included before all other files, so this
    should be good enough */
 
+/* Define to 1 if you have the ANSI C header files. */
+#undef OMPI_STDC_HEADERS
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#undef OMPI_HAVE_SYS_TIME_H
+
+/* Define to 1 if the system has the type `long long'. */
+#undef OMPI_HAVE_LONG_LONG
+
+/* The size of a `bool', as computed by sizeof. */
+#undef OMPI_SIZEOF_BOOL
+
+/* The size of a `int', as computed by sizeof. */
+#undef OMPI_SIZEOF_INT
+
 /* Whether we have FORTRAN LOGICAL*1 or not */
 #undef OMPI_HAVE_FORTRAN_LOGICAL1
 
@@ -72,18 +87,6 @@
 /* Whether we have FORTRAN REAL*8 or not */
 #undef OMPI_HAVE_FORTRAN_REAL8
 
-/* Define to 1 if you have the <sys/time.h> header file. */
-#undef HAVE_SYS_TIME_H
-
-/* Define to 1 if the system has the type `long long'. */
-#undef HAVE_LONG_LONG
-
-/* The size of a `bool', as computed by sizeof. */
-#undef SIZEOF_BOOL
-
-/* The size of a `int', as computed by sizeof. */
-#undef SIZEOF_INT
-
 /* Type of MPI_Offset -- has to be defined here and typedef'ed later because mpi.h does not get AC SUBST's */
 #undef OMPI_MPI_OFFSET_TYPE
 
@@ -111,9 +114,6 @@
 /* MPI datatype corresponding to MPI_Offset */
 #undef OMPI_OFFSET_DATATYPE
 
-/* Define to 1 if you have the ANSI C header files. */
-#undef STDC_HEADERS
-
 /* Major, minor, and release version of Open MPI */
 #undef OMPI_MAJOR_VERSION
 #undef OMPI_MINOR_VERSION
Index: mpi/cxx/comm_inln.h
===================================================================
--- mpi/cxx/comm_inln.h	(revision 17548)
+++ mpi/cxx/comm_inln.h	(working copy)
@@ -648,7 +648,7 @@
 			 void* extra_state, void* attribute_val_in,
 			 void* attribute_val_out, bool& flag)
 {
-#if SIZEOF_BOOL != SIZEOF_INT
+#if OMPI_SIZEOF_BOOL != OMPI_SIZEOF_INT
   int f = (int)flag;
   int ret;
   ret = MPI_DUP_FN(oldcomm, comm_keyval, extra_state, attribute_val_in,

Reply via email to