On 8 January 2015 at 23:32, Juan Luis Cano <[email protected]> wrote: > Hello all, > > I am trying to build a conda package of PETSc 3.4 using its Python build > system so anybody can install it in the Anaconda Python distribution. I need > PETSc as a dependency for FEniCS. >
Nice to know! I was thinking about doing it myself. You may find interesting my mpich and openmpi packages (newer versions than the available in Anaconda) to depend on https://binstar.org/mpi4py, I still have to put the recipes in github repo. > The problem is that the required shared libraries (also those corresponding > to external packages such as UMFPACK) are installed in > $PREFIX/lib/python2.7/site-packages/petsc/lib. The build process goes > perfectly fine but when packaging this into a tarball these libs won't be > found by any package as they are not in $PREFIX/lib. Here is the build > script I am using: > Are you using pip to create/build the conda recipes? I really advice against that. You should create a petsc package that is independent of a Python runtime (of course, you still need Python to run configure), this way you can install in the standard $PREFIX location. Why do you say things are installed in site-packages? Who is installing there FEniCS ? Please note/remember that conda is not only for Python stuff, but for any other Python-independent package that install under a $PREFIX tree. > https://github.com/Juanlu001/conda-recipes/blob/juanlu001/fenics/petsc/build.sh > * Please remember to add the md5 hash under the source section. * python should not be a runtime dependency of the petsc package > I tried to change the destination using `--prefix` in > PETSC_CONFIGURE_OPTIONS and after `setup.py install`, but neither worked. > Changing LD_LIBRARY_PATH seems dangerous to me and creating symbolic links > three levels higher seems dirty. If the python version changes, or "lib64" > is added somewhere, this will surely break... Does anybody have a suggestion > on how to do this? > Knowing the full stack of conda packages you depend on would help to figure out your issue. -- Lisandro Dalcin ============ Research Scientist Computer, Electrical and Mathematical Sciences & Engineering (CEMSE) Numerical Porous Media Center (NumPor) King Abdullah University of Science and Technology (KAUST) http://numpor.kaust.edu.sa/ 4700 King Abdullah University of Science and Technology al-Khawarizmi Bldg (Bldg 1), Office # 4332 Thuwal 23955-6900, Kingdom of Saudi Arabia http://www.kaust.edu.sa Office Phone: +966 12 808-0459
