summaryrefslogtreecommitdiffstats
path: root/src/H5Fmpio.c
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>1998-06-10 05:20:20 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>1998-06-10 05:20:20 (GMT)
commit328097d60e10c72283d15abea567080ecd6638e8 (patch)
tree38d77ef2d546a019ce8cb4642fbda1fb25e4fa41 /src/H5Fmpio.c
parent865a463b1fdf29fb7ff5b3a1930d77e39d09bce4 (diff)
downloadhdf5-328097d60e10c72283d15abea567080ecd6638e8.zip
hdf5-328097d60e10c72283d15abea567080ecd6638e8.tar.gz
hdf5-328097d60e10c72283d15abea567080ecd6638e8.tar.bz2
[svn-r415] Problem:
H5Fmpio.c was not part of the serial distribution. The auto- dependence configuration runs for serail distribution only, thus H5Fmpio.c has no dependence. It ended up not recompiled even when header files it depends on are changed. Solution: Changed configuration to always include this file. Enclosed the whole code in a big #ifdef HAVE_PARALLEL macro so that they would be compiled for parallel distribution only. Platform tested: O2K
Diffstat (limited to 'src/H5Fmpio.c')
-rw-r--r--src/H5Fmpio.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/src/H5Fmpio.c b/src/H5Fmpio.c
index 4f6c275..74a75f4 100644
--- a/src/H5Fmpio.c
+++ b/src/H5Fmpio.c
@@ -42,9 +42,6 @@
* requested. This kluge is activated by #ifdef MPI_KLUGE0202.
*
*/
-#include <mpi.h>
-#include <mpio.h>
-#include <H5private.h>
#include <H5private.h>
#include <H5Eprivate.h>
#include <H5Dprivate.h>
@@ -53,6 +50,21 @@
#include <sys/types.h>
#include <sys/stat.h>
+#ifndef HAVE_PARALLEL
+/*
+ * The H5F_mpio_xxxx functions are for parallel I/O only and are
+ * valid only when HAVE_PARALLEL is #defined. This empty #ifndef
+ * body is used to allow this source file be included in the serial
+ * distribution.
+ * Some compilers/linkers may complain about "empty" object file.
+ * If that happens, uncomment the following statement to pacify
+ * them.
+ */
+/* const hbool_t H5F_mpio_avail = FALSE; */
+#else /* HAVE_PARALLEL */
+#include <mpi.h>
+#include <mpio.h>
+
#define PABLO_MASK H5F_mpio
static hbool_t interface_initialize_g = FALSE; /* rky??? */
#define INTERFACE_INIT NULL
@@ -677,3 +689,5 @@ H5F_haddr_to_MPIOff( haddr_t addr, MPI_Offset *mpi_off )
return (ret_val);
}
+
+#endif /* HAVE_PARALLEL */