Problem with running make, Error 1

Use of Cobaya. camb, CLASS, cosmomc, compilers, etc.
Post Reply
Rami Taheri
Posts: 1
Joined: July 07 2017
Affiliation: University of Sydney

Problem with running make, Error 1

Post by Rami Taheri » July 11 2017

I am trying to compile CAMB using gfortran 4.8.5 20150623 (Red Hat 4.8.5-11).
After runnung 'make clean' and 'make', it gives 'Error 1':

Code: Select all

mkdir -p Release
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c constants.f90 -o Release/constants.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c utils.F90 -o Release/utils.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c subroutines.f90 -o Release/subroutines.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c inifile.f90 -o Release/inifile.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c power_tilt.f90 -o Release/power_tilt.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c recfast.f90 -o Release/recfast.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c reionization.f90 -o Release/reionization.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c modules.f90 -o Release/modules.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c bessels.f90 -o Release/bessels.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c equations.f90 -o Release/equations.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c halofit_ppf.f90 -o Release/halofit_ppf.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c lensing.f90 -o Release/lensing.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c SeparableBispectrum.F90 -o Release/SeparableBispectrum.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c cmbmain.f90 -o Release/cmbmain.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ -c camb.f90 -o Release/camb.o
ifort -fast -W0 -WB -fpp  -qopenmp -module Release -IRelease/ Release/constants.o  Release/utils.o   Release/subroutines.o Release/inifile.o  Release/power_tilt.o  Release/recfast.o Release/reionization.o Release/modules.o Release/bessels.o Release/equations.o Release/halofit_ppf.o Release/lensing.o Release/SeparableBispectrum.o Release/cmbmain.o Release/camb.o inidriver.F90 -cxxlib -o camb
ld: cannot find -lstdc++
ld: cannot find -lm
ld: cannot find -lstdc++
ld: cannot find -lpthread
ld: cannot find -lc
ld: cannot find -ldl
ld: cannot find -lc
make: *** [camb] Error 1
Following this thread:
http://cosmocoffee.info/viewtopic.php?t ... ight=lstdc
I tried deleting lstdc++ in the Makefile, but it still keeps giving the same error.

Can you please help me about this issue?[/url]

Ira *Wolfson
Posts: 69
Joined: January 24 2013
Affiliation: MPA
Contact:

Problem with running make, Error 1

Post by Ira *Wolfson » July 11 2017

Seems to me an error that has to do with compiling cfitsio

Having said that I would look at the following link:

https://stackoverflow.com/questions/407 ... e#40827727

Antony Lewis
Posts: 1936
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

Re: Problem with running make, Error 1

Post by Antony Lewis » July 11 2017

You seem to be building with ifort not gfortran (which would require at least gcc 4.9).

Ira *Wolfson
Posts: 69
Joined: January 24 2013
Affiliation: MPA
Contact:

Problem with running make, Error 1

Post by Ira *Wolfson » July 11 2017

BTW,

There is a VERY USEFUL arxiv document that basically outlines in detail how
to compile and run CosmoMC:


https://arxiv.org/pdf/1409.1354.pdf


If you haven't consulted it yet, you should - it was VERY HELPFUL to me.

-- Ira

Adam D. Helfer
Posts: 1
Joined: July 19 2017
Affiliation: University of Missouri

Problem with running make, Error 1

Post by Adam D. Helfer » July 19 2017

I am having a very similar problem trying to make CAMB in OSX/Sierra. I get

ld: library not found for -lSystem

(I've double-checked that X-Code is installed, updated and command-line tools are available.) Any help would be appreciated.
[/img]

Post Reply