CosmoCoffee Forum Index CosmoCoffee

 FAQFAQ   SearchSearch  MemberlistSmartFeed   MemberlistMemberlist    RegisterRegister 
   ProfileProfile   Log inLog in 
Arxiv New Filter | Bookmarks & clubs | Arxiv ref/author:

Installing CAMB on Sierra
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software
View previous topic :: View next topic  
Author Message
Damian Sowinski

Joined: 14 Feb 2017
Posts: 1
Affiliation: University of Wisconsin, Madison

PostPosted: February 24 2017  Reply with quote

I'm having problems with getting CAMB working on Sierra.

First off, I have the latest version of gfortran installed
GNU Fortran (GCC) 6.3.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO

The latest version of pyCAMB says that it fixed the compilation issue with 6.3, but theres another post ( where someone was having problems with 6.3.

When I run from inside the camb/pycamb folder:
sudo python install --user
I get the following error:
mkdir -p Releaselib
gfortran -shared -fPIC -O3 -fopenmp -ffast-math -fmax-errors=4 -JReleaselib -IReleaselib/ -c constants.f90 -o Releaselib/constants.o
FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!

Running through the code, I see that the starts the subprocess "make".
That ends up running Makefile, which gets to the end and starts running Makefile_main.
When gfortran ($(F90C)) is called in the line ,
$(DLL_DIR)/%.o: %.f90
   $(F90C) $(SF90FLAGS) -c $*.f90 -o $(DLL_DIR)/$*.o

the error pops up.

If anyone know why this is happening, please let me know.
After trying to get around this I finally took Caldwell's advice and installed gfortran v5.3.
Running no longer pops us the 'm' flag error, but now I get a strange:
gfortran -dynamiclib -fPIC -O3 -fopenmp -ffast-math -fmax-errors=4 -JReleaselib -IReleaselib/ -c utils.F90 -o Releaselib/utils.o
/var/tmp//ccijfDb9.s:9224:suffix or operands invalid for `movq'
/var/tmp//ccijfDb9.s:9328:suffix or operands invalid for `movq'
make: *** [Releaselib/utils.o] Error 1

looking a the traceback, the problem appears to be in the file:

SystemExit                                Traceback (most recent call last)
/opt/local/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/IPython/utils/ in execfile(fname, glob, loc, compiler)
    184         with open(fname, 'rb') as f:
    185             compiler = compiler or compile
--> 186             exec(compiler(, fname, 'exec'), glob, loc)
    188     # Refactor print statements in doctests.

/Users/Omnius/Desktop/CAMB-Jan2017/pycamb/ in <module>()
    122       packages=['camb', 'camb_tests'],
    123       package_data={'camb': [DLLNAME, 'HighLExtrapTemplate_lenspotentialCls.dat']},
--> 124       test_suite='camb_tests',
    125       classifiers=['Programming Language :: Python :: 2','Programming Language :: Python :: 2.7','Programming Language :: Python :: 3','Programming Language :: Python :: 3.4','Programming Language :: Python :: 3.5'],
    126       keywords=['cosmology', 'CAMB'],

/opt/local/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/distutils/ in setup(**attrs)
    146     if ok:
    147         try:
--> 148             dist.run_commands()
    149         except KeyboardInterrupt:
    150             raise SystemExit("interrupted")

/opt/local/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/distutils/ in run_commands(self)
    953         """
    954         for cmd in self.commands:
--> 955             self.run_command(cmd)
    957     # -- Methods that operate on its Commands --------------------------

/opt/local/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/distutils/ in run_command(self, command)
    972         cmd_obj = self.get_command_obj(command)
    973         cmd_obj.ensure_finalized()
--> 974
    975         self.have_run[command] = 1

/Users/Omnius/Desktop/CAMB-Jan2017/pycamb/ in run(self)
     97   "make", shell=True)
     98             print(" end make")
---> 99             if not osp.isfile(os.path.join('Releaselib', '')): sys.exit('Compilation failed')
    100             print(" chmod 755 Releaselib/")
    101   "chmod 755 Releaselib/", shell=True)

SystemExit: Compilation failed

At this point I gave up.
If anyone can help with either the prior issue or the present one, that would be great.[url][/url]
Back to top
View user's profile [ Hidden ]
Antony Lewis

Joined: 23 Sep 2004
Posts: 1351
Affiliation: University of Sussex

PostPosted: February 24 2017  Reply with quote

As with that post, it's probably an issue with your gfortran/gcc/ports installation, e.g. cf

If you have problems I'd just compile and run it in one of the CosmoBox virtual environments instead.
Back to top
View user's profile [ Hidden ] Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software All times are GMT + 5 Hours
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2001, 2005 phpBB Group. Sponsored by WordWeb online dictionary and dictionary software.