astrojuanlu / fenics-recipes

This repository contains conda recipes for the FEniCS libraries
The Unlicense
13 stars 15 forks source link

Compilation of ``petsc`` fails on centos 6. #54

Open RafalSkolasinski opened 8 years ago

RafalSkolasinski commented 8 years ago

I forked master branch to try a custom build. The only difference I made was to remove limitation on numpy version and enforcing libgfortran ==1 to workaround current problems with libgfortran on conda. (see #686).

The following problem occurs during configuration of petsc installation

TESTING: checkCLibraries from config.compilers(/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/compilers.py:164)
*******************************************************************************
         UNABLE to CONFIGURE with GIVEN OPTIONS    (see configure.log for details):
-------------------------------------------------------------------------------
C libraries cannot directly be used from Fortran

message from configure.log

*******************************************************************************
         UNABLE to CONFIGURE with GIVEN OPTIONS    (see configure.log for details):
-------------------------------------------------------------------------------
C libraries cannot directly be used from Fortran
*******************************************************************************
  File "./config/configure.py", line 363, in petsc_configure
    framework.configure(out = sys.stdout)
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/framework.py", line 1081, in configure
    self.processChildren()
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/framework.py", line 1070, in processChildren
    self.serialEvaluation(self.childGraph)
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/framework.py", line 1051, in serialEvaluation
    child.configure()
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/compilers.py", line 1403, in configure
    self.executeTest(self.checkCLibraries)
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/base.py", line 126, in executeTest
    ret = test(*args,**kargs)
  File "/root/anaconda3/conda-bld/work/petsc-3.6.2/config/BuildSystem/config/compilers.py", line 307, in checkCLibraries
    raise RuntimeError('C libraries cannot directly be used from Fortran')
================================================================================
Finishing Configure Run at Tue Mar 15 12:07:59 2016
================================================================================
astrojuanlu commented 8 years ago

I've seen lots of problems with using Anaconda gcc and libgfortran. The problem is that not using it creates its own portability issues. Perhaps at some point the wrong compilers are used and it makes the compilation fail, I will try to diagnose the issue this week.

RafalSkolasinski commented 8 years ago

I somehow manage to make all packages (except mshr) compiling (under Centos 7) without setting

libgfortran ==1

didn't try Centos 6 again because we'll have a cluster update soon.

In my fork now I got an Centos 7 Dockerimage that does the compilation. Using output of it allows for successful installation under Centos 7 and Linux Mint 17.3 Rosa (Ubuntu 14.04 bases as I remember).

If you would have tips how to succeed in compilation of mshr you would be my hero ;)