summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfigure585
-rw-r--r--configure.in107
2 files changed, 617 insertions, 75 deletions
diff --git a/configure b/configure
index 9f69dc0..4a98290 100755
--- a/configure
+++ b/configure
@@ -1021,7 +1021,6 @@ Optional Features:
--enable-trace Enable API tracing capability. Default=no if debug
is disabled.
--enable-parallel Search for MPI-IO and MPI support files
- --enable-mpe Enable MPE instrumentation [default=no]
--enable-filters=all Turn on all internal I/O filters. One may also
specify a comma-separated list of filters or the
word no. The default is all internal I/O filters.
@@ -1050,6 +1049,7 @@ Optional Packages:
--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-mpe=DIR Use MPE instrumentation [default=no]
Some influential environment variables:
CC C compiler command
@@ -30728,34 +30728,145 @@ echo "$as_me: error: no way to run a parallel program" >&2;}
fi
-fi
+ MPE=yes
- MPE=yes
-# Check whether --enable-mpe or --disable-mpe was given.
-if test "${enable_mpe+set}" = set; then
- enableval="$enable_mpe"
+# Check whether --with-mpe or --without-mpe was given.
+if test "${with_mpe+set}" = set; then
+ withval="$with_mpe"
else
- enableval=no
+ withval=no
fi;
-echo "$as_me:$LINENO: checking for MPE instrumentation" >&5
-echo $ECHO_N "checking for MPE instrumentation... $ECHO_C" >&6
-case "X-$enableval" in
- X-|X-no|X-none)
- echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
- unset MPE
- ;;
+ case "X-$withval" in
+ X-|X-no|X-none)
+ echo "$as_me:$LINENO: checking for MPE" >&5
+echo $ECHO_N "checking for MPE... $ECHO_C" >&6
+ echo "$as_me:$LINENO: result: suppressed" >&5
+echo "${ECHO_T}suppressed" >&6
+ unset MPE
+ ;;
+ X-yes)
- X-yes)
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+for ac_header in mpe.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
-echo "$as_me:$LINENO: checking for main in -lmpe" >&5
-echo $ECHO_N "checking for main in -lmpe... $ECHO_C" >&6
-if test "${ac_cv_lib_mpe_main+set}" = set; then
+# 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
+
+else
+ unset MPE
+fi
+
+done
+
+
+echo "$as_me:$LINENO: checking for MPE_Init_log in -lmpe" >&5
+echo $ECHO_N "checking for MPE_Init_log in -lmpe... $ECHO_C" >&6
+if test "${ac_cv_lib_mpe_MPE_Init_log+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -30764,7 +30875,13 @@ cat >conftest.$ac_ext <<_ACEOF
#line $LINENO "configure"
#include "confdefs.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 MPE_Init_log ();
#ifdef F77_DUMMY_MAIN
# ifdef __cplusplus
extern "C"
@@ -30774,7 +30891,7 @@ cat >conftest.$ac_ext <<_ACEOF
int
main ()
{
-main ();
+MPE_Init_log ();
;
return 0;
}
@@ -30791,18 +30908,18 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
- ac_cv_lib_mpe_main=yes
+ ac_cv_lib_mpe_MPE_Init_log=yes
else
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
-ac_cv_lib_mpe_main=no
+ac_cv_lib_mpe_MPE_Init_log=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:$LINENO: result: $ac_cv_lib_mpe_main" >&5
-echo "${ECHO_T}$ac_cv_lib_mpe_main" >&6
-if test $ac_cv_lib_mpe_main = yes; then
+echo "$as_me:$LINENO: result: $ac_cv_lib_mpe_MPE_Init_log" >&5
+echo "${ECHO_T}$ac_cv_lib_mpe_MPE_Init_log" >&6
+if test $ac_cv_lib_mpe_MPE_Init_log = yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBMPE 1
_ACEOF
@@ -30813,24 +30930,416 @@ else
unset MPE
fi
- ;;
+ ;;
+ *)
+ case "$withval" in
+ *,*)
+ mpe_inc="`echo $withval | cut -f1 -d,`"
+ mpe_lib="`echo $withval | cut -f2 -d, -s`"
+ ;;
+ *)
+ if test -n "$withval"; then
+ mpe_inc="$withval/include"
+ mpe_lib="$withval/lib"
+ fi
+ ;;
+ esac
- *)
- echo "$as_me:$LINENO: result: error" >&5
-echo "${ECHO_T}error" >&6
- { { echo "$as_me:$LINENO: error: \'$enableval\' is not a valid MPE value" >&5
-echo "$as_me: error: \'$enableval\' is not a valid MPE value" >&2;}
- { (exit 1); exit 1; }; }
- unset MPE
- ;;
+ if test "X$mpe_inc" = "X/usr/include"; then
+ mpe_inc=""
+ fi
+ if test "X$mpe_lib" = "X/usr/lib"; then
+ mpe_lib=""
+ fi
+
+ if test -n "$mpe_inc"; then
+ saved_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$mpe_inc"
+
+for ac_header in mpe.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
+
+else
+ CPPFLAGS="$saved_CPPFLAGS"; unset MPE
+fi
+
+done
+
+ else
+
+for ac_header in mpe.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
-if test "X-$MPE" = "X-yes"; then
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+else
+ unset MPE
+fi
+
+done
+
+ fi
+
+ if test -n "$mpe_lib"; then
+ saved_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -L$mpe_lib"
+
+echo "$as_me:$LINENO: checking for MPE_Init_log in -lmpe" >&5
+echo $ECHO_N "checking for MPE_Init_log in -lmpe... $ECHO_C" >&6
+if test "${ac_cv_lib_mpe_MPE_Init_log+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lmpe $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.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 MPE_Init_log ();
+#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+int
+main ()
+{
+MPE_Init_log ();
+ ;
+ 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_lib_mpe_MPE_Init_log=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+ac_cv_lib_mpe_MPE_Init_log=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_mpe_MPE_Init_log" >&5
+echo "${ECHO_T}$ac_cv_lib_mpe_MPE_Init_log" >&6
+if test $ac_cv_lib_mpe_MPE_Init_log = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBMPE 1
+_ACEOF
+
+ LIBS="-lmpe $LIBS"
+
+else
+ LDFLAGS="$saved_LDFLAGS"; unset MPE
+fi
+
+ else
+
+echo "$as_me:$LINENO: checking for MPE_Init_log in -lmpe" >&5
+echo $ECHO_N "checking for MPE_Init_log in -lmpe... $ECHO_C" >&6
+if test "${ac_cv_lib_mpe_MPE_Init_log+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lmpe $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+#include "confdefs.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 MPE_Init_log ();
+#ifdef F77_DUMMY_MAIN
+# ifdef __cplusplus
+ extern "C"
+# endif
+ int F77_DUMMY_MAIN() { return 1; }
+#endif
+int
+main ()
+{
+MPE_Init_log ();
+ ;
+ 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_lib_mpe_MPE_Init_log=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat conftest.$ac_ext >&5
+ac_cv_lib_mpe_MPE_Init_log=no
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_mpe_MPE_Init_log" >&5
+echo "${ECHO_T}$ac_cv_lib_mpe_MPE_Init_log" >&6
+if test $ac_cv_lib_mpe_MPE_Init_log = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBMPE 1
+_ACEOF
+
+ LIBS="-lmpe $LIBS"
+
+else
+ unset MPE
+fi
+
+ fi
+ ;;
+ esac
+
+ if test "X-$MPE" = "X-yes"; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_MPE 1
_ACEOF
+ fi
+
fi
echo "$as_me:$LINENO: checking for I/O filters" >&5
diff --git a/configure.in b/configure.in
index b0479f8..5ee4e88 100644
--- a/configure.in
+++ b/configure.in
@@ -1933,6 +1933,7 @@ if test -n "$PARALLEL"; then
RUNPARALLEL=""
fi
+dnl ----------------------------------------------------------------------
dnl Block the MPI_Get_count code since it does not work
dnl dnl Check whether MPI_Get_count actually works correctly on this
dnl dnl platform.
@@ -1959,7 +1960,75 @@ dnl ],
dnl AC_MSG_RESULT(no),
dnl AC_MSG_RESULT(yes)
dnl CPPFLAGS="$CPPFLAGS -DMPI_GET_COUNT_WORKS",AC_MSG_RESULT(no))
-dnl
+dnl ----------------------------------------------------------------------
+
+ dnl --------------------------------------------------------------------
+ dnl Do we want MPE instrumentation feature on?
+ dnl
+ dnl This must be done after enable-parallel is checked since it depends
+ dnl on a mpich compiler.
+ dnl
+ AC_SUBST(MPE) MPE=yes
+ AC_ARG_WITH([mpe],
+ [AC_HELP_STRING([--with-mpe=DIR],
+ [Use MPE instrumentation [default=no]])],,
+ [withval=no])
+
+ case "X-$withval" in
+ X-|X-no|X-none)
+ AC_MSG_CHECKING([for MPE])
+ AC_MSG_RESULT([suppressed])
+ unset MPE
+ ;;
+ X-yes)
+ AC_CHECK_HEADERS([mpe.h],, [unset MPE])
+ AC_CHECK_LIB([mpe], [MPE_Init_log],, [unset MPE])
+ ;;
+ *)
+ case "$withval" in
+ *,*)
+ mpe_inc="`echo $withval | cut -f1 -d,`"
+ mpe_lib="`echo $withval | cut -f2 -d, -s`"
+ ;;
+ *)
+ if test -n "$withval"; then
+ mpe_inc="$withval/include"
+ mpe_lib="$withval/lib"
+ fi
+ ;;
+ esac
+
+ dnl Trying to include -I/usr/include and -L/usr/lib is redundant and
+ dnl can mess some compilers up.
+ if test "X$mpe_inc" = "X/usr/include"; then
+ mpe_inc=""
+ fi
+ if test "X$mpe_lib" = "X/usr/lib"; then
+ mpe_lib=""
+ fi
+
+ if test -n "$mpe_inc"; then
+ saved_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$mpe_inc"
+ AC_CHECK_HEADERS([mpe.h],, [CPPFLAGS="$saved_CPPFLAGS"; unset MPE])
+ else
+ AC_CHECK_HEADERS([mpe.h],, [unset MPE])
+ fi
+
+ if test -n "$mpe_lib"; then
+ saved_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS -L$mpe_lib"
+ AC_CHECK_LIB([mpe], [MPE_Init_log],,
+ [LDFLAGS="$saved_LDFLAGS"; unset MPE])
+ else
+ AC_CHECK_LIB([mpe], [MPE_Init_log],, [unset MPE])
+ fi
+ ;;
+ esac
+
+ if test "X-$MPE" = "X-yes"; then
+ AC_DEFINE([HAVE_MPE], [1], [Define if we have MPE support])
+ fi
dnl ----------------------------------------------------------------------
dnl Check if they would like the "Flexible parallel" functions compiled in
@@ -1980,42 +2049,6 @@ dnl fi
fi
dnl ----------------------------------------------------------------------
-dnl Do we want MPE instrumentation feature on?
-dnl This must be done after enable-parallel is checked since it depends on
-dnl a mpich compiler.
-dnl
-AC_SUBST(MPE) MPE=yes
-AC_ARG_ENABLE([mpe],
- [AC_HELP_STRING([--enable-mpe],
- [Enable MPE instrumentation [default=no]])],,
- [enableval=no])
-
-AC_MSG_CHECKING([for MPE instrumentation])
-case "X-$enableval" in
- X-|X-no|X-none)
- AC_MSG_RESULT(no)
- unset MPE
- ;;
-
- X-yes)
- AC_MSG_RESULT(yes)
-
- dnl Check if MPE library is available
- AC_CHECK_LIB(mpe,main,, unset MPE)
- ;;
-
- *)
- AC_MSG_RESULT(error)
- AC_MSG_ERROR(\'$enableval\' is not a valid MPE value)
- unset MPE
- ;;
-esac
-
-if test "X-$MPE" = "X-yes"; then
- AC_DEFINE(HAVE_MPE, 1, [Define if we have MPE support])
-fi
-
-dnl ----------------------------------------------------------------------
dnl Turn on internal I/O filters by setting macros in header files
dnl Internal I/O filters are contained entirely within the library and do
dnl not depend on external headers or libraries. The shuffle filter is