--- trunk/OOPSE-4/configure 2006/05/17 03:03:03 2754 +++ trunk/OOPSE-4/configure 2006/07/07 19:44:54 2926 @@ -312,7 +312,7 @@ ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKA # include #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os PROGNAME debug CXX CXXFLAGS LDFLAGS CPPFLAGS ac_ct_CXX EXEEXT OBJEXT CC CFLAGS ac_ct_CC FC FCFLAGS ac_ct_FC CPP EGREP LN_S SET_MAKE RANLIB ac_ct_RANLIB PERLINTERP PERL_SHEBANG INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AR PS FCFLAGS_F90 FCFLAGS_SRCEXT PREPDEFFLAG FCLIBS FC_FUNC FC_FUNC_ MOD F90_WORK_FILES_ARG MODDIRFLAG F90MODINCSPEC F90_MODULE_NAMES ZLIB_INC_DIR ZLIB_LIB_DIR ZLIB FFTW_INC_DIR FFTW_LIB_DIR FFTW_LIBS LIBOBJS POW_LIB CXXCPP __func__ MPI_LIB_DIR MPI_INC_DIR MPI_F90_INC MPI_LIB MPI_F90_LIB USE_MPI USE_CGAL CGAL_INC_DIR CGAL_LIB_DIR CGAL_RLIB_DIR CGAL_DEFINES CGAL_CXXFLAGS CGAL_LIBS DOXYGEN DOT DOC enable_dot enable_html_docs enable_latex_docs BATEXT MKINSTALLDIRS OOPSE OOPSE_HOME SUBDIRS LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os PROGNAME debug USE_SINGLE_PRECISION CXX CXXFLAGS LDFLAGS CPPFLAGS ac_ct_CXX EXEEXT OBJEXT CC CFLAGS ac_ct_CC FC FCFLAGS ac_ct_FC CPP EGREP LN_S SET_MAKE RANLIB ac_ct_RANLIB PERLINTERP PERL_SHEBANG INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA AR PS FCFLAGS_F90 FCFLAGS_SRCEXT PREPDEFFLAG FCLIBS FC_FUNC FC_FUNC_ MOD F90_WORK_FILES_ARG MODDIRFLAG F90MODINCSPEC F90_MODULE_NAMES ZLIB_INC_DIR ZLIB_LIB_DIR ZLIB FFTW_INC_DIR FFTW_LIB_DIR FFTW_LIBS LIBOBJS POW_LIB CXXCPP __func__ MPI_LIB_DIR MPI_INC_DIR MPI_F90_INC MPI_LIB MPI_F90_LIB USE_MPI USE_CGAL CGAL_INC_DIR CGAL_LIB_DIR CGAL_RLIB_DIR CGAL_DEFINES CGAL_CXXFLAGS CGAL_LIBS DOXYGEN DOT DOC enable_dot enable_html_docs enable_latex_docs BATEXT MKINSTALLDIRS OOPSE OOPSE_HOME SUBDIRS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -871,6 +871,8 @@ Optional Features: --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-oopse-home=DIR define oopse home dir PREFIX/oopse --enable-debug Compile OOPSE in debug mode + --enable-single compile OOPSE in single precision + --enable-float synonym for --enable-single --enable-doxygen enable documentation generation with doxygen (auto) --enable-dot use 'dot' to generate graphs in doxygen (auto) --enable-html-docs enable HTML generation with doxygen (yes) @@ -1622,8 +1624,30 @@ fi msg="$msg, debug mode" fi + + +# Check whether --enable-single or --disable-single was given. +if test "${enable_single+set}" = set; then + enableval="$enable_single" + ok=$enableval +else + ok=no +fi; +# Check whether --enable-float or --disable-float was given. +if test "${enable_float+set}" = set; then + enableval="$enable_float" + ok=$enableval +fi; +if test "$ok" = "yes"; then +cat >>confdefs.h <<\_ACEOF +#define SINGLE_PRECISION 1 +_ACEOF + USE_SINGLE_PRECISION=yes + +fi + # Checks for programs. ac_ext=cc ac_cpp='$CXXCPP $CPPFLAGS' @@ -1631,7 +1655,7 @@ if test -n "$ac_tool_prefix"; then ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -n "$ac_tool_prefix"; then - for ac_prog in $CCC icpc icc pgCC pathCC c++ xlc++ xlC g++ CC + for ac_prog in $CCC mpicxx icpc pathCC pgCC c++ xlc++ xlC g++ CC do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 @@ -1673,7 +1697,7 @@ if test -z "$CXX"; then fi if test -z "$CXX"; then ac_ct_CXX=$CXX - for ac_prog in $CCC icpc icc pgCC pathCC c++ xlc++ xlC g++ CC + for ac_prog in $CCC mpicxx icpc pathCC pgCC c++ xlc++ xlC g++ CC do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 @@ -2187,7 +2211,7 @@ if test -n "$ac_tool_prefix"; then ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then - for ac_prog in icc pgcc pathcc cc xlc gcc + for ac_prog in mpicc icc pathcc pgcc cc xlc gcc do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 @@ -2229,7 +2253,7 @@ if test -z "$CC"; then fi if test -z "$CC"; then ac_ct_CC=$CC - for ac_prog in icc pgcc pathcc cc xlc gcc + for ac_prog in mpicc icc pathcc pgcc cc xlc gcc do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 @@ -2698,7 +2722,7 @@ if test -n "$ac_tool_prefix"; then ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $FCFLAGS_SRCEXT conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_fc_compiler_gnu if test -n "$ac_tool_prefix"; then - for ac_prog in ifort ifc pgf95 pathf95 xlf95 lf95 epcf90 pathf90 xlf90 f95 f90 gfortran g95 fort + for ac_prog in mpif90 ifort ifc pathf95 pgf95 xlf95 lf95 epcf90 pathf90 xlf90 f95 f90 gfortran g95 fort do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 @@ -2740,7 +2764,7 @@ if test -z "$FC"; then fi if test -z "$FC"; then ac_ct_FC=$FC - for ac_prog in ifort ifc pgf95 pathf95 xlf95 lf95 epcf90 pathf90 xlf90 f95 f90 gfortran g95 fort + for ac_prog in mpif90 ifort ifc pathf95 pgf95 xlf95 lf95 epcf90 pathf90 xlf90 f95 f90 gfortran g95 fort do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 @@ -2785,7 +2809,7 @@ echo "$as_me:2788:" \ # Provide some information about the compiler. -echo "$as_me:2788:" \ +echo "$as_me:2812:" \ "checking for Fortran compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 @@ -4033,7 +4057,7 @@ FCFLAGS="$FCFLAGS $ac_verb" # flags. ac_save_FFLAGS=$FCFLAGS FCFLAGS="$FCFLAGS $ac_verb" -(eval echo $as_me:4036: \"$ac_link\") >&5 +(eval echo $as_me:4060: \"$ac_link\") >&5 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'` echo "$ac_fc_v_output" >&5 FCFLAGS=$ac_save_FFLAGS @@ -4111,7 +4135,7 @@ FCFLAGS="$FCFLAGS $ac_cv_prog_fc_v" # flags. ac_save_FFLAGS=$FCFLAGS FCFLAGS="$FCFLAGS $ac_cv_prog_fc_v" -(eval echo $as_me:4114: \"$ac_link\") >&5 +(eval echo $as_me:4138: \"$ac_link\") >&5 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'` echo "$ac_fc_v_output" >&5 FCFLAGS=$ac_save_FFLAGS @@ -4847,7 +4871,7 @@ FCFLAGS="$FCFLAGS $ac_verb" # flags. ac_save_FFLAGS=$FCFLAGS FCFLAGS="$FCFLAGS $ac_verb" -(eval echo $as_me:4850: \"$ac_link\") >&5 +(eval echo $as_me:4874: \"$ac_link\") >&5 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'` echo "$ac_fc_v_output" >&5 FCFLAGS=$ac_save_FFLAGS @@ -4925,7 +4949,7 @@ FCFLAGS="$FCFLAGS $ac_cv_prog_fc_v" # flags. ac_save_FFLAGS=$FCFLAGS FCFLAGS="$FCFLAGS $ac_cv_prog_fc_v" -(eval echo $as_me:4928: \"$ac_link\") >&5 +(eval echo $as_me:4952: \"$ac_link\") >&5 ac_fc_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'` echo "$ac_fc_v_output" >&5 FCFLAGS=$ac_save_FFLAGS @@ -12972,15 +12996,21 @@ MPI_INC_DIR="$MPI/include" # Set variables... MPI_LIB_DIR="$MPI/lib" MPI_INC_DIR="$MPI/include" + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu echo "$as_me:$LINENO: checking for mpi.h" >&5 echo $ECHO_N "checking for mpi.h... $ECHO_C" >&6 have_mpi_h=0 rm -f conftest* -echo '#include ' > conftest.cc -if ${CXX} -I${MPI_INC_DIR} -c conftest.cc 2>&1 ; then +echo '#include ' > conftest.c +if ${CC} -I${MPI_INC_DIR} -c conftest.c 2>&1 ; then echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 have_mpi_h=1 @@ -13003,6 +13033,16 @@ have_mpif_h=0 echo "$as_me:$LINENO: checking whether mpif.h is usable" >&5 echo $ECHO_N "checking whether mpif.h is usable... $ECHO_C" >&6 + + +ac_ext=${FC_SRCEXT-f} +ac_compile='$FC -c $FCFLAGS $FCFLAGS_SRCEXT conftest.$ac_ext >&5' +ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $FCFLAGS_SRCEXT conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_fc_compiler_gnu + +ac_save_ext=$ac_ext +ac_ext=F90 +ac_save_FCFLAGS=$FCFLAGS have_mpif_h=0 rm -f conftest* cat >conftest.$ac_ext <&5 @@ -13120,14 +13168,15 @@ if test x = x"$MPI_LIB"; then 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 -lmpi" >&5 -echo $ECHO_N "checking for MPI_Init in -lmpi... $ECHO_C" >&6 -if test "${ac_cv_lib_mpi_MPI_Init+set}" = set; then + echo "$as_me:$LINENO: checking for MPI_Init in -lpmpich" >&5 +echo $ECHO_N "checking for MPI_Init in -lpmpich... $ECHO_C" >&6 +if test "${ac_cv_lib_pmpich_MPI_Init+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lmpi $LIBS" +LIBS="-lpmpich -lmpich -lpmpich -lmpich $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -13180,25 +13229,24 @@ 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_mpi_MPI_Init=yes + ac_cv_lib_pmpich_MPI_Init=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -ac_cv_lib_mpi_MPI_Init=no +ac_cv_lib_pmpich_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_mpi_MPI_Init" >&5 -echo "${ECHO_T}$ac_cv_lib_mpi_MPI_Init" >&6 -if test $ac_cv_lib_mpi_MPI_Init = yes; then - MPI_LIB="-lmpi" +echo "$as_me:$LINENO: result: $ac_cv_lib_pmpich_MPI_Init" >&5 +echo "${ECHO_T}$ac_cv_lib_pmpich_MPI_Init" >&6 +if test $ac_cv_lib_pmpich_MPI_Init = yes; then + MPI_LIB="-lpmpich -lmpich -lpmpich -lmpich" fi fi -$as_unset ac_cv_lib_mpi_MPI_Init if test x = x"$MPI_LIB"; then echo "$as_me:$LINENO: checking for MPI_Init in -lmpi" >&5 echo $ECHO_N "checking for MPI_Init in -lmpi... $ECHO_C" >&6 @@ -13206,7 +13254,7 @@ LIBS="-lmpi "-llam" $LIBS" echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lmpi "-llam" $LIBS" +LIBS="-lmpi $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -13273,19 +13321,19 @@ if test $ac_cv_lib_mpi_MPI_Init = yes; then echo "$as_me:$LINENO: result: $ac_cv_lib_mpi_MPI_Init" >&5 echo "${ECHO_T}$ac_cv_lib_mpi_MPI_Init" >&6 if test $ac_cv_lib_mpi_MPI_Init = yes; then - MPI_LIB="-lmpi -llam" + MPI_LIB="-lmpi" fi fi -$as_unset ac_cv_lib_mpich_MPI_Init +$as_unset ac_cv_lib_mpi_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 "$as_me:$LINENO: checking for MPI_Init in -lmpi" >&5 +echo $ECHO_N "checking for MPI_Init in -lmpi... $ECHO_C" >&6 +if test "${ac_cv_lib_mpi_MPI_Init+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lmpich "-lpmpich" $LIBS" +LIBS="-lmpi -llam $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -13338,25 +13386,24 @@ 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_mpich_MPI_Init=yes + ac_cv_lib_mpi_MPI_Init=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -ac_cv_lib_mpich_MPI_Init=no +ac_cv_lib_mpi_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="-lpmpich -lmpich" +echo "$as_me:$LINENO: result: $ac_cv_lib_mpi_MPI_Init" >&5 +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_mpi_MPI_Init if test x = x"$MPI_LIB"; then echo "$as_me:$LINENO: checking for MPI_Init in -lmpi" >&5 @@ -14703,6 +14750,7 @@ s,@CXX@,$CXX,;t t s,@host_os@,$host_os,;t t s,@PROGNAME@,$PROGNAME,;t t s,@debug@,$debug,;t t +s,@USE_SINGLE_PRECISION@,$USE_SINGLE_PRECISION,;t t s,@CXX@,$CXX,;t t s,@CXXFLAGS@,$CXXFLAGS,;t t s,@LDFLAGS@,$LDFLAGS,;t t