On Tue, Nov 16, 2010 at 11:58 AM, Srinath Vadlamani <span dir="ltr"><<a href="mailto:srinath@txcorp.com">srinath@txcorp.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
It seems now that petsc4py must be built during a petsc configure/build. Is this correct? I was hoping to install petsc4py in the same location as my other python builds, so that I only have to specify one location in my PYTHONPATH.</blockquote>
<div><br></div><div>I also prefer independent installs:</div><div><br></div><div> 1) Clone the petsc4py-dev repo</div><div><br></div><div> 2) make cython (you need Cython 0.13)</div><div><br></div><div> 3) python setup.py sdist</div>
<div><br></div><div> 4) pip install dist/petsc4py.*.tar.gz --install-option="--user"</div><div><br></div><div>which will install it under ~/.local. You can also omit the option to</div><div>install it in the default place.</div>
<div><br></div><div> Thanks,</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><>Srinath<br><br><div class="gmail_quote">
On Mon, Nov 15, 2010 at 2:11 PM, Barry Smith <span dir="ltr"><<a href="mailto:bsmith@mcs.anl.gov" target="_blank">bsmith@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
There (sadly) is not completely automatic way to do this. Cd to $PETSC_DIR/externalpackages; remove any petsc4py* directories from there; clone petsc4py-dev into that directory. cd back to $PETSC_DIR; now run ./configure --download-petsc4py<br>
<br>
It will not go and get a copy of petsc4py since the petsc4py-dev directory exists, rather it will use the one you have put there (by your clone).<br>
<br>
Note that petsc4py-dev may not always have been updated to the latest changes to petsc-dev, if you get errors in the build report them to <a href="mailto:petsc-maint@mcs.anl.gov" target="_blank">petsc-maint@mcs.anl.gov</a> and we'll update the petsc4py-dev; note that after an update of petsc4py-dev you should cd externalpackages/petsc4py-dev and hg pull; hg update to get the latest.<br>
<br>
Yes, someone should add proper support for ./configure to handle hg repositories from petsc-dev and do the pulls and updates automatically but that code has not been written, hence the manual process.<br>
<font color="#888888"><br>
Barry<br>
</font><div><div></div><div><br>
<br>
On Nov 15, 2010, at 3:00 PM, Srinath Vadlamani wrote:<br>
<br>
> How does one configure petsc-dev to build petsc4py-dev?<br>
> I cloned petsc4py-dev but it needs my petsc-dev complex install to have petsc4py symbols?<br>
><br>
> <>Srinath<br>
><br>
> 2010/11/15 Satish Balay <<a href="mailto:balay@mcs.anl.gov" target="_blank">balay@mcs.anl.gov</a>><br>
> [original e-mail didnt make it to the list due to the attached<br>
> configure.log. Huge attachments are prohibited on the mailing lists]<br>
><br>
><br>
> Using configure Options: --with-petsc-arch=real-par-debug --with-scalar-type=real --with-debugging=yes --with-debugger=totalview --download-superlu_dist=1 --download-mumps=1 --download-spooles=1 --with-shared=1 --download-blacs=1 --download-parmetis=1 --download-szip=1 --download-scalapack=1 --download-petsc4py --download-mpi4py --with-shared-libraries -prefix=/Users/srinath/software/petsc-dev-real-par<br>
><br>
><br>
> petsc4py listed in petsc4py.py is<br>
> <a href="http://petsc4py.googlecode.com/files/petsc4py-1.1.1.tar.gz" target="_blank">http://petsc4py.googlecode.com/files/petsc4py-1.1.1.tar.gz</a> Perhaps you<br>
> have to use petsc-4py-dev directly to get this working?<br>
><br>
> Lisandro will know..<br>
><br>
> Satish<br>
><br>
> On Mon, 15 Nov 2010, Srinath Vadlamani wrote:<br>
><br>
> > In file included from src/PETSc.c:3:<br>
> > src/petsc4py.PETSc.c: In function<br>
> > ‘__pyx_pf_8petsc4py_5PETSc_2IS_getBlockSize’:<br>
> > src/petsc4py.PETSc.c:49179: warning: implicit declaration of function<br>
> > ‘ISBlock’<br>
> > src/petsc4py.PETSc.c: In function ‘__pyx_pf_8petsc4py_5PETSc_2IS_getInfo’:<br>
> > src/petsc4py.PETSc.c:51132: warning: implicit declaration of function<br>
> > ‘ISStride’<br>
> > src/petsc4py.PETSc.c: In function ‘__pyx_pf_8petsc4py_5PETSc_3Mat_zeroRows’:<br>
> > src/petsc4py.PETSc.c:75725: error: too few arguments to function<br>
> > ‘MatZeroRowsIS’<br>
> > src/petsc4py.PETSc.c:75750: error: too few arguments to function<br>
> > ‘MatZeroRows’<br>
> > src/petsc4py.PETSc.c: In function<br>
> > ‘__pyx_pf_8petsc4py_5PETSc_3Mat_zeroRowsLocal’:<br>
> > src/petsc4py.PETSc.c:75872: error: too few arguments to function<br>
> > ‘MatZeroRowsLocalIS’<br>
> > src/petsc4py.PETSc.c:75897: error: too few arguments to function<br>
> > ‘MatZeroRowsLocal’<br>
> > src/petsc4py.PETSc.c: In function<br>
> > ‘__pyx_pf_8petsc4py_5PETSc_3KSP_setConvergenceTest’:<br>
> > src/petsc4py.PETSc.c:87471: error: ‘KSP_NORM_NO’ undeclared (first use in<br>
> > this function)<br>
> > src/petsc4py.PETSc.c:87471: error: (Each undeclared identifier is reported<br>
> > only once<br>
> > src/petsc4py.PETSc.c:87471: error: for each function it appears in.)<br>
> > src/petsc4py.PETSc.c: In function<br>
> > ‘__pyx_pf_8petsc4py_5PETSc_3KSP_getNormType’:<br>
> > src/petsc4py.PETSc.c:88847: error: ‘KSP_NORM_NO’ undeclared (first use in<br>
> > this function)<br>
> > src/petsc4py.PETSc.c: In function ‘initPETSc’:<br>
> > src/petsc4py.PETSc.c:131697: error: ‘KSP_NORM_NO’ undeclared (first use in<br>
> > this function)<br>
> > error: command 'mpicc' failed with exit status 1<br>
> > make[1]: *** [petsc4py] Error 1<br>
> ><br>
> ><br>
> ><br>
> ><br>
><br>
><br>
><br>
> --<br>
> =========================<br>
> Srinath Vadlamani, PhD.<br>
> Tech-X Corp. Research Scientist<br>
> 5621 Arapahoe Ave. Suite A<br>
> Boulder, CO 80303<br>
> 303-996-2034<br>
> =========================<br>
><br>
<br>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div>=========================</div><font color="#666666">Srinath Vadlamani, PhD.</font><div><font color="#666666">Tech-X Corp. Research Scientist</font></div>
<div><font color="#666666">5621 Arapahoe Ave. Suite A</font></div><div><font color="#666666">Boulder, CO 80303</font></div><div><font color="#666666">303-996-2034</font></div><div>=========================</div><br>
</div>
</blockquote></div><br><br clear="all"><br>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener<br>