CAMB_sources compilation
-
- Posts: 6
- Joined: June 04 2014
- Affiliation: University of the Western Cape
CAMB_sources compilation
Hey
I've been trying to use 2013 distribution of CAMB_sources but I have been unable to compile it.
Using gfortran 5.1 I've got several errors when compiling equations.f90 mainly related to the length of the lines and having issues wi EV% variables. Some of the errors are:
equations.f90:1711:132:
counts_radial_source= (1-2.5*W%dlog10Ndm)*((-4.D0*W%wing2(j)/chi*adotoa-2.D0*(-W%dwing2(j)*chi-W%wing2(j))/chi**2)/ &
1
Error: Line truncated at (1) [-Werror=line-truncation]
or
equations.f90:2401:26:
type(EvolutionVars) EV
1
Error: Name 'ev' at (1) is an ambiguous reference to 'ev' from current program unit
Been trying to use other version of gfortran and other flags but haven't been able to solve it.
Did anyone else had this problem?
Zé
I've been trying to use 2013 distribution of CAMB_sources but I have been unable to compile it.
Using gfortran 5.1 I've got several errors when compiling equations.f90 mainly related to the length of the lines and having issues wi EV% variables. Some of the errors are:
equations.f90:1711:132:
counts_radial_source= (1-2.5*W%dlog10Ndm)*((-4.D0*W%wing2(j)/chi*adotoa-2.D0*(-W%dwing2(j)*chi-W%wing2(j))/chi**2)/ &
1
Error: Line truncated at (1) [-Werror=line-truncation]
or
equations.f90:2401:26:
type(EvolutionVars) EV
1
Error: Name 'ev' at (1) is an ambiguous reference to 'ev' from current program unit
Been trying to use other version of gfortran and other flags but haven't been able to solve it.
Did anyone else had this problem?
Zé
-
- Posts: 1944
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: CAMB_sources compilation
Try compiling with -ffixed-line-length-none ?
-
- Posts: 6
- Joined: June 04 2014
- Affiliation: University of the Western Cape
CAMB_sources compilation
It didn't work. I also took out the flag -march=native since it was giving an error.
-
- Posts: 1944
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: CAMB_sources compilation
Might want to check your gfortran is up to date (at least version 4.8), or try virtual machines at http://cosmologist.info/CosmoBox/.
-
- Posts: 1944
- Joined: September 23 2004
- Affiliation: University of Sussex
- Contact:
Re: CAMB_sources compilation
The line length error was trivial to fix. The "ev" error is from the symbol being defined in two modules (EV and eV in constants). I've fixed these for gfortran compatibility (try CAMB_sources branch at https://github.com/cmbant/CAMB/).