Hello
I am trying to compile cosmomc with gfortran 4.1.2; I can run make fine in ./camb, but when I try to run make in ./source I get this error message:
In file Matrix_utils.F90:2206
sz = Size(Arr(1)%M,DIM=1)
1
Error: The upper bound in the last dimension must appear in the reference to the assumed size array 'arr' at (1).
In file Matrix_utils.F90:2226
if (MpiID==0) AM => Arr(i)
1
Error: The upper bound in the last dimension of the assumed_size array on the rhs of the pointer assignment at (1) must be set
make: *** [Matrix_utils.o] Error 1
The compile command from Makefile is:
gfortran -D__GFORTRAN__ -DMATRIX_SINGLE -O2 -I/usr/local/include -I/usr/local/src/likelihood_v3 -I../camb -c Matrix_utils.F90
WMAP_5 and fitsio have been installed without any problem.
Thanks a lot for your help
Error while compiling cosmomc with gfortran
-
- Posts: 1
- Joined: June 13 2008
- Affiliation: UC Berkeley
-
- Posts: 1944
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: Error while compiling cosmomc with gfortran
gfortran is supposed to have fixed this in the latest build, see report at
http://gcc.gnu.org/ml/gcc-patches/2008-03/msg00978.html
Or as a workaround change the declaration of the array (as for __GFORTRAN___ workaround in utils.f90).
http://gcc.gnu.org/ml/gcc-patches/2008-03/msg00978.html
Or as a workaround change the declaration of the array (as for __GFORTRAN___ workaround in utils.f90).