AMBER Archive (2009)
Subject: Re: [AMBER] compiling amber10 with mac intel, ifort/icc and mpi
From: Alan (alanwilter_at_gmail.com)
Date: Sat Jun 13 2009 - 13:37:54 CDT
Thanks dear David, I could manage following your hints and here is my recipe:
# To install Intel C/C++ and Fortran compilers
# install them, they will work for one month but your binaries will
# To renew license after a month, go to links above and copy e-mailed
*.lic files in /Users/Shared/Library/Application\
# OPEN MPI with INTEL COMPILERS
# Mac Osx has openmpi but not with support for Fortran77/Fortran90
# openmpi 1.3.x didnâ€™t work
wget -c http://www.open-mpi.org/software/ompi/v1.2/downloads/openmpi-1.2.9.tar.bz2
tar xvfj openmpi-1.2.9.tar.bz2
./configure --prefix=/usr/local CC=icc CXX=icpc F77=ifort FC=ifort
make -j 2 all
sudo make -j 2 install
export PATH=/usr/local/bin:$PATH # IMPORTANT: /usr/local/bin has to
come first to avoid conflict with MPI in /usr/bin and /sw/bin
# Installing AmberTools
# set AMBERHOME
tar xvfj AmberTools-1.2.tar.bz2
wget -c http://ambermd.org/bugfixes/AmberTools/1.2/bugfix.all
mv -f bugfix.all bugfixAmberTools.all
patch -p0 -N < bugfixAmberTools.all
make -j 2 -f Makefile_at
cd $AMBERHOME/test; make -f Makefile_at test
# Installing AMBER 10 SERIAL
tar xvfj Amber10.tar.bz2
wget -c http://ambermd.org/bugfixes/10.0/bugfix.all
mv -f bugfix.all bugfixAmber.all
patch -p0 -N < bugfixAmber.all
./configure_amber -nosanderidc ifort_macosx # â€˜-nosanderidcâ€™ is
because â€˜divconâ€™ doesnâ€™t work with ifort
make -j 2 serial
cd $AMBERHOME/test; make test
# AMBER PARALLEL
./configure_amber -nosanderidc -openmpi ifort_macosx
make -j 2 parallel
export DO_PARALLEL="mpirun -np 2"
All went fine!
Just some questions more. Divcon is still not ready for inter
compilers? Is is possible to compile divcon alone only with gnu
compilers? Did anyone get PMEMD compiled with Mac intel? From the
README, it seems to be not supported.
On Thu, Jun 11, 2009 at 13:43, David Watson <dewatson_at_olemiss.edu> wrote:
> On Jun 11, 2009, at 6:14 AM, Alan wrote:
>> So I did (as following the basic approach as in the manual, with gfortran
>> instead of g95):make clean
>> ./configure_amber -lamsource gfortran
>> make parallel
>> And got:
>> /Users/alan/Programmes/amber10/bin/mpif77 Â -ffree-form Â -o sander.MPI
>> constants.o nose_hoover.o [snip] ncsu-smd-hooks.o ncsu-umbrella.o
>> ncsu-utils.o ncsu-value.o ../netcdf/lib/libnetcdf.a
>> ld warning: duplicate dylib /sw/lib/gcc4.4/lib/libgcc_s.1.dylib
> It appears that you have Fink installed.
> Are you sure that you want to use the gcc provided with Fink?
> If you simply need gfortran, try installing R, as they have gone through the trouble of compiling it and providing it with their installation package.
> Then try compiling with the system gcc/gfortran by commenting out the appropriate line in your bash init scripts (the one that sources the file in /sw) and logging into a new Terminal.
> As far as mpi goes, Apple does provide openmpi, but unfortunately this is not compiled with support for fortran routines, which means you will need to get the source for gfortran and the base gcc collection, then compile your own version if you need mpi.
> Then you have to specify the full path to your version of mpirun to override the one in /usr/bin.
>> Undefined symbols:
>> "_lam_f77init", referenced from:
>> Â Â _lam_f77init$non_lazy_ptr in liblamf77mpi.a(init_f.o)
>> "_lam_mpi_comm_world", referenced from:
>> Â Â _mpi_recv_ in liblamf77mpi.a(recv_f.o)
>> Â Â _mpi_wait_ in liblamf77mpi.a(wait_f.o)
>> ld: symbol(s) not found
>> collect2: ld returned 1 exit status
>> make: *** [sander.MPI] Error 1
>> make: *** [parallel] Error 2
>> On Wed, Jun 10, 2009 at 17:54, David A. Case <case_at_biomaps.rutgers.edu>wrote:
>>> On Wed, Jun 10, 2009, Alan wrote:
>>>> ./configure_amber -nosanderidc -mpi -p4 gfortran
>>>> Undefined symbols:
>>>> "_mpi_reduce_", referenced from:
>>> Your build is not finding the MPI libraries. Â I have no idea where they are
>>> your computer. Â When you use the "-mpi" flag, the configure script assumes
>>> that the required MPI libraries will be found. Â If not, you have to edit
>>> config_amber.h to add the correct paths to the LOADLIB variable.
>>> As a start, run configure_amber with the -lamsource option instead of -mpi.
>>> This should(!) compile with gfortran (does on other platforms) and will
>>> automatically put all the correct paths into the build scripts. Â (Be sure
>>> run configure_lam as the script instructs you to do; also, I'd still
>>> leaving off the "-j 2" flag to make..parallel makes have not been tested
>>> ...hope this helps....dac
> AMBER mailing list
Alan Wilter S. da Silva, D.Sc. - CCPN Research Associate
Department of Biochemistry, University of Cambridge.
80 Tennis Court Road, Cambridge CB2 1GA, UK.
AMBER mailing list