ICC-MPI comiple failed

1,629 views
Skip to first unread message

Albert

unread,
May 14, 2014, 12:05:26 PM5/14/14
to plumed...@googlegroups.com
Hello:

I am trying to compile plumed-2.02 with intel ICC+intel MPI, but it failed with messages:


cd plumed-2.0.2/

export plumeddir="/home/albert/install/plumed-2.0.2"
export PLUMED_ROOT="/home/albert/install/plumed-2.0.2"
export PLUMED_PREFIX="/home/albert/install/plumed-2.0.2"

./configure.sh 
1) linux.gcc               4) linux.mpi.icc
2) linux.icc               5) linux.xcompile.mingw32
3) linux.mpi.gcc
Choose a configuration: 4

source sourceme.sh 

make

--------------------log----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
make[6]: Entering directory `/home/albert/install/plumed-2.0.2/src/analysis'
mpic++ -c -MM -MFHistogram.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 Histogram.cpp
g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [Histogram.o] Error 1
make[6]: Leaving directory `/home/albert/install/plumed-2.0.2/src/analysis'
make[5]: *** [../analysis] Error 2
make[5]: Leaving directory `/home/albert/install/plumed-2.0.2/src/lib'
make[4]: *** [dirs] Error 2
make[4]: Leaving directory `/home/albert/install/plumed-2.0.2/src/lib'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/albert/install/plumed-2.0.2/src/lib'
make[2]: *** [lib] Error 2
make[2]: Leaving directory `/home/albert/install/plumed-2.0.2/src'
make[1]: *** [lib] Error 2
make[1]: Leaving directory `/home/albert/install/plumed-2.0.2'
make: *** [all] Error 2
--------------------log----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

it is really strange that I choose icc-mpi, why it claimed g++ there? It looks like compile it with gcc instead of intel icc?

thx a lot

Albert

Giovanni Bussi

unread,
May 14, 2014, 12:08:34 PM5/14/14
to plumed...@googlegroups.com
It seems that on your machine mpic++ is not the intel compiler but gcc. 

You should use the configuration file for gcc or make sure that mpic++ is the intel compiler. Alternatively, edit the Makefile.conf file setting the name of the intel mpi compiler.

Giovanni


--
You received this message because you are subscribed to the Google Groups "PLUMED users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to plumed-users...@googlegroups.com.
To post to this group, send email to plumed...@googlegroups.com.
Visit this group at http://groups.google.com/group/plumed-users.
For more options, visit https://groups.google.com/d/optout.

Albert

unread,
May 14, 2014, 12:41:04 PM5/14/14
to plumed...@googlegroups.com
Hi Giovanni:

thanks again for kind helps.

The problem solved now after I modified Makefile.conf . However, it has another claimed

make[6]: Entering directory `/home/albert/install/plumed-2.0.2/src/analysis'
icpc -c -MM -MFAnalysis.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 Analysis.cpp
core/../../core/tools/../../tools/Communicator.h(25): catastrophic error: cannot open source file "mpi.h"
  #include <mpi.h>
                  ^
make[6]: *** [Analysis.o] Error 4
make[6]: Leaving directory `/home/albert/install/plumed-2.0.2/src/analysis'
make[5]: *** [../analysis] Error 2

It seems that it cannot find mpi.h file. I checked in my intel diretory, it is there:


install/plumed-2.0.2> find /opt/intel/ -name 'mpi.h'



在 2014年5月14日星期三UTC+2下午6时08分34秒,Giovanni Bussi写道:

Giovanni Bussi

unread,
May 14, 2014, 12:45:37 PM5/14/14
to plumed...@googlegroups.com
You are trying to use "icpc", which is not a mpi compiler.

I think you first have to decide which compiler you will use and understand:
1. if it supports mpi
2. if it is gnu or intel.

It would help if you first try to compile gromacs, then look at what compiler is used.

Giovanni

Albert

unread,
May 14, 2014, 2:38:52 PM5/14/14
to plumed...@googlegroups.com
Intel MPI doesn't contains program called mpic++, so I modified it into icpc. Here is the full list for what I get for intel ICC and MPI:


codecov           compilervars.sh  icc   idb   ifort          inspxe-runsc  link_install.sh  profdcg    proforder      tselect  xild
compilervars.csh  fpp              icpc  idbc  inspxe-inject  inspxe-wrap   map_opts         profmerge  sourcechecker  xiar



compchk.sh        mpdallexit.py   mpdcleanup     mpdhelp.py      mpdman.py       mpdrun.py     mpicleanup     mpif90   mpiifort     pmi_proxy
cpuinfo           mpdboot         mpdcleanup.py  mpdkilljob      mpd.py          mpdsigjob     mpicxx         mpifc    mpirun       tune
hydra_nameserver  mpdboot.py      mpdexit        mpdkilljob.py   mpdringtest     mpdsigjob.py  mpiexec        mpigcc   mpitune
IMB-MPI1          mpdcheck        mpdexit.py     mpdlib.py       mpdringtest.py  mpdtrace      mpiexec.hydra  mpigxx   mpivars.csh
mpd               mpdcheck.py     mpdgdbdrv.py   mpdlistjobs     mpdroot         mpdtrace.py   mpiexec.py     mpiicc   mpivars.sh
mpdallexit        mpdchkpyver.py  mpdhelp        mpdlistjobs.py  mpdrun          mpicc         mpif77         mpiicpc  mtv.so




