astrojuanlu / fenics-recipes

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

Installing fenics into an existing conda environment: libcppunit #18

Closed WilliamPJSmith closed 9 years ago

WilliamPJSmith commented 9 years ago

Hi Juanlu,

I would like to use your recipe to install FEniCS into an existing miniconda environment. This environment is designed to support a program called cellmodeller, which has its own python command cmpython. cmpython behaves like system python, but has all of its dependencies placed in a miniconda environment, stored under $HOME/miniconda.

To install, I tried

$ $HOME/miniconda/bin/conda install fenics --channel juanlu001

Which installs without complaint. However, when I tried to import dolphin from cmpython, I got the error

$ cmpython -c “from dolfin import * ”

ImportError: libboost_filesystem.so.1.55.0: cannot open shared object file: No such file or directory.

I solved this using the fix listed at https://github.com/Juanlu001/fenics-recipes/issues/8:

$ $HOME/miniconda/bin/conda install "boost=1.55" --channel juanlu001

which solves the boost problem, but gives a different error:

$ cmpython -c “from dolfin import *”

ImportError: libcppunit-1.13.so.0: cannot open shared object file: No such file or directory

Do you have any ideas on how to fix this? Many thanks,

Will

WilliamPJSmith commented 9 years ago

PS: to solve this, I also tried creating a new conda environment inside the original, and installing fenics in the inner environment, as per this recommendation: https://github.com/Juanlu001/fenics-recipes/issues/8

$ $HOME/miniconda/bin/conda create -n fenics27 python=2.7 ipython=2.2 $ source $HOME/miniconda/bin/activate fenics27 (fenics27)$ conda install fenics --channel juanlu001

unfortunately, the installation isn’t visible to cmpython:

(fenics27)$ cmpython -c “from dolfin import *”

ImportError: No module named dolfin

nor does this fix work for regular python (same problem as before):

(fenics27)$ python -c “from dolfin import *”

ImportError: libcppunit-1.13.so.0: cannot open shared object file: No such file or directory

Hope this is useful. W

astrojuanlu commented 9 years ago

Hello @WilliamPJSmith, thanks for the bug report and sorry for the delay. I suspect that your Linux system is too old for this version of libcppunit (some old CentOS or Ubuntu?), so I suggest installing fenics 1.4.0 as explained in http://fenicsproject.org/download/installation_using_conda.html#importerror-lib64-libc-so-6-version-glibc-2-14-not-found. If everything works this way I will close the issue.

astrojuanlu commented 9 years ago

Feedback needed, please reopen if error persists.