summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Wendling <wendling@ncsa.uiuc.edu>2001-07-09 17:50:12 (GMT)
committerBill Wendling <wendling@ncsa.uiuc.edu>2001-07-09 17:50:12 (GMT)
commit7f5b00c2152033b07f5f1ab99863235cbce8048f (patch)
treea457ad2036a18dc51a4777643dee9370e41f243b
parent447830cdfba2efcce3aced15de3f1bddb299037a (diff)
downloadhdf5-7f5b00c2152033b07f5f1ab99863235cbce8048f.zip
hdf5-7f5b00c2152033b07f5f1ab99863235cbce8048f.tar.gz
hdf5-7f5b00c2152033b07f5f1ab99863235cbce8048f.tar.bz2
[svn-r4156]
Purpose: Fix Description: I didn't put the zlib fix into the 1.4 branch. Solution: Put the fix into the configure to clear the cache so that configure always checks for zlib in the fortran/ directory so that it'll be put in the LFlags macro.
-rwxr-xr-xfortran/configure85
-rw-r--r--fortran/configure.in7
2 files changed, 51 insertions, 41 deletions
diff --git a/fortran/configure b/fortran/configure
index ac8ef21..2836c63 100755
--- a/fortran/configure
+++ b/fortran/configure
@@ -1968,6 +1968,9 @@ cross_compiling=$ac_cv_prog_cc_cross
+
+ac_cv_lib_z_compress=""
+
# Check whether --with-zlib or --without-zlib was given.
if test "${with_zlib+set}" = set; then
withval="$with_zlib"
@@ -1982,17 +1985,17 @@ case "$withval" in
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1986: checking for $ac_hdr" >&5
+echo "configure:1989: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1991 "configure"
+#line 1994 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1996: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1999: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2019,7 +2022,7 @@ fi
done
echo $ac_n "checking for compress in -lz""... $ac_c" 1>&6
-echo "configure:2023: checking for compress in -lz" >&5
+echo "configure:2026: checking for compress in -lz" >&5
ac_lib_var=`echo z'_'compress | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2027,7 +2030,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lz $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2031 "configure"
+#line 2034 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2038,7 +2041,7 @@ int main() {
compress()
; return 0; }
EOF
-if { (eval echo configure:2042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2068,7 +2071,7 @@ fi
;;
no)
echo $ac_n "checking for GNU zlib""... $ac_c" 1>&6
-echo "configure:2072: checking for GNU zlib" >&5
+echo "configure:2075: checking for GNU zlib" >&5
echo "$ac_t""suppressed" 1>&6
;;
*)
@@ -2080,17 +2083,17 @@ echo "configure:2072: checking for GNU zlib" >&5
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2084: checking for $ac_hdr" >&5
+echo "configure:2087: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2089 "configure"
+#line 2092 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2094: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2097: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2122,17 +2125,17 @@ done
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2126: checking for $ac_hdr" >&5
+echo "configure:2129: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2131 "configure"
+#line 2134 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2136: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2139: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2166,7 +2169,7 @@ done
LDFLAGS="$LDFLAGS -L$zlib_lib"
ZLIB_DIR=$zlib_lib
echo $ac_n "checking for compress in -lz""... $ac_c" 1>&6
-echo "configure:2170: checking for compress in -lz" >&5
+echo "configure:2173: checking for compress in -lz" >&5
ac_lib_var=`echo z'_'compress | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2174,7 +2177,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lz $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2178 "configure"
+#line 2181 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2185,7 +2188,7 @@ int main() {
compress()
; return 0; }
EOF
-if { (eval echo configure:2189: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2215,7 +2218,7 @@ fi
else
echo $ac_n "checking for compress in -lz""... $ac_c" 1>&6
-echo "configure:2219: checking for compress in -lz" >&5
+echo "configure:2222: checking for compress in -lz" >&5
ac_lib_var=`echo z'_'compress | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2223,7 +2226,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lz $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2227 "configure"
+#line 2230 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2234,7 +2237,7 @@ int main() {
compress()
; return 0; }
EOF
-if { (eval echo configure:2238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2323,7 +2326,7 @@ case "$CC_BASENAME" in
mpicc)
PARALLEL=mpicc
echo $ac_n "checking for mpirun""... $ac_c" 1>&6
-echo "configure:2327: checking for mpirun" >&5
+echo "configure:2330: checking for mpirun" >&5
cmd=`echo $CC |cut -f1 -d' '`
if (echo $cmd |grep / >/dev/null); then
@@ -2363,7 +2366,7 @@ fi
echo $ac_n "checking for parallel support files""... $ac_c" 1>&6
-echo "configure:2367: checking for parallel support files" >&5
+echo "configure:2370: checking for parallel support files" >&5
case "X-$enable_parallel" in
X-|X-no|X-none)
echo "$ac_t""skipped" 1>&6
@@ -2374,21 +2377,21 @@ case "X-$enable_parallel" in
PARALLEL=yes
cat > conftest.$ac_ext <<EOF
-#line 2378 "configure"
+#line 2381 "configure"
#include "confdefs.h"
int main() {
MPI_Init()
; return 0; }
EOF
-if { (eval echo configure:2385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
:
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -rf conftest*
echo $ac_n "checking for MPI_Init in -lmpi""... $ac_c" 1>&6
-echo "configure:2392: checking for MPI_Init in -lmpi" >&5
+echo "configure:2395: checking for MPI_Init in -lmpi" >&5
ac_lib_var=`echo mpi'_'MPI_Init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2396,7 +2399,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lmpi $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2400 "configure"
+#line 2403 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2407,7 +2410,7 @@ int main() {
MPI_Init()
; return 0; }
EOF
-if { (eval echo configure:2411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2440,21 +2443,21 @@ rm -f conftest*
if test "X$PARALLEL" = "Xyes"; then
cat > conftest.$ac_ext <<EOF
-#line 2444 "configure"
+#line 2447 "configure"
#include "confdefs.h"
int main() {
MPI_File_open()
; return 0; }
EOF
-if { (eval echo configure:2451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2454: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
:
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -rf conftest*
echo $ac_n "checking for MPI_File_open in -lmpio""... $ac_c" 1>&6
-echo "configure:2458: checking for MPI_File_open in -lmpio" >&5
+echo "configure:2461: checking for MPI_File_open in -lmpio" >&5
ac_lib_var=`echo mpio'_'MPI_File_open | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2462,7 +2465,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lmpio $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2466 "configure"
+#line 2469 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2473,7 +2476,7 @@ int main() {
MPI_File_open()
; return 0; }
EOF
-if { (eval echo configure:2477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2516,7 +2519,7 @@ rm -f conftest*
PARALLEL=mpich
echo $ac_n "checking for MPI_Init in -lmpich""... $ac_c" 1>&6
-echo "configure:2520: checking for MPI_Init in -lmpich" >&5
+echo "configure:2523: checking for MPI_Init in -lmpich" >&5
ac_lib_var=`echo mpich'_'MPI_Init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2524,7 +2527,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lmpich $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2528 "configure"
+#line 2531 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2535,7 +2538,7 @@ int main() {
MPI_Init()
; return 0; }
EOF
-if { (eval echo configure:2539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2583,23 +2586,23 @@ EOF
echo $ac_n "checking prefix for running on one processor""... $ac_c" 1>&6
-echo "configure:2587: checking prefix for running on one processor" >&5
+echo "configure:2590: checking prefix for running on one processor" >&5
echo "$ac_t""$RUNSERIAL" 1>&6
echo $ac_n "checking prefix for running in parallel""... $ac_c" 1>&6
-echo "configure:2590: checking prefix for running in parallel" >&5
+echo "configure:2593: checking prefix for running in parallel" >&5
echo "$ac_t""$RUNPARALLEL" 1>&6
echo $ac_n "checking whether a simple MPI-IO program can be linked""... $ac_c" 1>&6
-echo "configure:2594: checking whether a simple MPI-IO program can be linked" >&5
+echo "configure:2597: checking whether a simple MPI-IO program can be linked" >&5
cat > conftest.$ac_ext <<EOF
-#line 2596 "configure"
+#line 2599 "configure"
#include "confdefs.h"
int main() {
MPI_Init();MPI_File_open();
; return 0; }
EOF
-if { (eval echo configure:2603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
echo "$ac_t""yes" 1>&6
else
@@ -2627,7 +2630,7 @@ fi
echo $ac_n "checking make""... $ac_c" 1>&6
-echo "configure:2631: checking make" >&5
+echo "configure:2634: checking make" >&5
if test "`${MAKE-make} --version -f /dev/null 2>/dev/null |\
sed -n 1p|cut -c1-8`" = "GNU Make"; then
@@ -2644,7 +2647,7 @@ fi
if test -z "$DEPEND"; then
echo $ac_n "checking how to include a makefile""... $ac_c" 1>&6
-echo "configure:2648: checking how to include a makefile" >&5
+echo "configure:2651: checking how to include a makefile" >&5
cat >makeinc <<EOF
foo:
diff --git a/fortran/configure.in b/fortran/configure.in
index 5e9bf84..0004cca 100644
--- a/fortran/configure.in
+++ b/fortran/configure.in
@@ -249,6 +249,13 @@ dnl Is the GNU zlib present? It has a header file `zlib.h' and a library
dnl `-lz' and their locations might be specified with the `--enable-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 If the presence of zlib is already cached by the top-level configure,
+dnl then "uncache" it so that we will go through this logic in any case.
+dnl Some systems where you need to specify exactly where the zlib is need
+dnl this.
+ac_cv_lib_z_compress=""
+
AC_ARG_WITH(zlib,[ --with-zlib=INC,LIB Use the GNU zlib compression],
,withval=yes)
case "$withval" in