← Back to team overview

dolfin team mailing list archive

Re: PETSC_ARCH

 

On Tue, Aug 17, 2010 at 07:46:27PM +0100, Garth N. Wells wrote:
> On Tue, 2010-08-17 at 20:31 +0200, Anders Logg wrote:
> > On Tue, Aug 17, 2010 at 06:59:13PM +0100, Garth N. Wells wrote:
> > > On Tue, 2010-08-17 at 19:51 +0200, Anders Logg wrote:
> > > > On Tue, Aug 17, 2010 at 07:17:29PM +0200, Anders Logg wrote:
> > > > > On Tue, Aug 17, 2010 at 07:06:43PM +0200, Anders Logg wrote:
> > > > > > On Tue, Aug 17, 2010 at 06:01:46PM +0100, Garth N. Wells wrote:
> > > > > > > On Tue, 2010-08-17 at 18:46 +0200, Anders Logg wrote:
> > > > > > > > Why do we need to set PETSC_ARCH? We didn't before. Is there a way to
> > > > > > > > figure it out?
> > > > > > > >
> > > > > > >
> > > > > > > In general, no. It's possible (and common) to have a debug and an
> > > > > > > optimised version installed side-by-side (there are more possibilities)
> > > > > > > than just optimised and debug). The libs go in
> > > > > > >
> > > > > > >   ${PETSC_DIR}/${PETSC_ARCH}/lib
> > > > > > >
> > > > > > > If you do a regular
> > > > > > >
> > > > > > >    ./configure --prefix=/foo/bar
> > > > > > >
> > > > > > > then I don't think that it's required since there will be not
> > > > > > > distinction between a debug and an optimised version.
> > > > > >
> > > > > > There seems to be some code for searching for PETSC_ARCH in the
> > > > > > FindPETSc script:
> > > > > >
> > > > > > set (_petsc_arches
> > > > > >     $ENV{PETSC_ARCH}                   # If set, use environment
> > > > > >     variable first
> > > > > >     ${DEBIAN_FLAVORS}  # Debian defaults
> > > > > >     x86_64-unknown-linux-gnu i386-unknown-linux-gnu)
> > > > > >
> > > > > > But it doesn't include the following two options that we have in the
> > > > > > old Scons script:
> > > > > >
> > > > > > elif os.path.exists(getPetscDir(sconsEnv=sconsEnv)+"/linux-gnu-c-opt"):
> > > > > >         return "linux-gnu-c-opt"
> > > > > > elif os.path.exists(getPetscDir(sconsEnv=sconsEnv)+"/lib/linux-gnu-c-opt"):
> > > > > >         return "linux-gnu-c-opt"
> > > > >
> > > > > I see now these two are included in debian_arches.
> > > >
> > > > I don't have a regular PETSC_DIR but rather an installed version of
> > > > PETSc (installed by Dorsal). It looks like it should work anyway since
> > > > then PETSC_ARCH can be empty and the following test will still find
> > > > petsconf.h in $prefix/include:
> > > >
> > >
> > > There is a lot to check - there were changes from PETSc 3.0 to PETSc
> > > 3.1.
> >
> > Where does the PETSc conf file come from? Did you write it or copy it
> > from somewhere?
>
> >From Jed Brown. I made some small changes for 3.1.
>
> > It's quite big and difficult to follow.
> >
>
> Tell me about it!
>
> Garth

Does it need to be that complicated?

It seems fine up until the point where it has looked for PETSC_DIR and
PETSC_ARCH. Then begins a bunch of complex tests.

--
Anders

Attachment: signature.asc
Description: Digital signature


References