4

I just installed the PETSc library. This is what I did from the home directory ~

gunzip -c petsc-3.2-p6.tar.gz|tar -xof -
cd ~/petsc-3.2-p6
PETC_DIR=$PWD: export PETSC_DIR
./configure --download-f-blas-lapack=1
make all
make PETSC_DIR=/export/home/myusername/petsc-3.2-p6 PETSC_ARCH=arch-linux2-c-debug test

(note: I did not install mpich since it was already installed on the system)
Then, I tried to run an example from the following this tutorial, slide 46 of 197, which asks me to do the following:

cd ~/petsc-3.2-p6/src/snes/examples/tutorials
make ex5

In the process, I get the following errors:

makefile:24: /conf/variables: No such file or directory
makefile:24: /conf/rules: No such file or directory
makefile:24: /conf/test: No such file or directory

Is the problem in the way I setup PETSc? Or is there something I need to modify in the makefile?

Jack Poulson
  • 7,599
  • 32
  • 40
Paul
  • 12,045
  • 7
  • 56
  • 129

1 Answers1

6

You most likely haven't set the PETSC_DIR and PETSC_ARCH environment variables correctly.

For instance, you misspelled PETSC_DIR as PETC_DIR in the third line of your build example.

Peter Brune
  • 1,675
  • 12
  • 20
  • Sometimes, the simplest mistakes are often the hardest to see on your own! :) Thanks for the help. I got got it to work now. – Paul Jan 20 '12 at 20:10