Docs: Installation |
![]() |
Example Usages:
Several variables control the configuration and build process of PETSc. They can either be given as arguments to make or be set as environment variables. PETSC_DIR: - this environment/make variable should point to the location of the PETSc installation that is used. You can add export PETSC_DIR=value in your .profile or .sh file or setenv PETSC_DIR value in your .cshrc or .tcshrc file. Multiple PETSc versions can coexist on the same file-system. By changing PETSC_DIR one can switch between the versions PETSC_ARCH: this environment/make variable is used to specify the configuration that should currently be used. It corresponds to the configuration files in bmake/${PETSC_ARCH}. Multiple variants of PETSc libraries can be installed - each variant corresponding to a different PETSC_ARCH. One can switch between using these variants - by changing the value of PETSC_ARCH. If PETSC_ARCH is not set, the configuration from the last time you ran ./config/configure.py will be used. Return to Installation Instructions Cygwin provides UNIX tools on Microsoft Windows. When installing Cygwin make sure you install the following additional packages
Cygwin also has GNU compilers ( gcc, g++, g77) which can be used if Microsoft, Intel, or Borland Group compilers are not availableNote: Previously we recommanded doing 'rebaseall' to
avoid
python problems. However 'rebaseall' has its own problems - so if there
any python issues, the current recommendation is to reinstall cygwin
from scratch.
Return to Installation Instructions BLAS/LAPACK: these packages provide some basic numeric kernels used by PETSc.
Return to Installation Instructions MPI: This software provides the parallel functionality for PETSc.
Return to Installation Instructions I don't want to use MPI: You can build (sequential) PETSc without an MPI. Run ./config/configure.py --with-mpi=0 ....Return to Installation Instructions Additional Microsoft Windows Notes:Microsoft Compilers: Use configure with the following
options to build for Microsoft C/C++ & Compaq Fortran [assuming
MPICH & Intel MLK are already installed in the default locations] If fortran usage is not required - and you don't have Intel
MLK - just use: If fortran usage is required [with Digital/Compaq f90
compiler] - and you don't have Intel
MLK - just use the following [assuming the path to compaq fortran
libraries is correct]: Note the usage of both single quotes and double quotes in the above line. Configure: --download-package option does not work with many external packages [for eg: mpich] Project Files: We
provide
templates for Microsoft Visual Studio project files at
${PETSC_DIR}/projects. These work for us - with our configure build
[config/cygwin-ms.py with MPICH1 and Intel MKL 5], However they will
REQURE MODIFICATIONS to work with a user build of PETSc - as the
locations of packages & configure options used by user could be
different from our defult build. To get these project files working for your installation of
PETSc, please do the following:
Debugger: Running PETSc probrams with -start_in_debugger is not supported on this platform, so debuggers will need to be initiated manually. Make sure your environment is properly configured to use the appropriate debugger for your compiler. The debuggers can be initiated using Microsoft Visual Studio 6: msdev ex1.exe, Microsoft Visual Studio .NET: devenv ex1.exe, Intel Enhanced Debugger: edb ex1.exe, or GNU Debugger gdb ex1.exe. PETSc Win32 front end - win32fe: This tool is used as a wrapper to Microsoft/ Borland/ Intel compilers and associated tools - to enable building PETSc libraries using make and other UNIX tools. For additional info, run ${PETSC_DIR}/bin/win32/win32fe without any options. Return to Installation Instructions Installing on machine requiring cross compiler or a job scheduler:If one has to use a cross compiler - or go through the job scheduler to use MPI on a
given machine - use the configure option '--with-batch=1' as follows:
Installing on IBM SP:To run any code compiled with MPI on IBM SP - one has to go through the job scheduler. [So follow the instructions from the above section 'Installing on machine requiring job scheduler']. Alternatively check/run config/aix5.1.0.0.py for all configure options required on the SP with compilers defaulting to 32bit mode, and config/aix5.1.0.0-64.py with compilers defaulting to 64bit mode.Installing on IBM Blue Gene:IBM Blue Gene [as of now] requires modified compiler script wrappers to compile PETSc-2.3.2. Please download ftp://ftp.mcs.anl.gov/pub/petsc/tmp/petsc-bgl-tools.tar.gz and follow instructions provided in the README file. Installing with TAU Instrumentation package:TAU
package and the prerequisite PDT
packages need to be installed separately. PETSc provides a wrapper
compiler for TAU. This needs to be invoked with the correct information
for the installed TAU and PDT packages. For eg: ./config/configure.py
--with-mpi-dir=/home/petsc/soft/linux-rh73/mpich-1.2.4 --with-fc=0 --with-cxx=0
-PETSC_ARCH=linux-tau -with-cpp=cpp --with-cc="`pwd`/bin/taucc.py
-cc=gcc
-pdt_parse=/homes/petsc/soft/linux-rh73/pdtoolkit-2.2b1/linux/bin/cxxparse
-tau_lib_dir=/homes/petsc/soft/linux-rh73/tau-2.11.18/i386_linux/lib" Installing TOPS components:To install TOPS components one has to download and
install CCA
Tools. [linux only]
Return
to Installation Instructions |