I can installed Gromacs with intel ICC+ intel MPI without any problem, and I can run jobs well.

I decided to use intel compile with mpi for plumed patched Gromacs.


do you have any idea how to solve the problem? It seems that my current problem is make plumed-2.0 knows how to find the "mpi.h" file in intel compiler directory.

thx a lot


在 2014年5月14日星期三UTC+2下午6时45分37秒,Giovanni Bussi写道:

Giovanni Bussi

unread,
May 14, 2014, 2:43:06 PM5/14/14
to plumed...@googlegroups.com
I think your MPI installation is gcc based, so you either have to reconfigure MPI to use intel compiler or use it with gcc. 

Inviato da iPhone

Massimiliano Bonomi

unread,
May 14, 2014, 2:50:18 PM5/14/14
to plumed...@googlegroups.com
mpicxx should be the C++ mpi compiler
Max

Sent from my iPhone. Please excuse typos and brevity.

Albert

unread,
May 14, 2014, 2:57:09 PM5/14/14
to plumed...@googlegroups.com
thanks a lot.

problem solved after I compile openMPI with icc.

thanks again for kind helps.

Albert




在 2014年5月14日星期三UTC+2下午8时43分06秒,Giovanni Bussi写道:

Albert

unread,
May 14, 2014, 3:09:33 PM5/14/14
to plumed...@googlegroups.com
Maybe.

But I found there are still some problem if I try to use mpicxx from intel compiler directly. It seems that it will have some problem to use intel MPI directly.....



------------Makefile.conf------------------
LIBS=-ldl
DYNAMIC_LIBS=-lstdc++ -llapack -lblas
DOUBLEPRECISION=-r8

CPPFLAGS=-D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI $(CHECK_BOUNDARIES) -I. $(PLUMED_INCLUDE)
CXXFLAGS=-O -fPIC -Wall -wd981,383,1418
CFLAGS=-O -fPIC -Wall

LDFLAGS=-rdynamic
SOEXT=so
LDSO=mpicc -shared $(CFLAGS)
LD=mpicxx
LDF90=mpif90
CXX=mpicxx
CC=mpicc
FC=mpif90

GCCDEP=mpicxx
------------Makefile.conf------------------



make[6]: Entering directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/colvar'
mpicxx -c -MM -MFTorsion.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 Torsion.cpp

g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [Value.o] Error 1
make[6]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/bias'
make[5]: *** [../bias] Error 2
make[5]: *** Waiting for unfinished jobs....
mpicxx -c -MM -MFAnalysis.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 Analysis.cpp

g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [Histogram.o] Error 1
make[6]: *** Waiting for unfinished jobs....mpicxx -c -MM -MFSumHills.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 SumHills.cpp


g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: g++: error: unrecognized command line option ‘-wd981,383,1418’
*** [Manual.o] Error 1
make[6]: *** Waiting for unfinished jobs....
mpicxx -c -MM -MFCoordination.d -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 Coordination.cpp
make[6]: *** [Torsion.o] Error 1
make[6]: *** Waiting for unfinished jobs....

g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [Analysis.o] Error 1
make[6]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/analysis'

make[5]: *** [../analysis] Error 2
g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [SumHills.o] Error 1
make[6]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/cltools'
make[5]: *** [../cltools] Error 2

g++: error: unrecognized command line option ‘-wd981,383,1418’
make[6]: *** [Coordination.o] Error 1
make[6]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/colvar'
make[5]: *** [../colvar] Error 2
make[5]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/lib'

make[4]: *** [dirs] Error 2
make[4]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/lib'

make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src/lib'

make[2]: *** [lib] Error 2
make[2]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2/src'

