summaryrefslogtreecommitdiffstats
path: root/tools/h5import.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/h5import.c')
-rw-r--r--tools/h5import.c26
1 files changed, 19 insertions, 7 deletions
diff --git a/tools/h5import.c b/tools/h5import.c
index a5c030a..5d36e78 100644
--- a/tools/h5import.c
+++ b/tools/h5import.c
@@ -7,15 +7,27 @@
*
* Purpose: Create an hdf5 file with a 1d dataset of uint8.
*/
-#include <fcntl.h>
-#include <hdf5.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <sys/stat.h>
+
+/* See H5private.h for how to include system headers */
+#include <H5config.h>
+#ifdef STDC_HEADERS
+# include <fcntl.h>
+# include <string.h>
+# include <stdlib.h>
+# include <stdio.h>
+#endif
+
#ifdef HAVE_UNISTD_H
-#include <unistd.h>
+# include <sys/types.h>
+# include <unistd.h>
#endif
+
+#ifdef HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#include <hdf5.h>
+
/*-------------------------------------------------------------------------
* Function: usage