Page 1 of 1

Compilation of SERPENT with mpicc

Posted: Thu Sep 22, 2011 5:34 pm
by mathieu.hursin
Dear all,

I have recently received SERPENT-v-1.1.16. I managed to compile it on a single UNIX machine and I have been trying (unsuccessfully) on our cluster here at PSI.

The compilation crashed when dealing with testparam.o with the following message:

testparam.c(14): error: incorrect use of va_start
va_start (argp, *val);

I m using intel/intel-10.0_64 as a compiler and mpi/mpich2-1.0.6-intel-10.0 for mpi.

Has anyone run into a similar problem...if so how did you solve it?

Thanks a lot,


Re: Compilation of SERPENT with mpicc

Posted: Fri Sep 23, 2011 10:41 am
by Jaakko Leppänen
This problem is related to varialble-lenght function argument lists, and GNU and Intel compilers apparently handle them differently. Unfortunately I haven't figured out a solution for this problem, so if possible, you should use the GNU C-compiler instead.

Re: Compilation of SERPENT with mpicc

Posted: Mon Sep 24, 2012 1:30 pm
by fabioalcaro
I just received the latest version of the serpent code 1.1.18 and I am trying to compile it using the mpicc wrapper.
The compilation process partly succeeds, meaning that I don't get any compilation error but I get the following warning message for each compiled file:

Code: Select all

/usr/lib/openmpi/include/mpi.h:220: warning: ISO C90 does not support ‘long long’
mpicc -Wall -ansi -ffast-math -O3 -pedantic -DMPI -c filename.c
In file included from header.h:200,
                 from filename.c:1:
The problem seems to be related to the -DMPI flag option (if I discard such flag, the compilation fully succeeds).
Does anyone know how to overcome this problem? Is it necessary to compile with the -DMPI flag in order to exploit parallel calculation mode?

I give some information about the system in which I am installing serpent:
CPU: Intel(R) Xeon(R) CPU E31270 @ 3.40GHz (4 cores, 8 threads)
OS: Debian Squeeze 6.0.4
C compiler: gcc 4.4.5
MPI: openmpi 1.4.2

Thank you in advance

Re: Compilation of SERPENT with mpicc

Posted: Mon Sep 24, 2012 1:59 pm
by Jaakko Leppänen
I believe this is an unnecessary warning message, related to the mpicc wrapper. You can get rid of it by removing line:

Code: Select all

CFLAGS += -pedantic
in the Makefile.