--- AmberTools/src/configure 2010-10-06 16:53:29.000000000 -0700 +++ AmberTools/src/configure 2010-10-06 17:02:44.000000000 -0700 @@ -19,24 +19,23 @@ solaris (=cc/f90) Optional flags: - -mpi Use MPI for parallelization; assumes mpicc is in your PATH; - (Note: you must first configure and build a serial AmberTools) - -cuda Builds the NVIDIA GPU version of pmemd (pmemd.cuda). - with default SPDP hybrid precision. - (Note: this option is exclusive of mpi and only works with - gnu at present. CUDA_HOME must point to your cuda build tools - installation path.). - -openmp Use OpenMP pragmas to parallelize (not available for pgi; - only affects NAB and sander QM/MM. For NAB, do not set - -openmp and -mpi at the same time.) - -cygwin Modifications for cygwin on Windows. + -mpi Use MPI for parallelization; assumes mpicc and mpif90 are + in your PATH; set MPI_HOME to your MPI installation path. + Note: you must first configure and build a serial AmberTools. + -cuda Builds the NVIDIA GPU version of pmemd (pmemd.cuda and + pmemd.cuda.MPI) with default SPDP hybrid precision. + (Note: Set CUDA_HOME to your cuda build tools installation path.) + -openmp Use OpenMP pragmas to parallelize NAB (not available for pgi). + Do not use -openmp and -mpi at the same time. Type "make + clean; make nabonly" after setting this flag. + -cygwin Modifications for cygwin on Windows -windows Build PMEMD on Windows using the Intel compilers and msmpi. Requires a cygwin installation for building the executables but not for running them. -static Create statically linked executables (not recommended for MacOSX; may not work with some versions of MPI) -noX11 Do not build programs that require X11 libraries, e.g. xleap; - this is generally requied if -static is chosen + this is generally required if -static is chosen -nobintraj Do not include support for binary (NetCDF) trajectory files -nosleap Do not build sleap, which requires fairly modern compilers -oldmkl Set this if you are using MKL version 9 or earlier @@ -370,16 +369,8 @@ echo "Error: CUDA_HOME is not set. This must point to your NVIDIA tools installation" exit 1 fi - if [ "$mpi" = 'yes' ]; then - echo "Error: NVIDIA cuda compilation is exclusive of MPI." - exit 1 - fi - #RCW April 2010: Disable Intel compiler with cuda for the time being since - # it has several issues linking correctly against NVCC. - #if [ ! "$compiler" = "gnu" -a ! "$compiler" = "intel" ]; then - # echo "Error: NVIDIA cuda compilation works only with gnu or Intel compilers" - if [ ! "$compiler" = "gnu" ]; then - echo "Error: NVIDIA cuda compilation works only with gnu compilers" + if [ ! "$compiler" = "gnu" -a ! "$compiler" = "intel" ]; then + echo "Error: NVIDIA cuda compilation works only with gnu or Intel compilers" exit 1 fi if [ ! -x "$CUDA_HOME/bin/nvcc" ]; then @@ -504,6 +495,11 @@ pmemd_cu_defines='-DCUDA' pmemd_cu_libs='-L$(CUDA_HOME)/lib64 -L$(CUDA_HOME)/lib -lcufft -lcudart ./cuda/cuda.a' nvcc='$(CUDA_HOME)/bin/nvcc -use_fast_math -O3 -gencode arch=compute_13,code=sm_13 -gencode arch=compute_20,code=sm_20' + if [ "$mpi" = 'yes' ]; then + pmemd_cu_includes="$pmemd_cu_includes -I\$(MPI_HOME)/include" + pmemd_cu_defines="$pmemd_cu_defines -DMPI -DMPICH_IGNORE_CXX_SEEK" + pmemd_coptflags="$ocflags -DMPICH_IGNORE_CXX_SEEK" + fi fi if [ "$cuda_SPSP" = 'yes' ]; then pmemd_cu_defines="$pmemd_cu_defines -Duse_SPSP" @@ -633,8 +629,11 @@ #PMEMD Specifics pmemd_fpp_flags='-DDIRFRC_EFS -DDIRFRC_COMTRANS -DDIRFRC_NOVEC -DFFTLOADBAL_2PROC -DPUBFFT' - pmemd_foptflags='-fast' - pmemd_coptflags='-fast' +#RCW Removed 10/5/2010 - Causes issues building in parallel since -fast always implies -static. +# pmemd_foptflags='-fast' +# pmemd_coptflags='-fast' + pmemd_foptflags=$foptflags + pmemd_coptflags=$ocflags #CUDA Specifics if [ "$cuda" = 'yes' -o "$cuda_SPSP" = 'yes' -o "$cuda_DPDP" = 'yes' ]; then @@ -643,13 +642,11 @@ pmemd_cu_libs='-L$(CUDA_HOME)/lib64 -L$(CUDA_HOME)/lib -lcufft -lcudart ./cuda/cuda.a' nvcc='$(CUDA_HOME)/bin/nvcc -use_fast_math -O3 -gencode arch=compute_13,code=sm_13 -gencode arch=compute_20,code=sm_20' - #There is a bug in the Intel ipo that causes link errors between - #Fortran and c. Workaround is to not use -fast. - pmemd_foptflags=$foptflags - - #Currently use of -O>0 for c compilation appears to cause problems - #(NANs etc) with CUDA. For the time being use -O0 for ocflags. - pmemd_coptflags="$ocflags -O0" + if [ "$mpi" = 'yes' ]; then + pmemd_cu_includes="$pmemd_cu_includes -I\$(MPI_HOME)/include" + pmemd_cu_defines="$pmemd_cu_defines -DMPI -DMPICH_IGNORE_CXX_SEEK" + pmemd_coptflags="$pmemd_coptflags -DMPICH_IGNORE_CXX_SEEK" + fi fi if [ "$cuda_SPSP" = 'yes' ]; then pmemd_cu_defines="$pmemd_cu_defines -Duse_SPSP" @@ -657,7 +654,7 @@ if [ "$cuda_DPDP" = 'yes' ]; then pmemd_cu_defines="$pmemd_cu_defines -Duse_DPDP" fi - fi #Windows + fi ;; #################### Portland group ####### @@ -989,13 +986,12 @@ majorversion=`echo $version | cut -d'.' -f1` minorversion=`echo $version | cut -d'.' -f2` # The oldest version known to build sleap is 3.2.3. - # But we are leaving the threshold at 3.1 since we expect that to work. - if [ $majorversion -lt 3 -o $majorversion -eq 3 -a $minorversion -lt 1 ] - then - echo "Warning: the C++ compiler is too old to build sleap !" - echo " Upgrade your compiler." - echo " See http://gcc.gnu.org/releases.html for the timeline." - echo " For the moment Amber will be configured not to build sleap." + # But leave the threshold at 3.1 since we expect that to work. + if [ "$version" = "" -o \ + "$majorversion" -lt 3 -o \ + "$majorversion" -eq 3 -a "$minorversion" -lt 1 ]; then + echo "Warning: the C++ compiler is not found or is too old!" + echo "For the moment Amber will be configured not to build sleap." build_sleap="skip_sleap" else echo "OK" @@ -1022,7 +1018,8 @@ if [ $status -gt 0 ]; then echo "Unable to compile a Fortran program using $fc $fflags" - echo "We will be unable to compile sqm" + echo "You need to fix this problem before continuing" + exit 1 else hasfc='yes' echo "OK" @@ -1058,7 +1055,9 @@ status=$? if [ $status -gt 0 ]; then - echo "WARNING: Unable to compile mixed C/Fortran code." + echo "ERROR: Unable to compile mixed C/Fortran code." + echo "You need to fix this problem before continuing." + exit 1 else echo "OK" fi @@ -1310,10 +1309,10 @@ cd fftw-2.1.5 if [ "$mpi" = 'yes' ]; then ./configure $rismflag --enable-mpi CC="$cc" CFLAGS="$cflags" F77="$fc" FFLAGS="$fflags" \ - > ../fftw2_config.log 2>&1 + FLIBS="$flibs_arch" > ../fftw2_config.log 2>&1 else ./configure $rismflag CC="$cc" CFLAGS="$cflags" F77="$fc" FFLAGS="$fflags" \ - > ../fftw2_config.log 2>&1 + FLIBS="$flibs_arch" > ../fftw2_config.log 2>&1 fi ncerror=$? if [ $ncerror -gt 0 ]; then @@ -1344,9 +1343,15 @@ #------------------------------------------------------------------------------ if [ "$mpi" = 'yes' ]; then - cc="mpicc" - fc="mpif90" - mpi_flag="-DMPI" + if [ "$crayxt5" = 'yes' ]; then + cc="cc" + fc="ftn" + mpi_flag="-DMPI -I${MPI_HOME}/include" + else + cc="mpicc" + fc="mpif90" + mpi_flag="-DMPI -I${MPI_HOME}/include" + fi fi #------------------------------------------------------------------------------ @@ -1492,8 +1497,8 @@ FOPTFLAGS= $foptflags \$(LOCALFLAGS) \$(AMBERBUILDFLAGS) FREEFORMAT_FLAG= $freeformat_flag LM=$lm -FPP=$fpp $fppflags $mpi_flag -FPPFLAGS=$fppflags $mpi_flag +FPP=$fpp $fppflags $mpi_flag \$(AMBERBUILDFLAGS) +FPPFLAGS=$fppflags $mpi_flag \$(AMBERBUILDFLAGS) BUILD_SLEAP=$build_sleap XHOME= $xhome @@ -1546,20 +1551,22 @@ echo "The next step is to switch to a dos shell with ifort enabled." echo "Change to \$AMBERHOME/src/ and type 'make clean' followed by" echo "'make parallel_win'." + elif [ "$cuda" = 'yes' -o "$cuda_SPSP" = 'yes' -o "$cuda_DPDP" = 'yes' ]; then + echo "The next step is to cd to ../../src and type 'make cuda_parallel'" else echo "If you have amber11, the most common next step is to " echo "'cd ../../src; make clean; make parallel'. See the Users' Manual" echo "for information on building a parallel version of AmberTools" fi elif [ "$cuda" = 'yes' -o "$cuda_SPSP" = 'yes' -o "$cuda_DPDP" = 'yes' ]; then - echo "The next step is to cd to ../../src and type 'make cuda'" + echo "The next step is to cd to ../../src and type 'make cuda'" elif [ "$windows" = 'yes' ]; then - echo "The next step is to switch to a dos shell with ifort enabled." - echo "Change to \$AMBERHOME/src/ and type 'make serial_win'." + echo "The next step is to switch to a dos shell with ifort enabled." + echo "Change to \$AMBERHOME/src/ and type 'make serial_win'." elif [ "$openmp" = 'yes' ]; then - echo "The next step is to type 'make nabonly'" + echo "The next step is to type 'make nabonly'" else - echo "The next step is to type 'make install'" + echo "The next step is to type 'make install'" fi echo " " --- AmberTools/src/configure 2010-12-16 22:01:21.000000000 -0800 +++ AmberTools/src/configure 2010-12-16 22:09:01.000000000 -0800 @@ -491,7 +491,7 @@ #CUDA Specifics if [ "$cuda" = 'yes' -o "$cuda_SPSP" = 'yes' -o "$cuda_DPDP" = 'yes' ]; then - pmemd_cu_includes='-I$(CUDA_HOME)/include' + pmemd_cu_includes='-I$(CUDA_HOME)/include -IB40C -IB40C/KernelCommon' pmemd_cu_defines='-DCUDA' pmemd_cu_libs='-L$(CUDA_HOME)/lib64 -L$(CUDA_HOME)/lib -lcufft -lcudart ./cuda/cuda.a' nvcc='$(CUDA_HOME)/bin/nvcc -use_fast_math -O3 -gencode arch=compute_13,code=sm_13 -gencode arch=compute_20,code=sm_20' @@ -637,7 +637,7 @@ #CUDA Specifics if [ "$cuda" = 'yes' -o "$cuda_SPSP" = 'yes' -o "$cuda_DPDP" = 'yes' ]; then - pmemd_cu_includes='-I$(CUDA_HOME)/include' + pmemd_cu_includes='-I$(CUDA_HOME)/include -IB40C -IB40C/KernelCommon' pmemd_cu_defines='-DCUDA' pmemd_cu_libs='-L$(CUDA_HOME)/lib64 -L$(CUDA_HOME)/lib -lcufft -lcudart ./cuda/cuda.a' nvcc='$(CUDA_HOME)/bin/nvcc -use_fast_math -O3 -gencode arch=compute_13,code=sm_13 -gencode arch=compute_20,code=sm_20'