source: issm/trunk-jpl/externalpackages/petsc/install-dev-pleiades.sh@ 12609

Last change on this file since 12609 was 12609, checked in by habbalf, 13 years ago

PETSc dev install for Pleiades. Follow steps 1-3. Steps maybe a bit redundant but it works so far

  • Property svn:executable set to *
File size: 3.5 KB
Line 
1#!/bin/bash
2#Step 0: download
3#Step 1: install before plapack crasehs
4#Step 2: After Plapack implodes
5STEP=0
6
7if [ $STEP -eq 0 ]; then
8 # Adapted from petsc 3.2.
9 # Used Mercurial to get code
10 rm -rf src
11 hg clone http://petsc.cs.iit.edu/petsc/petsc-dev src
12 cd src
13 hg clone http://petsc.cs.iit.edu/petsc/BuildSystem config/BuildSystem
14fi
15
16# To update (via Mercurial):
17# cd petsc-dev
18# hg pull -u
19# cd config/BuildSystem
20# hg pull -u
21
22
23# configure script
24# Note: using metis from externalpackages did not work...
25# for now downloading new metis
26# -then rename metis in externalpackages to metis2
27if [ $STEP -eq 1 ]; then
28
29 mkdir install
30
31 #configure
32 cd src
33 ./config/configure.py \
34 --prefix="$ISSM_DIR/externalpackages/petsc/install" \
35 --with-batch=1 \
36 --PETSC_ARCH="$ISSM_ARCH" \
37 --PETSC_DIR="$ISSM_DIR/externalpackages/petsc/src" \
38 --with-debugging=0 \
39 --with-shared-libraries=0 \
40 --with-blas-lapack-dir=/nasa/intel/mkl/10.0.011/ \
41 --known-mpi-shared-libraries=1 \
42 --with-mpi-lib=/nasa/sgi/mpt/2.04/lib/libmpi.so \
43 --with-mpi-include=/nasa/sgi/mpt/2.04/include \
44 --download-mumps=yes \
45 --download-plapack=yes \
46 --download-scalapack=yes \
47 --download-blacs=yes \
48 --download-blas=yes \
49 --download-f-blas-lapack=yes \
50 --download-parmetis=yes \
51 --download-metis=yes \
52 --download-trilinos=yes \
53 --download-euclid=yes \
54 --download-pastix=yes \
55 --download-ptscotch=yes \
56 --download-spooles=yes \
57 --download-spai=yes \
58 --download-superlu=http://crd.lbl.gov/~xiaoye/SuperLU/superlu_4.3.tar.gz \
59 --FFLAGS=-I/usr/include \
60 --with-cc=icc \
61 --with-fc=ifort \
62 --COPTFLAGS=" -O3 -xS" \
63 --FOPTFLAGS=" -O3 -xS" \
64 --CXXOPTFLAGS=" -O3 -xS" \
65 --with-pic=1
66 echo "== Fix Plapack compilation manually (http://issm.jpl.nasa.gov/documentation/faq/petsc32/) =="
67 echo "== Then run STEP=2 =="
68fi
69if [ $STEP -eq 2 ]; then
70 cd src
71 ./config/configure.py \
72 --prefix="$ISSM_DIR/externalpackages/petsc/install" \
73 --with-batch=1 \
74 --PETSC_ARCH="$ISSM_ARCH" \
75 --PETSC_DIR="$ISSM_DIR/externalpackages/petsc/src" \
76 --with-debugging=0 \
77 --with-shared-libraries=0 \
78 --with-blas-lapack-dir=/nasa/intel/mkl/10.0.011/ \
79 --with-mpi-lib=/nasa/sgi/mpt/2.04/lib/libmpi.so \
80 --with-mpi-include=/nasa/sgi/mpt/2.04/include \
81 --known-mpi-shared-libraries=1 \
82 --download-mumps=yes \
83 --download-scalapack=yes \
84 --download-blacs=yes \
85 --download-blas=yes \
86 --with-f-blas-lapack-dir=$ISSM_DIR/externalpackages/petsc/src/$ISSM_ARCH \
87 --download-parmetis=yes \
88 --download-metis=yes \
89 --with-cxx=icpc \
90 --download-hypre=yes \
91 --download-trilinos=yes \
92 --download-prometheus=yes \
93 --download-euclid=yes \
94 --download-pastix=yes \
95 --download-ptscotch=yes \
96 --download-spooles=yes \
97 --download-superlu=http://crd.lbl.gov/~xiaoye/SuperLU/superlu_4.3.tar.gz \
98 --with-spai-dir=$ISSM_DIR/externalpackages/petsc/src/$ISSM_ARCH \
99 --with-plapack-dir=$ISSM_DIR/externalpackages/petsc/src/$ISSM_ARCH \
100 --FFLAGS=-I/usr/include \
101 --with-cc=icc \
102 --with-fc=ifort \
103 --COPTFLAGS=" -O3 -xS" \
104 --FOPTFLAGS=" -O3 -xS" \
105 --CXXOPTFLAGS=" -O3 -xS" \
106 --with-pic=1
107 cat > script.queue << EOF
108#PBS -S /bin/bash
109#PBS -q debug
110#PBS -l select=1:ncpus=1:model=har
111#PBS -l walltime=200
112#PBS -W group_list=s1010
113#PBS -m e
114. /usr/share/modules/init/bash
115module load comp-intel/11.1.046
116module load mpi-sgi/mpt.2.04 #DEFINES MPI_Type_create_indexed_block
117module load math/intel_mkl_64_10.0.011
118export PATH="$PATH:."
119export MPI_GROUP_MAX=64
120mpiexec -np 1 ./conftest-linux-gnu-ia64-intel.py
121EOF
122 echo "== Follow PETSc's instructions"
123fi
Note: See TracBrowser for help on using the repository browser.