PETSc

 

Developers Site


 

 These pages are for people interested in using the development copy of PETSc (called petsc-dev) or contributing to the PETSc libraries. It is intended only for people who are experienced with building, using and debugging PETSc. If you cannot use makefiles, a debugger and EMACS etags then please don't access these pages.

Consider joining petsc-dev mailing-list.

How to:


Browsing Source:

One can browse the development repositories at the following location

Obtaining the development version of PETSc:

You have two options
  1.  download and install mercurial
  2.  access the nightly tarball snapshot at ftp://info.mcs.anl.gov/pub/petsc/petsc-dev.tar.gz
  Both methods above create a local directory with the name petsc-dev.

1) To use mercurial - install the software from http://www.selenic.com/mercurial/wiki/index.cgi/Download [follow instructions provided]. We recommend using  mercurial-0.9.3 version or newer [avoid versions older than 0.9.0].  Obtain petsc-dev with the following:
  • hg clone http://petsc.cs.iit.edu/petsc/petsc-dev
  • cd petsc-dev/python
  • hg clone http://petsc.cs.iit.edu/petsc/BuildSystem BuildSystem
To update your copy of petsc-dev
  • make PETSC_ARCH=docsonly pull
 or
  • cd petsc-dev
  • hg pull
  • hg update
  • cd python/BuildSystem
  • hg pull
  • hg update
The Mercurial download always has the latest version of petsc-dev.

For additional help use
  • hg help  [or]
  • man hg
2) The nightly tarball will be equivalent to the release tarball - with all the doumentation built. To use the tarball snapshot, simply download ftp://info.mcs.anl.gov/pub/petsc/petsc-dev.tar.gz and extract it.
  • gunzip -c petsc-dev.tar.gz | tar xf  -
To update your copy of petsc-dev simply get a new copy of the tar file. The tar file at the ftp site is updated once each night with the latest changes to petsc-dev

Compiling and using the development copy (petsc-dev):

Use config/configure.py to install PETSc, (trouble, please contact us petsc-maint@mcs.anl.gov). And subscribe to petsc mailing lists.


Building documentation:

The documentation tools (except for pdflatex) are automatically downloaded and installed by config/configure.py. However, as a failsafe, we provide them here as well.

The following additional tools are required to build the PETSc documentation:

  • Sowing:  A text processing tools developed by Bill Gropp

  • C2html: A text processing package required to generate the PETSc documentation.

  • A version of pdflatex (for example in teTeX):This package might already be installed on most systems. It is required to generate the users manual (part of the PETSc documentation)

   Once pdflatex (from teTeX) is in your PATH you can build the documentation with:

  • make alldoc LOC=${PETSC_DIR}

Sending patches to update the master copy of petsc-dev:

One can send us changes to PETSc [perhaps bug fixes or new feature additions] via e-mail. One easy way to do this [if no new files get created] is:

  • [get the latest version of petsc-dev using mercurial as descrbed above]
  • [make edits]
  • hg diff > patchfile
  • [email patchfile to petsc-maint@mcs.anl.gov]
To undo the changes, one can do 'hg revert' so that subsequent 'hg pull' or 'make pull' will continue to work.

Alternatively - one can send us patches using 'hg bundle' as described at http://www.selenic.com/mercurial/wiki/index.cgi/CommunicatingChanges