summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Wendling <wendling@ncsa.uiuc.edu>2002-07-17 16:10:46 (GMT)
committerBill Wendling <wendling@ncsa.uiuc.edu>2002-07-17 16:10:46 (GMT)
commitceba60418cdeb53eae7d953ec6fc9cc1f58efff1 (patch)
treedff97a1ffc292f5b479871b9c1c82106f30db0e5
parent23670c0cf63d08c4f78ea3e8f157bf58aab92b5a (diff)
downloadhdf5-ceba60418cdeb53eae7d953ec6fc9cc1f58efff1.zip
hdf5-ceba60418cdeb53eae7d953ec6fc9cc1f58efff1.tar.gz
hdf5-ceba60418cdeb53eae7d953ec6fc9cc1f58efff1.tar.bz2
[svn-r5807] Purpose:
Update, Bug Fix, and Feature Add Description: - Updated how AC_{ENABLE,WITH} help messages were being generated. Autoconf now gives you an AC_HELP_STRING macro to use to create them. - Fixed the problem with Linux LFS on RedHat 7.3 machines. It wasn't finding getdents64(), so we can't rely on that being present anymore... - Added GPFS detection and setting. - Updated how compression is specified. It's no longer necessary to test for HAVE_ZLIB_H, HAVE_LIBZ, and HAVE_COMPRESS2. The one macro {H5_}HAVE_COMPRESSION takes care of all of these. Solution: Changed the check for Linux LFS from looking for getdents() to looking at the version number of the kernel (using the uname -r command). You can still override with the --enable-linux-lfs switch if you really believe that your <2.4 kernel has LFS support. Platforms tested: Linux (2.2 and 2.4)
-rw-r--r--c++/test/dsets.cpp14
-rwxr-xr-xconfigure498
-rw-r--r--configure.in520
-rw-r--r--perform/pio_engine.c167
-rw-r--r--perform/zip_perf.c4
-rw-r--r--src/H5Zdeflate.c8
-rw-r--r--src/H5config.h.in13
-rw-r--r--test/dsets.c18
8 files changed, 825 insertions, 417 deletions
diff --git a/c++/test/dsets.cpp b/c++/test/dsets.cpp
index 2876bb2..a5b66b5 100644
--- a/c++/test/dsets.cpp
+++ b/c++/test/dsets.cpp
@@ -445,7 +445,7 @@ test_compression(H5File& file)
DataSet* dataset = new DataSet (file.createDataSet
(DSET_COMPRESS_NAME, PredType::NATIVE_INT, space1, dscreatplist));
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -471,7 +471,7 @@ test_compression(H5File& file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -496,7 +496,7 @@ test_compression(H5File& file)
//if (H5Dwrite(dataset, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, xfer, points)<0) goto error;
dataset->write ((void*) points, PredType::NATIVE_INT, DataSpace::ALL, DataSpace::ALL, xfer);
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -520,7 +520,7 @@ test_compression(H5File& file)
if (status == -1) goto error;
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -556,7 +556,7 @@ test_compression(H5File& file)
if (status == -1) goto error;
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -585,7 +585,7 @@ test_compression(H5File& file)
if (status == -1) goto error;
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -628,7 +628,7 @@ test_compression(H5File& file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
diff --git a/configure b/configure
index ad7c1ac..8e770d3 100755
--- a/configure
+++ b/configure
@@ -991,27 +991,27 @@ if test -n "$ac_init_help"; then
Optional Features:
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --disable-hsizet Datasets can normally be larger than memory
- and/or files but some compilers are unable to
- handle this (including versions of GCC before
- 2.8.0). Disabling the feature causes dataset
- sizes to be restricted to the size of core memory,
- or 'size_t'.
- --enable-fortran Compile the Fortran interface default=no
- --enable-cxx Compile the C++ interface default=no
- --enable-static-exec Build only statically linked executables default=no
+ --disable-hsizet Datasets can normally be larger than memory and/or
+ files but some compilers are unable to handle this
+ (including versions of GCC before 2.8.0). Disabling
+ the feature causes dataset sizes to be restricted to
+ the size of core memory, or 'size_t'.
+ --enable-fortran Compile the Fortran interface [default=no]
+ --enable-cxx Compile the C++ interface [default=no]
+ --enable-static-exec Build only statically linked executables
+ [default=no]
--enable-shared=PKGS build shared libraries default=yes
--enable-static=PKGS build static libraries default=yes
--enable-fast-install=PKGS optimize for fast installation default=yes
--disable-libtool-lock avoid locking (might break parallel builds)
--enable-production Determines how to run the compiler.
--enable-linux-lfs Enable support for large (64-bit) files on Linux.
- default=check
+ [default=check]
--enable-threadsafe Enable thread safe capability
--enable-hdf5v1_4 Compile the HDF5 v1.4 compatibility interface
- default=no
- --enable-stream-vfd Build the Stream Virtual File Driver default=no
- --enable-debug=all Turn on debugging in all packages. One may also
+ [default=no]
+ --enable-stream-vfd Build the Stream Virtual File Driver [default=no]
+ --enable-debug=all Turn on debugging in all packages. One may also
specify a comma-separated list of package names
without the leading H5 or the word no. The default
is most packages.
@@ -1032,13 +1032,13 @@ Optional Packages:
--with-xxx=DIR - Specify only the directory which contains the
include/ and lib/ subdirectories
- --with-dmalloc=DIR Use dmalloc memory debugging aid (default=no)
- --with-zlib=DIR Use GNU zlib compression default=yes
- --with-pablo=DIR Use the Pablo library default=no
- --with-ssl=LIB Use the SSL library default=no
- --with-gass=DIR Use the GASS library default=no
- --with-srb=DIR Use the SRB library default=no
- --with-pthread=DIR Use the Pthreads library default=no
+ --with-dmalloc=DIR Use dmalloc memory debugging aid [default=no]
+ --with-zlib=DIR Use GNU zlib compression [default=yes]
+ --with-pablo=DIR Use the Pablo library [default=no]
+ --with-ssl=LIB Use the SSL library [default=no]
+ --with-gass=DIR Use the GASS library [default=no]
+ --with-srb=DIR Use the SRB library [default=no]
+ --with-pthread=DIR Use the Pthreads library [default=no]
Some influential environment variables:
CC C compiler command
@@ -7285,6 +7285,7 @@ esac
echo "$as_me:$LINENO: checking make" >&5
echo $ECHO_N "checking make... $ECHO_C" >&6
+
if test "`${MAKE-make} --version -f /dev/null 2>/dev/null |\
sed -n 1p|cut -c1-8`" = "GNU Make"; then
echo "$as_me:$LINENO: result: GNU make" >&5
@@ -7331,6 +7332,7 @@ echo "${ECHO_T}you have a deficient make command" >&6
DEPEND=config/dependN
break
done
+
rm makeinc maketest
fi
@@ -7416,32 +7418,32 @@ fi;
case "X-$enable_production" in
X-yes)
enable_production="yes"
- echo "$as_me:$LINENO: result: \"production\"" >&5
-echo "${ECHO_T}\"production\"" >&6
+ echo "$as_me:$LINENO: result: production" >&5
+echo "${ECHO_T}production" >&6
CONFIG_MODE=production
CFLAGS="$CFLAGS $PROD_CFLAGS"
CPPFLAGS="$CPPFLAGS $PROD_CPPFLAGS"
;;
X-|X-no)
enable_production="no"
- echo "$as_me:$LINENO: result: \"development\"" >&5
-echo "${ECHO_T}\"development\"" >&6
+ echo "$as_me:$LINENO: result: development" >&5
+echo "${ECHO_T}development" >&6
CONFIG_MODE=development
CFLAGS="$CFLAGS $DEBUG_CFLAGS"
CPPFLAGS="$CPPFLAGS $DEBUG_CPPFLAGS"
;;
X-pg|X-profile)
enable_production="profile"
- echo "$as_me:$LINENO: result: \"profile\"" >&5
-echo "${ECHO_T}\"profile\"" >&6
+ echo "$as_me:$LINENO: result: profile" >&5
+echo "${ECHO_T}profile" >&6
CONFIG_MODE=profile
CFLAGS="$CFLAGS $PROFILE_CFLAGS"
CPPFLAGS="$CPPFLAGS $PROFILE_CPPFLAGS"
;;
*)
enable_production="user-defined"
- echo "$as_me:$LINENO: result: \"user-defined\"" >&5
-echo "${ECHO_T}\"user-defined\"" >&6
+ echo "$as_me:$LINENO: result: user-defined" >&5
+echo "${ECHO_T}user-defined" >&6
CONFIG_MODE="$X-enableval"
;;
esac
@@ -7782,6 +7784,7 @@ fi
+
for ac_header in sys/resource.h sys/time.h unistd.h sys/ioctl.h sys/stat.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
@@ -8243,6 +8246,7 @@ done
+
for ac_header in io.h winsock.h sys/timeb.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
@@ -8485,100 +8489,28 @@ if test "${enable_linux_lfs+set}" = set; then
fi;
+ LINUX_LFS="no"
case "X-$enable_linux_lfs" in
X-yes)
LINUX_LFS=yes
;;
X-no)
- LINUX_LFS=no
;;
X-|*)
- LINUX_LFS=no
-
-for ac_func in getdents64
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-#line $LINENO "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
-
-#ifdef F77_DUMMY_MAIN
-# ifdef __cplusplus
- extern "C"
-# endif
- int F77_DUMMY_MAIN() { return 1; }
-#endif
-int
-main ()
-{
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func;
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- eval "$as_ac_var=yes"
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-eval "$as_ac_var=no"
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
- LINUX_LFS=yes
-fi
-done
+ MAJOR_VER="`uname -r | cut -d '.' -f1`"
+ MINOR_VER="`uname -r | cut -d '.' -f2`"
+ if test $MAJOR_VER -ge 2 -a $MINOR_VER -ge 4; then
+ LINUX_LFS="yes"
+ fi
;;
esac
- echo "$as_me:$LINENO: checking for large file support on linux mode" >&5
-echo $ECHO_N "checking for large file support on linux mode... $ECHO_C" >&6
+ echo "$as_me:$LINENO: checking for large file support mode on Linux" >&5
+echo $ECHO_N "checking for large file support mode on Linux... $ECHO_C" >&6
if test "X$LINUX_LFS" = "Xyes"; then
echo "$as_me:$LINENO: result: enabled" >&5
echo "${ECHO_T}enabled" >&6
-
CPPFLAGS="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE $CPPFLAGS"
else
echo "$as_me:$LINENO: result: disabled" >&5
@@ -8634,11 +8566,8 @@ else
cat >conftest.$ac_ext <<_ACEOF
#line $LINENO "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-which can conflict with char $ac_func (); below. */
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func (); below. */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error. */
#ifdef __cplusplus
@@ -8701,6 +8630,11 @@ _ACEOF
fi
done
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+echo "$as_me:$LINENO: result: skipping test for lseek64() and fseek64()" >&5
+echo "${ECHO_T}skipping test for lseek64() and fseek64()" >&6
fi
rm -f conftest.$ac_objext conftest.$ac_ext
@@ -21820,6 +21754,7 @@ cat >>confdefs.h <<_ACEOF
_ACEOF
+
cat >>confdefs.h <<\EOF
#include <sys/types.h> /*for off_t definition*/
EOF
@@ -22847,7 +22782,7 @@ if test `eval echo '${'$as_ac_Header'}'` = yes; then
cat >>confdefs.h <<_ACEOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-
+ HAVE_ZLIB_H="yes"
fi
done
@@ -22919,6 +22854,74 @@ else
unset HAVE_ZLIB
fi
+ echo "$as_me:$LINENO: checking for compress2" >&5
+echo $ECHO_N "checking for compress2... $ECHO_C" >&6
+if test "${ac_cv_func_compress2+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char compress2 (); below. */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char compress2 ();
+char (*f) ();
+
+#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+int
+main ()
+{
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_compress2) || defined (__stub___compress2)
+choke me
+#else
+f = compress2;
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_func_compress2=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+ac_cv_func_compress2=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_func_compress2" >&5
+echo "${ECHO_T}$ac_cv_func_compress2" >&6
+if test $ac_cv_func_compress2 = yes; then
+ HAVE_COMPRESS2="yes"
+fi
+
if test -z "$HAVE_ZLIB" -a -n "$HDF5_CONFIG_ABORT"; then
{ { echo "$as_me:$LINENO: error: couldn't find zlib library" >&5
@@ -23064,7 +23067,7 @@ if test `eval echo '${'$as_ac_Header'}'` = yes; then
cat >>confdefs.h <<_ACEOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
-
+ HAVE_ZLIB_H="yes"
else
CPPFLAGS="$saved_CPPFLAGS"
fi
@@ -23143,6 +23146,74 @@ else
LDFLAGS="$saved_LDFLAGS"; unset HAVE_ZLIB
fi
+ echo "$as_me:$LINENO: checking for compress2" >&5
+echo $ECHO_N "checking for compress2... $ECHO_C" >&6
+if test "${ac_cv_func_compress2+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char compress2 (); below. */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char compress2 ();
+char (*f) ();
+
+#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+int
+main ()
+{
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_compress2) || defined (__stub___compress2)
+choke me
+#else
+f = compress2;
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_func_compress2=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+ac_cv_func_compress2=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_func_compress2" >&5
+echo "${ECHO_T}$ac_cv_func_compress2" >&6
+if test $ac_cv_func_compress2 = yes; then
+ HAVE_COMPRESS2="yes"
+fi
+
if test -z "$HAVE_ZLIB" -a -n "$HDF5_CONFIG_ABORT"; then
{ { echo "$as_me:$LINENO: error: couldn't find zlib library" >&5
@@ -23152,6 +23223,14 @@ echo "$as_me: error: couldn't find zlib library" >&2;}
;;
esac
+if test "x$HAVE_ZLIB" = "xyes" -a "x$HAVE_ZLIB_H" = "xyes" -a "x$HAVE_COMPRESS2" = "xyes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_COMPRESSION 1
+_ACEOF
+
+fi
+
PABLO=""
HAVE_PABLO="no"
@@ -28535,8 +28614,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext
-
-for ac_func in compress2 difftime fork gethostname getpwuid getrusage
+for ac_func in difftime fork gethostname getpwuid getrusage
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:$LINENO: checking for $ac_func" >&5
@@ -29167,7 +29245,6 @@ fi
done
fi
-
echo "$as_me:$LINENO: result: %${hdf5_cv_printf_ll}d and %${hdf5_cv_printf_ll}u" >&5
echo "${ECHO_T}%${hdf5_cv_printf_ll}d and %${hdf5_cv_printf_ll}u" >&6
@@ -29237,6 +29314,169 @@ else
echo "${ECHO_T}no" >&6
fi
+
+for ac_header in gpfs.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+else
+ # Is the header compilable?
+echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.h"
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_header_compiler=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+ac_header_compiler=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6
+
+# Is the header present?
+echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.h"
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ egrep -v '^ *\+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ ac_header_preproc=yes
+else
+ echo "$as_me: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ ac_header_preproc=no
+fi
+rm -f conftest.err conftest.$ac_ext
+echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc in
+ yes:no )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
+ no:yes )
+ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
+esac
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ eval "$as_ac_Header=$ac_header_preproc"
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+ echo "$as_me:$LINENO: checking for GPFS support" >&5
+echo $ECHO_N "checking for GPFS support... $ECHO_C" >&6
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.h"
+#include <gpfs.h>
+#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+int
+main ()
+{
+int fd = 0; gpfs_fcntl(fd, (void *)0);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_GPFS 1
+_ACEOF
+
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ LIBS="$LIBS -lgpfs"
+ GPFS="yes"
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+ GPFS="no"
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+fi
+
+done
+
+
echo "$as_me:$LINENO: checking for debug flags" >&5
echo $ECHO_N "checking for debug flags... $ECHO_C" >&6
# Check whether --enable-debug or --disable-debug was given.
@@ -29279,7 +29519,7 @@ if test -n "$DEBUG_PKG"; then
fi
echo "$as_me:$LINENO: checking for API tracing" >&5
-echo $ECHO_N "checking for API tracing... $ECHO_C" >&6;
+echo $ECHO_N "checking for API tracing... $ECHO_C" >&6
# Check whether --enable-trace or --disable-trace was given.
if test "${enable_trace+set}" = set; then
enableval="$enable_trace"
@@ -29287,6 +29527,7 @@ if test "${enable_trace+set}" = set; then
fi;
+
if test -z "$TRACE" -o "X$TRACE" = "Xyes"; then
echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6
@@ -29413,7 +29654,7 @@ echo $ECHO_N "checking for mpirun_lam or mpirun... $ECHO_C" >&6
cmd=mpirun
fi
echo "$as_me:$LINENO: result: $path/$cmd" >&5
-echo "${ECHO_T}$path/$cmd" >&6;
+echo "${ECHO_T}$path/$cmd" >&6
RUNSERIAL="${RUNSERIAL:-none}"
if test -z "$RUNPARALLEL"; then
RUNPARALLEL="$path/$cmd -np \$\${NPROCS:=3}"
@@ -31399,8 +31640,8 @@ IF_YES_NO() {
else
while test $# -gt 0; do
if test "$1" != "yes"; then
- PRINT "No"
- return
+ PRINT "No"
+ return
fi
shift
done
@@ -31453,7 +31694,7 @@ else
PRINT "No"
fi
-PRINT "Features:"
+PRINT "Languages:"
PRINT_N " C++"
IF_YES_NO "$HDF_CXX"
@@ -31461,9 +31702,17 @@ IF_YES_NO "$HDF_CXX"
PRINT_N " Fortran"
IF_YES_NO "$HDF_FORTRAN"
+PRINT "Features:"
+
+PRINT_N " dmalloc"
+IF_YES_NO "$HAVE_DMALLOC"
+
PRINT_N " GASS"
IF_YES_NO "$GASS"
+PRINT_N " GPFS"
+IF_YES_NO "$GPFS"
+
PRINT_N " HDF5 v1.4 Compatibility"
IF_YES_NO "$HDF5_V1_4_COMPAT"
@@ -31497,6 +31746,3 @@ IF_ENABLED_DISABLED "$THREADSAFE"
PRINT_N " Zlib-compression"
IF_YES_NO "$HAVE_ZLIB"
-
-PRINT_N " dmalloc"
-IF_YES_NO "$HAVE_DMALLOC"
diff --git a/configure.in b/configure.in
index 4422aba..53820e1 100644
--- a/configure.in
+++ b/configure.in
@@ -1,8 +1,16 @@
dnl Process this file with autoconf to produce configure.
dnl
-dnl Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002
-dnl National Center for Supercomputing Applications
-dnl All rights reserved.
+dnl Copyright by the Board of Trustees of the University of Illinois.
+dnl All rights reserved.
+dnl
+dnl This file is part of HDF5. The full HDF5 copyright notice, including
+dnl terms governing use, modification, and redistribution, is contained in
+dnl the files COPYING and Copyright.html. COPYING can be found at the root
+dnl of the source code distribution tree; Copyright.html can be found at the
+dnl root level of an installed copy of the electronic HDF5 document set and
+dnl is linked from the top-level documents page. It can also be found at
+dnl http://hdf.ncsa.uiuc.edu/HDF5/doc/Copyright.html. If you do not have
+dnl access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu.
dnl ----------------------------------------------------------------------
dnl Initialize configure.
@@ -37,20 +45,20 @@ AC_OUTPUT_COMMANDS([
])
AC_CANONICAL_HOST
-AC_SUBST(CPPFLAGS)
+AC_SUBST([CPPFLAGS])
dnl ----------------------------------------------------------------------
dnl Dump all shell variables values.
dnl
-AC_MSG_CHECKING(shell variables initial values)
-set >&5
-AC_MSG_RESULT(done)
+AC_MSG_CHECKING([shell variables initial values])
+set >&AS_MESSAGE_LOG_FD
+AC_MSG_RESULT([done])
dnl ----------------------------------------------------------------------
dnl Check that the cache file was build on the same host as what we're
dnl running on now.
dnl
-AC_CACHE_CHECK(for cached host,hdf5_cv_host,hdf5_cv_host="none");
+AC_CACHE_CHECK([for cached host], [hdf5_cv_host], [hdf5_cv_host="none"]);
if test $hdf5_cv_host = "none"; then
hdf5_cv_host=$host
elif test $hdf5_cv_host != $host; then
@@ -105,27 +113,29 @@ case $host_os in
;;
esac
-AC_ARG_ENABLE(hsizet,
- [ --disable-hsizet Datasets can normally be larger than memory
- and/or files but some compilers are unable to
- handle this (including versions of GCC before
- 2.8.0). Disabling the feature causes dataset
- sizes to be restricted to the size of core memory,
- or 'size_t'.],
- HSIZET=$enableval)
+AC_ARG_ENABLE([hsizet],
+ [AC_HELP_STRING([--disable-hsizet],
+ [Datasets can normally be larger than
+ memory and/or files but some compilers are
+ unable to handle this (including versions
+ of GCC before 2.8.0). Disabling the
+ feature causes dataset sizes to be
+ restricted to the size of core memory, or
+ 'size_t'.])],
+ [HSIZET=$enableval])
-AC_MSG_CHECKING(for sizeof hsize_t and hssize_t)
+AC_MSG_CHECKING([for sizeof hsize_t and hssize_t])
AC_SUBST(HSIZET)
case $HSIZET in
no|small)
- AC_MSG_RESULT(small)
+ AC_MSG_RESULT([small])
HSIZET=small
;;
*)
- AC_MSG_RESULT(large)
+ AC_MSG_RESULT([large])
HSIZET=large
- AC_DEFINE(HAVE_LARGE_HSIZET, 1,
+ AC_DEFINE([HAVE_LARGE_HSIZET], [1],
[Define if it's safe to use \`long long' for hsize_t and hssize_t])
;;
esac
@@ -142,13 +152,13 @@ for f in $host_cpu-$host_vendor-$host_os \
$host_os_novers \
$host_vendor \
$host_cpu ; do
- AC_MSG_CHECKING(for config $f)
+ AC_MSG_CHECKING([for config $f])
if test -f "$srcdir/config/$f"; then
host_config=$srcdir/config/$f
- AC_MSG_RESULT(found)
+ AC_MSG_RESULT([found])
break
fi
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT([no])
done
if test $host_config != "none"; then
CC_BASENAME="`echo $CC | cut -f1 -d' ' | xargs basename 2>/dev/null`"
@@ -159,13 +169,13 @@ dnl Source any special site-specific file
hname="`hostname`"
while test -n "$hname"; do
file=$srcdir/config/site-specific/host-$hname
- AC_MSG_CHECKING(for config $file)
+ AC_MSG_CHECKING([for config $file])
if test -f "$file"; then
. $file
- AC_MSG_RESULT(found)
+ AC_MSG_RESULT([found])
break
fi
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT([no])
hname_tmp=$hname
hname="`echo $hname | cut -d. -f2-99`"
test "$hname_tmp" = "$hname" && break
@@ -177,15 +187,16 @@ dnl
AC_PROG_CC
CC_BASENAME="`echo $CC | cut -f1 -d' ' | xargs basename 2>/dev/null`"
-AC_SUBST(config_dirs) config_dirs=""
+AC_SUBST([config_dirs]) config_dirs=""
dnl ----------------------------------------------------------------------
dnl Check if they would like the Fortran interface compiled
dnl
-AC_MSG_CHECKING(if fortran interface enabled)
-AC_ARG_ENABLE(fortran,
- [ --enable-fortran Compile the Fortran interface [default=no]],
- HDF_FORTRAN=$enableval)
+AC_MSG_CHECKING([if fortran interface enabled])
+AC_ARG_ENABLE([fortran],
+ [AC_HELP_STRING([--enable-fortran],
+ [Compile the Fortran interface [default=no]])],
+ [HDF_FORTRAN=$enableval])
if test "X$HDF_FORTRAN" = "Xyes"; then
echo "yes"
@@ -201,10 +212,11 @@ fi
dnl ----------------------------------------------------------------------
dnl Check if they would like the C++ interface compiled
dnl
-AC_MSG_CHECKING(if c++ interface enabled)
-AC_ARG_ENABLE(cxx,
- [ --enable-cxx Compile the C++ interface [default=no]],
- HDF_CXX=$enableval)
+AC_MSG_CHECKING([if c++ interface enabled])
+AC_ARG_ENABLE([cxx],
+ [AC_HELP_STRING([--enable-cxx],
+ [Compile the C++ interface [default=no]])],
+ [HDF_CXX=$enableval])
if test "X$HDF_CXX" = "Xyes"; then
echo "yes"
@@ -218,15 +230,17 @@ else
fi
dnl Run configure in the subdirectories if specified
-AC_CONFIG_SUBDIRS(${config_dirs})
+AC_CONFIG_SUBDIRS([${config_dirs}])
dnl ----------------------------------------------------------------------
dnl If we should build only static executables
dnl
-AC_MSG_CHECKING(if should build only statically linked executables)
-AC_ARG_ENABLE(static_exec,
- [ --enable-static-exec Build only statically linked executables [default=no]],
- STATIC_EXEC=$enableval)
+AC_MSG_CHECKING([if should build only statically linked executables])
+AC_ARG_ENABLE([static_exec],
+ [AC_HELP_STRING([--enable-static-exec],
+ [Build only statically linked executables
+ [default=no]])],
+ [STATIC_EXEC=$enableval])
if test "X$STATIC_EXEC" = "Xyes"; then
echo "yes"
@@ -235,25 +249,25 @@ else
echo "no"
LT_STATIC_EXEC=""
fi
-AC_SUBST(LT_STATIC_EXEC)
+AC_SUBST([LT_STATIC_EXEC])
dnl ----------------------------------------------------------------------
dnl Check if they have Perl installed on their system. We only need Perl
dnl if they're using a GNU compiler.
dnl
-AC_SUBST(PERL) PERL=""
+AC_SUBST([PERL]) PERL=""
if test "X$GCC" = "Xyes"; then
- AC_CHECK_PROGS(PERL, perl,, $PATH)
+ AC_CHECK_PROGS([PERL], [perl],, [$PATH])
fi
dnl ----------------------------------------------------------------------
dnl Check which archiving tool to use. This needs to be done before
-dnl the AM_PROG_LIBTOOL macro.
+dnl the AC_PROG_LIBTOOL macro.
dnl
if test -z "$AR"; then
- AC_CHECK_PROGS(AR,ar xar,:,$PATH)
+ AC_CHECK_PROGS([AR], [ar xar], [:], [$PATH])
fi
-AC_SUBST(AR)
+AC_SUBST([AR])
dnl Export the AR macro so that it will be placed in the libtool file
dnl correctly.
@@ -262,7 +276,7 @@ export AR
AC_PROG_MAKE_SET
AC_PROG_INSTALL
AC_LIBTOOL_DLOPEN
-AM_PROG_LIBTOOL
+AC_PROG_LIBTOOL
dnl Fix up the INSTALL macro if it's a relative path. We want the
dnl full-path to the binary instead.
@@ -272,11 +286,12 @@ case "$INSTALL" in
;;
esac
-AC_MSG_CHECKING(make)
-AC_SUBST_FILE(DEPEND)
+AC_MSG_CHECKING([make])
+AC_SUBST_FILE([DEPEND])
+
if test "`${MAKE-make} --version -f /dev/null 2>/dev/null |\
sed -n 1p|cut -c1-8`" = "GNU Make"; then
- AC_MSG_RESULT(GNU make)
+ AC_MSG_RESULT([GNU make])
GMAKE=yes
if test "X$GCC" = "Xyes"; then
DEPEND=config/depend1
@@ -284,12 +299,12 @@ if test "`${MAKE-make} --version -f /dev/null 2>/dev/null |\
DEPEND=config/depend2
fi
else
- AC_MSG_RESULT(generic)
+ AC_MSG_RESULT([generic])
fi
dnl How do we include another file into a Makefile?
if test -z "$DEPEND"; then
- AC_MSG_CHECKING(how to include a makefile)
+ AC_MSG_CHECKING([how to include a makefile])
dnl The include file contains the target for `foo'
cat >makeinc <<EOF
@@ -310,16 +325,17 @@ EOF
dnl Most make's use `include FILE'
echo 'include makeinc' >maketest
if (${MAKE-make} -f maketest foo) >/dev/null 2>&1; then
- AC_MSG_RESULT(include FILE)
+ AC_MSG_RESULT([include FILE])
DEPEND=config/depend4
break;
fi
dnl default
- AC_MSG_RESULT(you have a deficient make command)
+ AC_MSG_RESULT([you have a deficient make command])
DEPEND=config/dependN
break
done
+
rm makeinc maketest
fi
@@ -328,7 +344,7 @@ dnl Sometimes makes think the `.PATH:' appearing before the first rule
dnl with an action should override the `all' default target. So we have
dnl to decide what the proper syntax is.
dnl
-AC_MSG_CHECKING(how make searches directories)
+AC_MSG_CHECKING([how make searches directories])
while true; do #for break
# The most common method is `VPATH=DIR1 DIR2 ...'
cat >maketest <<EOF
@@ -390,7 +406,7 @@ EOF
SEARCH_SEP=' '
AC_MSG_RESULT([it doesn't])
if test ! -f configure; then
- AC_MSG_ERROR(${MAKE-make} requires the build and source directories to be the same)
+ AC_MSG_ERROR([${MAKE-make} requires the build and source directories to be the same])
fi
break
done
@@ -402,33 +418,34 @@ dnl the record.
dnl
AC_MSG_CHECKING(for production mode)
AC_ARG_ENABLE(production,
- [ --enable-production Determines how to run the compiler.])
+ [AC_HELP_STRING([--enable-production],
+ [Determines how to run the compiler.])])
case "X-$enable_production" in
X-yes)
enable_production="yes"
- AC_MSG_RESULT("production")
+ AC_MSG_RESULT([production])
CONFIG_MODE=production
CFLAGS="$CFLAGS $PROD_CFLAGS"
CPPFLAGS="$CPPFLAGS $PROD_CPPFLAGS"
;;
X-|X-no)
enable_production="no"
- AC_MSG_RESULT("development")
+ AC_MSG_RESULT([development])
CONFIG_MODE=development
CFLAGS="$CFLAGS $DEBUG_CFLAGS"
CPPFLAGS="$CPPFLAGS $DEBUG_CPPFLAGS"
;;
X-pg|X-profile)
enable_production="profile"
- AC_MSG_RESULT("profile")
+ AC_MSG_RESULT([profile])
CONFIG_MODE=profile
CFLAGS="$CFLAGS $PROFILE_CFLAGS"
CPPFLAGS="$CPPFLAGS $PROFILE_CPPFLAGS"
;;
*)
enable_production="user-defined"
- AC_MSG_RESULT("user-defined")
+ AC_MSG_RESULT([user-defined])
CONFIG_MODE="$X-enableval"
;;
esac
@@ -436,27 +453,29 @@ esac
dnl ----------------------------------------------------------------------
dnl Check for system libraries.
dnl
-AC_CHECK_LIB(m,ceil)
+AC_CHECK_LIB([m], [ceil])
if test "`uname`" = "SunOS" -o "`uname -sr`" = "HP-UX B.11.00"; then
dnl ...for Solaris
- AC_CHECK_LIB(nsl, xdr_int)
+ AC_CHECK_LIB([nsl], [xdr_int])
fi
-dnl AC_CHECK_LIB(coug,main) dnl ...for ASCI/Red
+dnl AC_CHECK_LIB([coug], [main]) dnl ...for ASCI/Red
dnl ----------------------------------------------------------------------
dnl Check for system header files.
dnl
AC_HEADER_STDC
AC_HEADER_TIME
+
dnl Unix
-AC_CHECK_HEADERS(sys/resource.h sys/time.h unistd.h sys/ioctl.h sys/stat.h)
-AC_CHECK_HEADERS(sys/socket.h sys/types.h)
-AC_CHECK_HEADERS(stddef.h setjmp.h features.h)
-AC_CHECK_HEADERS(stdint.h, C9x=yes)
+AC_CHECK_HEADERS([sys/resource.h sys/time.h unistd.h sys/ioctl.h sys/stat.h])
+AC_CHECK_HEADERS([sys/socket.h sys/types.h])
+AC_CHECK_HEADERS([stddef.h setjmp.h features.h])
+AC_CHECK_HEADERS([stdint.h], [C9x=yes])
+
dnl Windows
-AC_CHECK_HEADERS(io.h winsock.h sys/timeb.h)
+AC_CHECK_HEADERS([io.h winsock.h sys/timeb.h])
case "$host" in
alpha*-dec*-osf*)
@@ -464,43 +483,47 @@ case "$host" in
dnl Alpha to turn off UAC fixing. We do *not* attempt to
dnl locate these files on other systems because there are too
dnl many problems with including them.
- AC_CHECK_HEADERS(sys/sysinfo.h sys/proc.h)
+ AC_CHECK_HEADERS([sys/sysinfo.h sys/proc.h])
;;
esac
+dnl ----------------------------------------------------------------------
+dnl Test for 64bit stuff before the data types and their sizes. The
+dnl result could effect the outcome of the sizeof macros below.
+dnl
case "$host_cpu-$host_vendor-$host_os" in
*linux*)
dnl ----------------------------------------------------------------------
dnl Enable large file support on linux? Store the result in the LINUX_LFS
dnl variable for posterity
- AC_ARG_ENABLE(linux-lfs,
- [ --enable-linux-lfs Enable support for large (64-bit) files on Linux.
- [default=check]])
+ AC_ARG_ENABLE([linux-lfs],
+ [AC_HELP_STRING([--enable-linux-lfs],
+ [Enable support for large (64-bit)
+ files on Linux. [default=check]])])
+ LINUX_LFS="no"
case "X-$enable_linux_lfs" in
X-yes)
LINUX_LFS=yes
;;
X-no)
- LINUX_LFS=no
;;
X-|*)
- LINUX_LFS=no
- AC_CHECK_FUNCS(getdents64,
- dnl Add the large file support flags to the CPPFLAGS macro if
- dnl we're on a Linux system which austensibly supports LFS. (We
- dnl think it does if it has the `getdents64' syscall).
- LINUX_LFS=yes)
+ MAJOR_VER="`uname -r | cut -d '.' -f1`"
+ MINOR_VER="`uname -r | cut -d '.' -f2`"
+
+ if test $MAJOR_VER -ge 2 -a $MINOR_VER -ge 4; then
+ LINUX_LFS="yes"
+ fi
;;
esac
- AC_MSG_CHECKING(for large file support on linux mode)
+ AC_MSG_CHECKING([for large file support mode on Linux])
if test "X$LINUX_LFS" = "Xyes"; then
- AC_MSG_RESULT(enabled)
-
+ AC_MSG_RESULT([enabled])
CPPFLAGS="-D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE $CPPFLAGS"
else
- AC_MSG_RESULT(disabled)
+ AC_MSG_RESULT([disabled])
fi
dnl Add POSIX support on Linux systems, so <features.h> defines
@@ -517,26 +540,26 @@ case "$host_cpu-$host_vendor-$host_os" in
esac
AC_TRY_COMPILE([#include <sys/types.h>],
- [off64_t n = 0;],
- AC_CHECK_FUNCS(lseek64 fseek64),
- AC_MSG_RESULT([skipping test for lseek64() and fseek64()]))
+ [off64_t n = 0;],
+ [AC_CHECK_FUNCS([lseek64 fseek64])],
+ [AC_MSG_RESULT([skipping test for lseek64() and fseek64()])])
dnl ----------------------------------------------------------------------
dnl Data types and their sizes.
dnl
AC_TYPE_OFF_T
-AC_CHECK_TYPE(size_t, unsigned long)
-AC_CHECK_TYPE(ssize_t, long)
+AC_CHECK_TYPE([size_t], [unsigned long])
+AC_CHECK_TYPE([ssize_t], [long])
AC_C_BIGENDIAN
-AC_CHECK_SIZEOF(char, 1)
-AC_CHECK_SIZEOF(short, 2)
-AC_CHECK_SIZEOF(int, 4)
-AC_CHECK_SIZEOF(long, 4)
-AC_CHECK_SIZEOF(long long, 8)
-AC_CHECK_SIZEOF(__int64, 8)
-AC_CHECK_SIZEOF(float, 4)
-AC_CHECK_SIZEOF(double, 8)
-AC_CHECK_SIZEOF(long double, 8)
+AC_CHECK_SIZEOF([char], [1])
+AC_CHECK_SIZEOF([short], [2])
+AC_CHECK_SIZEOF([int], [4])
+AC_CHECK_SIZEOF([long], [4])
+AC_CHECK_SIZEOF([long long], [8])
+AC_CHECK_SIZEOF([__int64], [8])
+AC_CHECK_SIZEOF([float], [4])
+AC_CHECK_SIZEOF([double], [8])
+AC_CHECK_SIZEOF([long double], [8])
dnl Checkpoint the cache
AC_CACHE_SAVE
@@ -552,40 +575,41 @@ if test "X$C9x" = "Xyes"; then
EOF
fi
-AC_CHECK_SIZEOF( int8_t, 1)
-AC_CHECK_SIZEOF( uint8_t, 1)
-AC_CHECK_SIZEOF( int_least8_t, 1)
-AC_CHECK_SIZEOF( uint_least8_t, 1)
-AC_CHECK_SIZEOF( int_fast8_t, 1)
-AC_CHECK_SIZEOF( uint_fast8_t, 1)
-
-AC_CHECK_SIZEOF( int16_t, 2)
-AC_CHECK_SIZEOF( uint16_t, 2)
-AC_CHECK_SIZEOF( int_least16_t, 2)
-AC_CHECK_SIZEOF(uint_least16_t, 2)
-AC_CHECK_SIZEOF( int_fast16_t, 2)
-AC_CHECK_SIZEOF( uint_fast16_t, 2)
-
-AC_CHECK_SIZEOF( int32_t, 4)
-AC_CHECK_SIZEOF( uint32_t, 4)
-AC_CHECK_SIZEOF( int_least32_t, 4)
-AC_CHECK_SIZEOF(uint_least32_t, 4)
-AC_CHECK_SIZEOF( int_fast32_t, 4)
-AC_CHECK_SIZEOF( uint_fast32_t, 4)
-
-AC_CHECK_SIZEOF( int64_t, 8)
-AC_CHECK_SIZEOF( uint64_t, 8)
-AC_CHECK_SIZEOF( int_least64_t, 8)
-AC_CHECK_SIZEOF(uint_least64_t, 8)
-AC_CHECK_SIZEOF( int_fast64_t, 8)
-AC_CHECK_SIZEOF( uint_fast64_t, 8)
-
-AC_CHECK_SIZEOF(size_t, 4)
-AC_CHECK_SIZEOF(ssize_t, 4)
+AC_CHECK_SIZEOF( int8_t, [1])
+AC_CHECK_SIZEOF( uint8_t, [1])
+AC_CHECK_SIZEOF( int_least8_t, [1])
+AC_CHECK_SIZEOF( uint_least8_t, [1])
+AC_CHECK_SIZEOF( int_fast8_t, [1])
+AC_CHECK_SIZEOF( uint_fast8_t, [1])
+
+AC_CHECK_SIZEOF( int16_t, [2])
+AC_CHECK_SIZEOF( uint16_t, [2])
+AC_CHECK_SIZEOF( int_least16_t, [2])
+AC_CHECK_SIZEOF(uint_least16_t, [2])
+AC_CHECK_SIZEOF( int_fast16_t, [2])
+AC_CHECK_SIZEOF( uint_fast16_t, [2])
+
+AC_CHECK_SIZEOF( int32_t, [4])
+AC_CHECK_SIZEOF( uint32_t, [4])
+AC_CHECK_SIZEOF( int_least32_t, [4])
+AC_CHECK_SIZEOF(uint_least32_t, [4])
+AC_CHECK_SIZEOF( int_fast32_t, [4])
+AC_CHECK_SIZEOF( uint_fast32_t, [4])
+
+AC_CHECK_SIZEOF( int64_t, [8])
+AC_CHECK_SIZEOF( uint64_t, [8])
+AC_CHECK_SIZEOF( int_least64_t, [8])
+AC_CHECK_SIZEOF(uint_least64_t, [8])
+AC_CHECK_SIZEOF( int_fast64_t, [8])
+AC_CHECK_SIZEOF( uint_fast64_t, [8])
+
+AC_CHECK_SIZEOF([size_t], [4])
+AC_CHECK_SIZEOF([ssize_t], [4])
+
cat >>confdefs.h <<\EOF
#include <sys/types.h> /*for off_t definition*/
EOF
-AC_CHECK_SIZEOF(off_t, 4)
+AC_CHECK_SIZEOF([off_t], [4])
dnl Checkpoint the cache
AC_CACHE_SAVE
@@ -600,7 +624,7 @@ AC_TRY_COMPILE([
#endif
],
[dev_t d1, d2; if(d1==d2) return 0;],
- AC_DEFINE(DEV_T_IS_SCALAR, 1,
+ AC_DEFINE([DEV_T_IS_SCALAR], [1],
[Define if \`dev_t' is a scalar])
AC_MSG_RESULT(yes),
AC_MSG_RESULT(no)
@@ -611,7 +635,7 @@ dnl Fake --with-xxx option to allow us to create a help message for the
dnl following --with-xxx options which can take either a =DIR or =INC,LIB
dnl specifier.
dnl
-AC_ARG_WITH(fnord,
+AC_ARG_WITH([fnord],
[
For the following --with-xxx options, you can specify where the header
files and libraries are in two different ways:
@@ -620,7 +644,7 @@ AC_ARG_WITH(fnord,
library directory separated by a comma
--with-xxx=DIR - Specify only the directory which contains the
include/ and lib/ subdirectories
- ],,)
+ ])
dnl ----------------------------------------------------------------------
dnl Is the dmalloc present? It has a header file `dmalloc.h' and a library
@@ -628,9 +652,10 @@ dnl `-ldmalloc' and their locations might be specified with the `--with-dmalloc'
dnl command-line switch. The value is an include path and/or a library path.
dnl If the library path is specified then it must be preceded by a comma.
dnl
-AC_ARG_WITH(dmalloc,
- [ --with-dmalloc[=DIR] Use dmalloc memory debugging aid (default=no)],,
- withval=no)
+AC_ARG_WITH([dmalloc],
+ [AC_HELP_STRING([--with-dmalloc=DIR],
+ [Use dmalloc memory debugging aid [default=no]])],,
+ withval=no)
case $withval in
yes)
@@ -689,24 +714,26 @@ dnl `-lz' and their locations might be specified with the `--with-zlib'
dnl command-line switch. The value is an include path and/or a library path.
dnl If the library path is specified then it must be preceded by a comma.
dnl
-AC_ARG_WITH(zlib,
- [ --with-zlib[=DIR] Use GNU zlib compression [default=yes]],,
- withval=yes)
+AC_ARG_WITH([zlib],
+ [AC_HELP_STRING([--with-zlib=DIR],
+ [Use GNU zlib compression [default=yes]])],,
+ withval=yes)
case $withval in
yes)
HAVE_ZLIB="yes"
- AC_CHECK_HEADERS(zlib.h)
- AC_CHECK_LIB(z, compress2,, unset HAVE_ZLIB)
+ AC_CHECK_HEADERS([zlib.h], [HAVE_ZLIB_H="yes"])
+ AC_CHECK_LIB([z], [compress2],, [unset HAVE_ZLIB])
+ AC_CHECK_FUNC([compress2], [HAVE_COMPRESS2="yes"])
if test -z "$HAVE_ZLIB" -a -n "$HDF5_CONFIG_ABORT"; then
- AC_MSG_ERROR(couldn't find zlib library)
+ AC_MSG_ERROR([couldn't find zlib library])
fi
;;
no)
HAVE_ZLIB="no"
- AC_MSG_CHECKING(for GNU zlib)
- AC_MSG_RESULT(suppressed)
+ AC_MSG_CHECKING([for GNU zlib])
+ AC_MSG_RESULT([suppressed])
;;
*)
HAVE_ZLIB="yes"
@@ -730,30 +757,40 @@ case $withval in
CPPFLAGS="$CPPFLAGS -I$zlib_inc"
fi
- AC_CHECK_HEADERS(zlib.h,, CPPFLAGS="$saved_CPPFLAGS")
+ AC_CHECK_HEADERS([zlib.h],
+ [HAVE_ZLIB_H="yes"],
+ [CPPFLAGS="$saved_CPPFLAGS"])
if test -n "$zlib_lib"; then
LDFLAGS="$LDFLAGS -L$zlib_lib"
fi
- AC_CHECK_LIB(z, compress2,, LDFLAGS="$saved_LDFLAGS"; unset HAVE_ZLIB)
+ AC_CHECK_LIB([z], [compress2],,
+ [LDFLAGS="$saved_LDFLAGS"; unset HAVE_ZLIB])
+ AC_CHECK_FUNC([compress2], [HAVE_COMPRESS2="yes"])
if test -z "$HAVE_ZLIB" -a -n "$HDF5_CONFIG_ABORT"; then
- AC_MSG_ERROR(couldn't find zlib library)
+ AC_MSG_ERROR([couldn't find zlib library])
fi
;;
esac
+if test "x$HAVE_ZLIB" = "xyes" -a "x$HAVE_ZLIB_H" = "xyes" -a "x$HAVE_COMPRESS2" = "xyes"; then
+ AC_DEFINE(HAVE_COMPRESSION, 1,
+ [Define if we have zlib compression support])
+fi
+
dnl ----------------------------------------------------------------------
dnl Pablo Configuration
dnl
AC_SUBST(PABLO) PABLO=""
AC_SUBST(HAVE_PABLO) HAVE_PABLO="no"
-AC_ARG_WITH(pablo,
- [ --with-pablo[=DIR] Use the Pablo library [default=no]],,
- withval=no)
+AC_ARG_WITH([pablo],
+ [AC_HELP_STRING([--with-pablo=DIR],
+ [Use the Pablo library [default=no]])],,
+ withval=no)
-AC_MSG_CHECKING(for Pablo)
+AC_MSG_CHECKING([for Pablo])
case "$withval" in
yes)
@@ -821,9 +858,10 @@ esac
dnl Is SSL library present? It is needed by GLOBUS-GASS and Grid Storage
dnl driver. SSL must be tested before them.
AC_SUBST(SSL) SSL=yes
-AC_ARG_WITH(ssl,
- [ --with-ssl[=LIB] Use the SSL library [default=no]],,
- withval=no)
+AC_ARG_WITH([ssl],
+ [AC_HELP_STRING([--with-ssl=LIB],
+ [Use the SSL library [default=no]])],,
+ withval=no)
case "$withval" in
yes)
@@ -849,9 +887,10 @@ dnl the Grid Storage driver.
dnl
AC_SUBST(GASS) GASS="yes"
AC_SUBST(TESTGASS) TESTGASS='$(srcdir)/testgass'
-AC_ARG_WITH(gass,
- [ --with-gass[=DIR] Use the GASS library [default=no]],,
- withval=no)
+AC_ARG_WITH([gass],
+ [AC_HELP_STRING([--with-gass=DIR],
+ [Use the GASS library [default=no]])],,
+ withval=no)
case "$withval" in
yes)
@@ -924,7 +963,7 @@ case "$withval" in
esac
if test -n "$GASS"; then
- AC_DEFINE(HAVE_GASS, 1,
+ AC_DEFINE([HAVE_GASS], [1],
[Define if the Globus GASS is defined])
fi
@@ -933,9 +972,10 @@ dnl Are SRB Client and other system libraries(socket, elf) present?
dnl
AC_SUBST(SRB) SRB="yes"
AC_SUBST(TESTSRB) TESTSRB='$(srcdir)/testsrb'
-AC_ARG_WITH(srb,
- [ --with-srb[=DIR] Use the SRB library [default=no]],,
- withval=no)
+AC_ARG_WITH([srb],
+ [AC_HELP_STRING([--with-srb=DIR],
+ [Use the SRB library [default=no]])],,
+ withval=no)
case "$withval" in
yes)
@@ -1013,9 +1053,10 @@ dnl be preceded by a comma.
dnl
AC_SUBST(PTHREAD) PTHREAD=yes
-AC_ARG_WITH(pthread,
- [ --with-pthread[=DIR] Use the Pthreads library [default=no]],,
- withval=no)
+AC_ARG_WITH([pthread],
+ [AC_HELP_STRING([--with-pthread=DIR],
+ [Use the Pthreads library [default=no]])],,
+ withval=no)
case "$withval" in
yes)
@@ -1064,9 +1105,10 @@ dnl ----------------------------------------------------------------------
dnl Enable thread-safe version of library. It requires Pthreads support.
dnl
AC_MSG_CHECKING(for thread safe support)
-AC_ARG_ENABLE(threadsafe,
- [ --enable-threadsafe Enable thread safe capability],
- THREADSAFE=$enableval)
+AC_ARG_ENABLE([threadsafe],
+ [AC_HELP_STRING([--enable-threadsafe],
+ [Enable thread safe capability])],
+ THREADSAFE=$enableval)
case "X-$THREADSAFE" in
X-|X-no)
@@ -1075,8 +1117,8 @@ case "X-$THREADSAFE" in
X-yes)
dnl Check that we can link a simple Pthread program.
AC_TRY_LINK(,pthread_create(),
- AC_MSG_RESULT(yes); THREADSAFE=yes,
- AC_MSG_ERROR(needed pthread library not available))
+ AC_MSG_RESULT(yes); THREADSAFE=yes,
+ AC_MSG_ERROR(needed pthread library not available))
;;
*)
AC_MSG_RESULT(error)
@@ -1085,7 +1127,7 @@ case "X-$THREADSAFE" in
esac
if test "X$THREADSAFE" = "Xyes"; then
- AC_DEFINE(HAVE_THREADSAFE, 1,
+ AC_DEFINE([HAVE_THREADSAFE], [1],
[Define if we have thread safe support])
fi
@@ -1093,32 +1135,35 @@ dnl ----------------------------------------------------------------------
dnl Check if they would like the HDF5 v1.4 compatibility functions
dnl compiled in
dnl
-AC_MSG_CHECKING(whether HDF5 v1.4 compatibility functions enabled)
-AC_ARG_ENABLE(hdf5v1_4,
- [ --enable-hdf5v1_4 Compile the HDF5 v1.4 compatibility interface
- [default=no]],
- HDF5_V1_4_COMPAT=$enableval)
+AC_MSG_CHECKING([whether HDF5 v1.4 compatibility functions enabled])
+AC_ARG_ENABLE([hdf5v1_4],
+ [AC_HELP_STRING([--enable-hdf5v1_4],
+ [Compile the HDF5 v1.4 compatibility
+ interface [default=no]])],
+ [HDF5_V1_4_COMPAT=$enableval])
if test "$HDF5_V1_4_COMPAT" = "yes"; then
- AC_MSG_RESULT(yes)
- AC_DEFINE(WANT_H5_V1_4_COMPAT, 1,
+ AC_MSG_RESULT([yes])
+ AC_DEFINE([WANT_H5_V1_4_COMPAT], [1],
[Define if the HDF5 v1.4 compatibility functions are to be compiled in])
else
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT([no])
fi
dnl ----------------------------------------------------------------------
dnl Should the Stream Virtual File Driver be compiled in ?
dnl
-AC_MSG_CHECKING(for Stream Virtual File Driver support)
-AC_ARG_ENABLE(stream-vfd,
- [ --enable-stream-vfd Build the Stream Virtual File Driver [default=no]],
- STREAM_VFD=$enableval)
+AC_MSG_CHECKING([for Stream Virtual File Driver support])
+AC_ARG_ENABLE([stream-vfd],
+ [AC_HELP_STRING([--enable-stream-vfd],
+ [Build the Stream Virtual File Driver
+ [default=no]])],
+ [STREAM_VFD=$enableval])
if test "$STREAM_VFD" = "yes"; then
- AC_MSG_RESULT(yes)
- AC_CHECK_HEADERS(netinet/tcp.h sys/filio.h)
- AC_DEFINE(HAVE_STREAM, 1,
+ AC_MSG_RESULT([yes])
+ AC_CHECK_HEADERS([netinet/tcp.h sys/filio.h])
+ AC_DEFINE([HAVE_STREAM], [1],
[Define if the stream virtual file driver should be compiled])
dnl Check if 'socklen_t' available
@@ -1137,13 +1182,13 @@ if test "$STREAM_VFD" = "yes"; then
#endif
],
[socklen_t foo; return 0;],
- AC_DEFINE(HAVE_SOCKLEN_T, 1,
+ AC_DEFINE([HAVE_SOCKLEN_T], 1,
[Define if \`socklen_t' is defined])
- AC_MSG_RESULT(yes),
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT([yes]),
+ AC_MSG_RESULT([no])
)
else
- AC_MSG_RESULT(not configured)
+ AC_MSG_RESULT([not configured])
fi
dnl ----------------------------------------------------------------------
@@ -1242,7 +1287,7 @@ AC_MSG_RESULT(no))
dnl ----------------------------------------------------------------------
dnl Check for functions.
dnl
-AC_CHECK_FUNCS(compress2 difftime fork gethostname getpwuid getrusage)
+AC_CHECK_FUNCS(difftime fork gethostname getpwuid getrusage)
AC_CHECK_FUNCS(gettimeofday BSDgettimeofday longjmp setsysinfo sigaction)
AC_CHECK_FUNCS(signal snprintf vsnprintf strdup system waitpid)
@@ -1252,14 +1297,14 @@ dnl
AC_C_CONST
AC_C_INLINE
-AC_MSG_CHECKING(for __attribute__ extension)
+AC_MSG_CHECKING([for __attribute__ extension])
AC_TRY_COMPILE(,[int __attribute__((unused)) x],
AC_DEFINE(HAVE_ATTRIBUTE, 1,
[Define if the __attribute__(()) extension is present])
AC_MSG_RESULT(yes),
AC_MSG_RESULT(no))
-AC_MSG_CHECKING(for __FUNCTION__ extension)
+AC_MSG_CHECKING([for __FUNCTION__ extension])
AC_TRY_COMPILE(,[(void)__FUNCTION__],
AC_DEFINE(HAVE_FUNCTION, 1,
[Define if the compiler understand the __FUNCTION__ keyword])
@@ -1275,7 +1320,7 @@ dnl the dynamic library. The correct way to do it should be updating
dnl LD_LIBRARY_PATH along with LDFLAGS or do it with the AC_TRY_RUN macro.
dnl
AC_MSG_CHECKING(how to print long long)
-AC_CACHE_VAL(hdf5_cv_printf_ll,
+AC_CACHE_VAL([hdf5_cv_printf_ll],
LD_LIBRARY_PATH="$LD_LIBRARY_PATH`echo $LDFLAGS | sed -e 's/-L/:/g' -e 's/ //g'`"
export LD_LIBRARY_PATH
@@ -1293,7 +1338,7 @@ int main(void)
exit(strcmp(s,"1099511627776"));
}
], break,,continue)
-done)
+done)dnl
AC_MSG_RESULT(%${hdf5_cv_printf_ll}d and %${hdf5_cv_printf_ll}u)
AC_DEFINE_UNQUOTED(PRINTF_LL_WIDTH, "$hdf5_cv_printf_ll",
@@ -1302,7 +1347,7 @@ AC_DEFINE_UNQUOTED(PRINTF_LL_WIDTH, "$hdf5_cv_printf_ll",
dnl ----------------------------------------------------------------------
dnl Check if malloc(0) returns valid pointer
dnl
-AC_MSG_CHECKING(if malloc of zero bytes returns valid pointer)
+AC_MSG_CHECKING([if malloc of zero bytes returns valid pointer])
AC_CACHE_VAL(hdf5_cv_malloc_works,
AC_TRY_RUN([
#if STDC_HEADERS
@@ -1322,19 +1367,36 @@ if test ${hdf5_cv_malloc_works} = "yes"; then
else
AC_MSG_RESULT(no)
fi
-
+
+dnl ----------------------------------------------------------------------
+dnl Checking to see if GPFS is available on this filesystem
+dnl
+AC_CHECK_HEADERS([gpfs.h],
+ AC_MSG_CHECKING([for GPFS support])
+ AC_TRY_COMPILE([#include <gpfs.h>],
+ [int fd = 0; gpfs_fcntl(fd, (void *)0);],
+ AC_DEFINE(HAVE_GPFS, 1,
+ [Define if we have GPFS support])
+ AC_MSG_RESULT(yes)
+ LIBS="$LIBS -lgpfs"
+ GPFS="yes",
+ AC_MSG_RESULT(no)
+ GPFS="no"))
+
dnl ----------------------------------------------------------------------
dnl Turn on debugging by setting compiler flags
dnl
AC_MSG_CHECKING(for debug flags)
-AC_ARG_ENABLE(debug,
- [ --enable-debug[=all] Turn on debugging in all packages. One may also
- specify a comma-separated list of package names
- without the leading H5 or the word no. The default
- is most packages.],
- DEBUG_PKG=$enableval)
-
-AC_SUBST(DEBUG_PKG)
+AC_ARG_ENABLE([debug],
+ [AC_HELP_STRING([--enable-debug=all],
+ [Turn on debugging in all packages. One may
+ also specify a comma-separated list of
+ package names without the leading H5 or
+ the word no. The default is most
+ packages.])],
+ [DEBUG_PKG=$enableval])
+
+AC_SUBST([DEBUG_PKG])
all_packages="ac,b,d,e,f,g,hg,hl,i,mf,mm,o,p,s,t,v,z"
case "X-$DEBUG_PKG" in
X-|X-yes)
@@ -1366,18 +1428,20 @@ fi
dnl ----------------------------------------------------------------------
dnl Enable tracing of the API
dnl
-AC_MSG_CHECKING(for API tracing);
-AC_ARG_ENABLE(trace,
- [ --disable-trace Disable API tracing capability],
- TRACE=$enableval)
+AC_MSG_CHECKING([for API tracing])
+AC_ARG_ENABLE([trace],
+ [AC_HELP_STRING([--disable-trace],
+ [Disable API tracing capability])],
+ [TRACE=$enableval])
+
+AC_SUBST([TRACE_API])
-AC_SUBST(TRACE_API)
if test -z "$TRACE" -o "X$TRACE" = "Xyes"; then
- AC_MSG_RESULT(yes)
+ AC_MSG_RESULT([yes])
TRACE_API=yes
CPPFLAGS="$CPPFLAGS -DH5_DEBUG_API"
else
- AC_MSG_RESULT(no)
+ AC_MSG_RESULT([no])
TRACE_API=no
CPPFLAGS="$CPPFLAGS -UH5_DEBUG_API"
fi
@@ -1439,7 +1503,7 @@ case "$CC_BASENAME" in
dnl The mpich compiler. Use mpirun from the same directory if it
dnl exists.
PARALLEL=mpicc
- AC_MSG_CHECKING(for mpirun)
+ AC_MSG_CHECKING([for mpirun])
dnl Find the path where mpicc is located.
cmd="`echo $CC | cut -f1 -d' '`"
@@ -1455,14 +1519,14 @@ case "$CC_BASENAME" in
dnl Is there an mpirun at that path?
if test -x $path/mpirun; then
- AC_MSG_RESULT($path/mpirun)
+ AC_MSG_RESULT([$path/mpirun])
RUNSERIAL="${RUNSERIAL:-none}"
if test -z "$RUNPARALLEL"; then
RUNPARALLEL="$path/mpirun -np \$\${NPROCS:=3}"
fi
else
- AC_MSG_RESULT(none)
+ AC_MSG_RESULT([none])
fi
;;
@@ -1470,7 +1534,7 @@ case "$CC_BASENAME" in
dnl The LAM compiler. Use mpirun_lam or mpirun from the same directory
dnl if it exists.
PARALLEL=hcc
- AC_MSG_CHECKING(for mpirun_lam or mpirun)
+ AC_MSG_CHECKING([for mpirun_lam or mpirun])
dnl Find the path where hcc is located
cmd="`echo $CC | cut -f1 -d' '`"
@@ -1491,13 +1555,13 @@ case "$CC_BASENAME" in
else
cmd=mpirun
fi
- AC_MSG_RESULT($path/$cmd);
+ AC_MSG_RESULT([$path/$cmd])
RUNSERIAL="${RUNSERIAL:-none}"
if test -z "$RUNPARALLEL"; then
RUNPARALLEL="$path/$cmd -np \$\${NPROCS:=3}"
fi
else
- AC_MSG_RESULT(none)
+ AC_MSG_RESULT([none])
fi
;;
@@ -1520,10 +1584,11 @@ dnl `--disable-parallel' but specifies a known parallel compiler (like mpicc
dnl or mpcc) then parallel support is enabled but configure doesn't search
dnl for any parallel header files or libraries.
dnl
-AC_ARG_ENABLE(parallel,
- [ --enable-parallel=TYPE Search for MPI-IO and MPI support files])
+AC_ARG_ENABLE([parallel],
+ [AC_HELP_STRING([--enable-parallel=TYPE],
+ [Search for MPI-IO and MPI support files])])
-AC_MSG_CHECKING(for parallel support files)
+AC_MSG_CHECKING([for parallel support files])
case "X-$enable_parallel" in
X-|X-no|X-none)
dnl Either we are not compiling for parallel or the header and
@@ -1929,8 +1994,8 @@ IF_YES_NO() {
else
while test $# -gt 0; do
if test "$1" != "yes"; then
- PRINT "No"
- return
+ PRINT "No"
+ return
fi
shift
done
@@ -1983,7 +2048,7 @@ else
PRINT "No"
fi
-PRINT "Features:"
+PRINT "Languages:"
PRINT_N " C++"
IF_YES_NO "$HDF_CXX"
@@ -1991,9 +2056,17 @@ IF_YES_NO "$HDF_CXX"
PRINT_N " Fortran"
IF_YES_NO "$HDF_FORTRAN"
+PRINT "Features:"
+
+PRINT_N " dmalloc"
+IF_YES_NO "$HAVE_DMALLOC"
+
PRINT_N " GASS"
IF_YES_NO "$GASS"
+PRINT_N " GPFS"
+IF_YES_NO "$GPFS"
+
PRINT_N " HDF5 v1.4 Compatibility"
IF_YES_NO "$HDF5_V1_4_COMPAT"
@@ -2027,6 +2100,3 @@ IF_ENABLED_DISABLED "$THREADSAFE"
PRINT_N " Zlib-compression"
IF_YES_NO "$HAVE_ZLIB"
-
-PRINT_N " dmalloc"
-IF_YES_NO "$HAVE_DMALLOC"
diff --git a/perform/pio_engine.c b/perform/pio_engine.c
index 60c4590..87dab86 100644
--- a/perform/pio_engine.c
+++ b/perform/pio_engine.c
@@ -131,13 +131,15 @@ static void do_cleanupfile(iotype iot, char *fname);
/* GPFS-specific functions */
#ifdef H5_HAVE_GPFS
-static void access_range(int handle, off_t start, off_t length, int is_write);
-static void free_range(int handle, off_t start, off_t length);
-static void clear_file_cache(int handle);
-static void cancel_hints(int handle);
-static void start_data_shipping(int handle, int num_insts);
-static void stop_data_shipping(int handle);
-static void invalidate_file_cache(const char *filename);
+static void gpfs_access_range(int handle, off_t start, off_t length, int is_write);
+static void gpfs_free_range(int handle, off_t start, off_t length);
+static void gpfs_clear_file_cache(int handle);
+static void gpfs_cancel_hints(int handle);
+static void gpfs_start_data_shipping(int handle, int num_insts);
+static void gpfs_start_data_ship_map(int handle, int partition_size,
+ int agent_count, int *agent_node_num);
+static void gpfs_stop_data_shipping(int handle);
+static void gpfs_invalidate_file_cache(const char *filename);
#endif /* H5_HAVE_GPFS */
/*
@@ -1659,7 +1661,7 @@ do_cleanupfile(iotype iot, char *fname)
/* Descriptions here come from the IBM GPFS Manual */
/*
- * Function: access_range
+ * Function: gpfs_access_range
* Purpose: Declares an access range within a file for an
* application.
*
@@ -1678,16 +1680,17 @@ do_cleanupfile(iotype iot, char *fname)
* Subsequent GPFS_ACCESS_RANGE hints will replace a hint
* passed earlier.
*
- * START - The start of the access range offset, in
- * bytes, from the beginning of the file.
- * LENGTH - Length of the access range. 0 indicates to
- * the end of the file.
+ * START - The start of the access range offset, in
+ * bytes, from the beginning of the file
+ * LENGTH - Length of the access range. 0 indicates to
+ * the end of the file
+ * IS_WRITE - 0 indicates READ access, 1 indicates WRITE access
* Return: Nothing
* Programmer: Bill Wendling, 03. June 2002
* Modifications:
*/
static void
-access_range(int handle, off_t start, off_t length, int is_write)
+gpfs_access_range(int handle, off_t start, off_t length, int is_write)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1712,7 +1715,7 @@ access_range(int handle, off_t start, off_t length, int is_write)
}
/*
- * Function: free_range
+ * Function: gpfs_free_range
* Purpose: Undeclares an access range within a file for an
* application.
*
@@ -1736,7 +1739,7 @@ access_range(int handle, off_t start, off_t length, int is_write)
* Modifications:
*/
static void
-free_range(int handle, off_t start, off_t length)
+gpfs_free_range(int handle, off_t start, off_t length)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1761,7 +1764,7 @@ free_range(int handle, off_t start, off_t length)
}
/*
- * Function: clear_file_cache
+ * Function: gpfs_clear_file_cache
* Purpose: Indicates file access in the near future is not expected.
*
* The application does not expect to make any further
@@ -1780,7 +1783,7 @@ free_range(int handle, off_t start, off_t length)
* Modifications:
*/
static void
-clear_file_cache(int handle)
+gpfs_clear_file_cache(int handle)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1802,7 +1805,7 @@ clear_file_cache(int handle)
}
/*
- * Function: cancel_hints
+ * Function: gpfs_cancel_hints
* Purpose: Indicates to remove any hints against the open file
* handle.
*
@@ -1826,7 +1829,7 @@ clear_file_cache(int handle)
* Modifications:
*/
static void
-cancel_hints(int handle)
+gpfs_cancel_hints(int handle)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1848,17 +1851,31 @@ cancel_hints(int handle)
}
/*
- * Function: start_data_shipping
- * Purpose: Start up data shipping. The second parameter is the total
- * number of open instances on all nodes that will be
- * operating on the file. Must be called for every such
- * instance with the same value of NUM_INSTS.
+ * Function: gpfs_start_data_shipping
+ * Purpose: Initiates data shipping mode.
+ *
+ * Once all participating threads have issued this directive
+ * for a file, GPFS enters a mode where it logically
+ * partitions the blocks of the file among a group of agent
+ * nodes. The agents are those nodes on which one or more
+ * threads have issued the GPFS_DATA_SHIP_START directive.
+ * Each thread that has issued a GPFS_DATA_SHIP_START
+ * directive and the associated agent nodes are referred to
+ * as the data shipping collective.
+ *
+ * The second parameter is the total number of open
+ * instances on all nodes that will be operating on the
+ * file. Must be called for every such instance with the
+ * same value of NUM_INSTS.
+ *
+ * NUM_INSTS - The number of open file instances, on all
+ * nodes, collaborating to operate on the file
* Return: Nothing
* Programmer: Bill Wendling, 28. May 2002
* Modifications:
*/
static void
-start_data_shipping(int handle, int num_insts)
+gpfs_start_data_shipping(int handle, int num_insts)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1882,15 +1899,79 @@ start_data_shipping(int handle, int num_insts)
}
/*
- * Function: stop_data_shipping
- * Purpose: Shut down data shipping. Must be called for every handle
- * for which start_data_shipping was called.
+ * Function: gpfs_start_data_ship_map
+ * Purpose: Indicates which agent nodes are to be used for data
+ * shipping. GPFS recognizes which agent nodes to use for
+ * data shipping.
+ *
+ * PARTITION_SIZE - The number of contiguous bytes per
+ * server. This value must be a
+ * multiple of the number of bytes in a
+ * single file system block
+ * AGENT_COUNT - The number of entries in the
+ * agentNodeNumber array
+ * AGENT_NODE_NUM - The data ship agent node numbers as
+ * listed in the SDT or the global ODM
+ *
+ * Return: Nothing
+ * Programmer: Bill Wendling, 10. Jul 2002
+ * Modifications:
+ */
+static void
+gpfs_start_data_ship_map(int handle, int partition_size, int agent_count,
+ int *agent_node_num)
+{
+ int i;
+ struct {
+ gpfsFcntlHeader_t hdr;
+ gpfsDataShipMap_t map;
+ } ds_map;
+
+ ds_map.hdr.totalLength = sizeof(ds_map);
+ ds_map.hdr.fcntlVersion = GPFS_FCNTL_CURRENT_VERSION;
+ ds_map.hdr.fcntlReserved = 0;
+ ds_map.map.structLen = sizeof(gpfsDataShipMap_t);
+ ds_map.map.structType = GPFS_DATA_SHIP_MAP;
+ ds_map.map.partitionSize = partition_size;
+ ds_map.map.agentCount = agent_count;
+
+ for (i = 0; i < agent_count; ++i)
+ ds_map.map.agentNodeNumber[i] = agent_node_num[i];
+
+ if (gpfs_fcntl(handle, &ds_map) != 0) {
+ fprintf(stderr,
+ "gpfs_fcntl DS map directive failed. errno=%d errorOffset=%d\n",
+ errno, ds_map.hdr.errorOffset);
+ exit(EXIT_FAILURE);
+ }
+}
+
+/*
+ * Function: gpfs_stop_data_shipping
+ * Purpose: Takes a file out of the data shipping mode.
+ *
+ * - GPFS waits for all threads that issued the
+ * GPFS_DATA_SHIP_START directive to issue this directive,
+ * then flushes the dirty file data to disk.
+ *
+ * - While a gpfs_cntl() call is blocked for other threads,
+ * the call can be interrupted by any signal. If a signal
+ * is delivered to any of the waiting calls, all waiting
+ * calls on every node will be interrupted and will return
+ * EINTR. GPFS will not cancel data shipping mode if such
+ * a signal occurs. It is the responsibility of the
+ * application to mask off any signals that might normally
+ * occur while waiting for another node in the data
+ * shipping collective. Several libraries use SIGALRM; the
+ * thread that makes the gpfs_fcntl() call should use
+ * sigthreadmask to mask off delivery of this signal while
+ * inside the call.
* Return: Nothing
* Programmer: Bill Wendling, 28. May 2002
* Modifications:
*/
static void
-stop_data_shipping(int handle)
+gpfs_stop_data_shipping(int handle)
{
struct {
gpfsFcntlHeader_t hdr;
@@ -1910,7 +1991,7 @@ stop_data_shipping(int handle)
}
/*
- * Function: invalidate_file_cache
+ * Function: gpfs_invalidate_file_cache
* Purpose: Invalidate all cached data held on behalf of a file on
* this node.
* Return: Nothing
@@ -1918,7 +1999,7 @@ stop_data_shipping(int handle)
* Modifications:
*/
static void
-invalidate_file_cache(const char *filename)
+gpfs_invalidate_file_cache(const char *filename)
{
int handle;
struct {
@@ -1951,7 +2032,7 @@ invalidate_file_cache(const char *filename)
/* Close the file */
if (close(handle) == -1) {
fprintf(stderr,
- "could not close file '%s' after flushing file cache,",
+ "could not close file '%s' after flushing file cache, ",
filename);
fprintf(stderr, "errno=%d\n", errno);
exit(1);
@@ -1965,43 +2046,51 @@ invalidate_file_cache(const char *filename)
/* H5_HAVE_GPFS isn't defined...stub functions */
static void
-access_range(int UNUSED handle, off_t UNUSED start, off_t UNUSED length, int UNUSED is_write)
+gpfs_access_range(int UNUSED handle, off_t UNUSED start, off_t UNUSED length,
+ int UNUSED is_write)
+{
+ return;
+}
+
+static void
+gpfs_free_range(int UNUSED handle, off_t UNUSED start, off_t UNUSED length)
{
return;
}
static void
-free_range(int UNUSED handle, off_t UNUSED start, off_t UNUSED length)
+gpfs_clear_file_cache(int UNUSED handle)
{
return;
}
static void
-clear_file_cache(int UNUSED handle)
+gpfs_cancel_hints(int UNUSED handle)
{
return;
}
static void
-cancel_hints(int UNUSED handle)
+gpfs_start_data_shipping(int UNUSED handle, int UNUSED num_insts)
{
return;
}
static void
-start_data_shipping(int UNUSED handle, int UNUSED num_insts)
+gpfs_stop_data_shipping(int UNUSED handle)
{
return;
}
static void
-stop_data_shipping(int UNUSED handle)
+gpfs_start_data_ship_map(int UNUSED handle, int UNUSED partition_size,
+ int UNUSED agent_count, int UNUSED *agent_node_num)
{
return;
}
static void
-invalidate_file_cache(const char UNUSED *filename)
+gpfs_invalidate_file_cache(const char UNUSED *filename)
{
return;
}
diff --git a/perform/zip_perf.c b/perform/zip_perf.c
index 301a831..926b3cf 100644
--- a/perform/zip_perf.c
+++ b/perform/zip_perf.c
@@ -38,7 +38,7 @@
#include "hdf5.h"
#include "h5tools_utils.h"
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
#include <zlib.h>
@@ -673,4 +673,4 @@ main(void)
return EXIT_SUCCESS;
}
-#endif /* !(H5_HAVE_COMPRESS2 && H5_HAVE_ZLIB_H && H5_HAVE_LIBZ) */
+#endif /* !H5_HAVE_COMPRESSION */
diff --git a/src/H5Zdeflate.c b/src/H5Zdeflate.c
index 43ffbd5..1910115 100644
--- a/src/H5Zdeflate.c
+++ b/src/H5Zdeflate.c
@@ -14,7 +14,7 @@
# include "zlib.h"
#else
/* Make sure compression is disabled too. */
-#undef H5_HAVE_COMPRESS2
+#undef H5_HAVE_COMPRESSION
#endif
/* Interface initialization */
@@ -40,7 +40,7 @@ static int interface_initialize_g = 0;
*-------------------------------------------------------------------------
*/
size_t
-#if defined(H5_HAVE_COMPRESS2)
+#if defined(H5_HAVE_COMPRESSION)
H5Z_filter_deflate (unsigned flags, size_t cd_nelmts,
const unsigned cd_values[], size_t nbytes,
size_t *buf_size, void **buf)
@@ -52,7 +52,7 @@ H5Z_filter_deflate (unsigned UNUSED flags, size_t cd_nelmts,
{
size_t ret_value = 0;
void *outbuf = NULL;
-#if defined(H5_HAVE_COMPRESS2)
+#if defined(H5_HAVE_COMPRESSION)
int aggression = 6;
int status;
#endif
@@ -65,7 +65,7 @@ H5Z_filter_deflate (unsigned UNUSED flags, size_t cd_nelmts,
"invalid deflate aggression level");
}
-#if defined(H5_HAVE_COMPRESS2)
+#if defined(H5_HAVE_COMPRESSION)
aggression = cd_values[0];
if (flags & H5Z_FLAG_REVERSE) {
/* Input; uncompress */
diff --git a/src/H5config.h.in b/src/H5config.h.in
index 49c220d..324d51c 100644
--- a/src/H5config.h.in
+++ b/src/H5config.h.in
@@ -9,8 +9,8 @@
/* Define to 1 if you have the `BSDgettimeofday' function. */
#undef HAVE_BSDGETTIMEOFDAY
-/* Define to 1 if you have the `compress2' function. */
-#undef HAVE_COMPRESS2
+/* Define if we have zlib compression support */
+#undef HAVE_COMPRESSION
/* Define to 1 if you have the `difftime' function. */
#undef HAVE_DIFFTIME
@@ -39,9 +39,6 @@
/* Define to 1 if you have the `GetConsoleScreenBufferInfo' function. */
#undef HAVE_GETCONSOLESCREENBUFFERINFO
-/* Define to 1 if you have the `getdents64' function. */
-#undef HAVE_GETDENTS64
-
/* Define to 1 if you have the `gethostname' function. */
#undef HAVE_GETHOSTNAME
@@ -60,6 +57,12 @@
/* Define to 1 if you have the <globus_common.h> header file. */
#undef HAVE_GLOBUS_COMMON_H
+/* Define if we have GPFS support */
+#undef HAVE_GPFS
+
+/* Define to 1 if you have the <gpfs.h> header file. */
+#undef HAVE_GPFS_H
+
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
diff --git a/test/dsets.c b/test/dsets.c
index 1343f22..890aa2f 100644
--- a/test/dsets.c
+++ b/test/dsets.c
@@ -366,14 +366,14 @@ test_compression(hid_t file)
const hsize_t chunk_size[2] = {2, 25};
const hssize_t hs_offset[2] = {7, 30};
const hsize_t hs_size[2] = {4, 50};
-#if !(defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ))
+#ifndef H5_HAVE_COMPRESSION
const char *not_supported;
#endif
hsize_t i, j, n;
void *tconv_buf = NULL;
-#if !(defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ))
+#ifndef H5_HAVE_COMPRESSION
not_supported = " Deflate compression is not supported.\n"
" The zlib was not found when hdf5 was configured.";
#endif
@@ -399,7 +399,7 @@ test_compression(hid_t file)
/* Create the dataset */
if ((dataset = H5Dcreate(file, DSET_COMPRESS_NAME, H5T_NATIVE_INT, space,
dc))<0) goto error;
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -426,7 +426,7 @@ test_compression(hid_t file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -448,7 +448,7 @@ test_compression(hid_t file)
if (H5Dwrite(dataset, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, xfer, points)<0)
goto error;
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -477,7 +477,7 @@ test_compression(hid_t file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -517,7 +517,7 @@ test_compression(hid_t file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -549,7 +549,7 @@ test_compression(hid_t file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();
@@ -595,7 +595,7 @@ test_compression(hid_t file)
}
}
}
-#if defined(H5_HAVE_COMPRESS2) && defined(H5_HAVE_ZLIB_H) && defined(H5_HAVE_LIBZ)
+#ifdef H5_HAVE_COMPRESSION
PASSED();
#else
SKIPPED();