--- trunk/OOPSE-4/configure 2004/10/15 19:38:12 1579 +++ trunk/OOPSE-4/configure 2005/01/14 20:15:58 1947 @@ -4946,7 +4946,7 @@ done # clean out junk possibly left behind by a previous configuration - rm -f src/utils/getopt.h + rm -f src/getopt.h # Check for getopt_long support for ac_header in getopt.h @@ -5286,7 +5286,7 @@ esac *) LIBOBJS="$LIBOBJS getopt1.$ac_objext" ;; esac - ac_config_links="$ac_config_links src/utils/getopt.h:src/utils/gnugetopt.h" + ac_config_links="$ac_config_links src/getopt.h:src/utils/gnugetopt.h" fi @@ -7232,7 +7232,78 @@ fi echo "${ECHO_T}$ac_cv_lib_mpi_MPI_Init" >&6 if test $ac_cv_lib_mpi_MPI_Init = yes; then MPI_LIB="-lmpi -llam" +fi + +fi +$as_unset ac_cv_lib_mpich_MPI_Init +if test x = x"$MPI_LIB"; then + echo "$as_me:$LINENO: checking for MPI_Init in -lmpich" >&5 +echo $ECHO_N "checking for MPI_Init in -lmpich... $ECHO_C" >&6 +if test "${ac_cv_lib_mpich_MPI_Init+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lmpich "-lpmpich" $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end 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 MPI_Init (); +int +main () +{ +MPI_Init (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (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); }; } && + { 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_mpich_MPI_Init=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_lib_mpich_MPI_Init=no fi +rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_mpich_MPI_Init" >&5 +echo "${ECHO_T}$ac_cv_lib_mpich_MPI_Init" >&6 +if test $ac_cv_lib_mpich_MPI_Init = yes; then + MPI_LIB="-lmpich -lpmpich" +fi fi @@ -7956,7 +8027,7 @@ esac ac_config_headers="$ac_config_headers src/config.h" - ac_config_files="$ac_config_files make/Makefile" + ac_config_files="$ac_config_files make/Makefile src/utils/Makefile" cat >confcache <<\_ACEOF @@ -8488,7 +8559,8 @@ do case "$ac_config_target" in # Handling of arguments. "make/Makefile" ) CONFIG_FILES="$CONFIG_FILES make/Makefile" ;; - "src/utils/getopt.h" ) CONFIG_LINKS="$CONFIG_LINKS src/utils/getopt.h:src/utils/gnugetopt.h" ;; + "src/utils/Makefile" ) CONFIG_FILES="$CONFIG_FILES src/utils/Makefile" ;; + "src/getopt.h" ) CONFIG_LINKS="$CONFIG_LINKS src/getopt.h:src/utils/gnugetopt.h" ;; "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}