make[1]: *** [lib] Error 2
make[1]: Leaving directory `/home/albert/Downloads/gromacs/plumed-2.0.2'

make: *** [all] Error 2







在 2014年5月14日星期三UTC+2下午8时50分18秒,Max写道:

Carlo Camilloni

unread,
May 14, 2014, 3:16:12 PM5/14/14
to plumed...@googlegroups.com
it looks like your mpicxx is linked to g++ instead of icpc.
this depend on how your computer is configured,
alternatively you can check whether you have

mpiicpc
and
mpiicc

or you can try to export 

export I_MPI_CC=icc
export I_MPI_CXX=icpc

before starting the compilation.

Carlo
Message has been deleted

Carlo Camilloni

unread,
May 14, 2014, 4:23:08 PM5/14/14
to plumed...@googlegroups.com
Hi,

if you add to CPPFLAGS:

-DMPICH_IGNORE_CXX_SEEK

it will work

Carlo


On 14 May 2014, at 22:03, yua...@gmail.com wrote:

Hello Carlo:

thanks a lot for the kind messages. Here is my new Makefile.conf:

LIBS=-ldl
DYNAMIC_LIBS=-lstdicpc -llapack -lblas

DOUBLEPRECISION=-r8

CPPFLAGS=-D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI $(CHECK_BOUNDARIES) -I. $(PLUMED_INCLUDE)
CXXFLAGS=-O -fPIC -Wall -wd981,383,1418
CFLAGS=-O -fPIC -Wall

LDFLAGS=-rdynamic
SOEXT=so
LDSO=mpiicc -shared $(CFLAGS)
LD=mpiicpc
LDF90=mpif90
CXX=mpiicpc
CC=mpiicc
FC=mpif90

GCCDEP=mpiicpc


I have both mpiicpc and mpicc, but it still failed:


home/albert/install/intel-2013update4/impi/intel64/include/mpicxx.h(95): catastrophic error: #error directive: "SEEK_SET is #defined but must not be for the C++ binding of MPI. Include mpi.h before stdio.h"
  #error "SEEK_SET is #defined but must not be for the C++ binding of MPI. Include mpi.h before stdio.h"
   ^
make[6]: *** [MetaD.o] Error 4

make[6]: *** Waiting for unfinished jobs....
mpiicpc -c -D__PLUMED_HAS_DLOPEN -D__PLUMED_MPI  -I.   -O -fPIC -Wall -wd981,383,1418 UWalls.cpp -o UWalls.o





On Wednesday, May 14, 2014 9:16:12 PM UTC+2, Carlo Camilloni wrote:
it looks like your mpicxx is linked to g++ instead of icpc.
this depend on how your computer is configured,
alternatively you can check whether you have

mpiicpc
and
mpiicc

or you can try to export 

export I_MPI_CC=icc
export I_MPI_CXX=icpc

before starting the compilation.

Carlo

Albert

unread,
May 15, 2014, 1:21:21 AM5/15/14
to plumed...@googlegroups.com
Hi Carlo:

thanks for such useful advices. the "make" step finished without any errors.

but there is some errors for "make install"

cd ../../ ; tar cf - patches scripts src/*/*.h src/*/*.cpp src/*/*.o src/config/compile_options.sh *-doc | tar xf - -C /home/albert/install/plumed-2.0.2/lib/plumed-/home/albert/install/plumed-2.0.2//
cd ../../src ; tar cf - */*.h $(find . -type l) | tar xf - -C /home/albert/install/plumed-2.0.2/include/plumed-/home/albert/install/plumed-2.0.2/
for file in Plumed.inc* Plumed.cmake* ; do sed "s| /home/albert/install/plumed-2.0.2/source| /home/albert/install/plumed-2.0.2/lib/plumed-/home/albert/install/plumed-2.0.2//|g" $file > /home/albert/install/plumed-2.0.2/lib/plumed-/home/albert/install/plumed-2.0.2//src/lib/$file ; done
ln -s /home/albert/install/plumed-2.0.2/lib/plumed-/home/albert/install/plumed-2.0.2//src/lib/plumed /home/albert/install/plumed-2.0.2/bin/plumed-/home/albert/install/plumed-2.0.2
ln: failed to create symbolic link ‘/home/albert/install/plumed-2.0.2/bin/plumed-/home/albert/install/plumed-2.0.2’: No such file or directory
make[3]: *** [install-do] Error 1
make[3]: Leaving directory `/home/albert/install/plumed-2.0.2/source/src/lib'
make[2]: *** [install] Error 2
make[2]: Leaving directory `/home/albert/install/plumed-2.0.2/source/src/lib'
make[1]: *** [install] Error 2
make[1]: Leaving directory `/home/albert/install/plumed-2.0.2/source/src'
make: *** [install] Error 2


here is my environment setting before compiling:

export plumeddir=/home/albert/install/plumed-2.0.2/source
export PLUMED_ROOT=/home/albert/install/plumed-2.0.2/source
export PLUMED_ROOT=/home/albert/install/plumed-2.0.2/source
export PLUMED_PREFIX=/home/albert/install/plumed-2.0.2

thanks again

在 2014年5月14日星期三UTC+2下午10时23分08秒,Carlo Camilloni写道:

Giovanni Bussi

unread,
May 15, 2014, 3:43:14 AM5/15/14
to plumed...@googlegroups.com
Hi Albert,

it looks that also PLUMED_LIBSUFFIX is defined. Could you double check the environment?

env | grep PLUMED_

See this page for instructions on the environment variables for installation: http://plumed.github.io/doc-v2.0/user-doc/html/_installation.html

Ciao!

Giovanni
Reply all
Reply to author
Forward
0 new messages