unable to find include files during make
Barry Smith
bsmith at mcs.anl.gov
Thu Nov 30 08:31:10 CST 2006
Ben,
You need also to have ${PETSC_FC_INCLUDES} which is
defined in ${PETSC_DIR}/bmake/common/variables so if you are
using the
include ${PETSC_DIR}/bmake/common/base
in your makefile you need only add ${PETSC_FC_INCLUDES} to
your opt. If you are NOT using the inclusion of PETSc common/base
it gets more complicated you will need something like
-I${PETSC_DIR} -I${PETSC_DIR}/bmake/${PETSC_ARCH} -I${PETSC_DIR}/include
added to the opt.
Barry
On Thu, 30 Nov 2006, Ben Tay wrote:
> hi,
>
> i've managed to compile petsc on my sch's linux server. i've done both the
> shared and non-shared libraries. test examples worked fine. however when i
> tried to compile my own code which uses petsc in one of the module, it says
> "can't find include file..... (all include files)".
>
> my petsc_dir/petsc arch has already been set. i'm using intel fortran 7
> (ifc) with gcc, because i get the error msg "Fortran libraries cannot be
> used with C compiler" when i tried ifc with icc. is there anyway to get
> around this?
>
> anyway, how should my makefile be? currently my makefile for the petsc
> solver is
>
> petsc_sub.o : petsc_sub.F
>
> $(f90) $(opt) petsc_sub.F
> if i compiled as shared libraries, what other statements must i add? the
> current opt are
>
> -r8 -ip -w95 -c -static-libcxa -L/nas/lsftmp/g0306332/petsc-2.3.2-p6/
>
>
> thank you very much
>
> regards
>
More information about the petsc-users
mailing list