On Mon, 12 Mar 2012, Matthew Knepley wrote:

> 
> The makefiles are simple. Here is building an executable:

you need some addtional stuf..

include ${PETSC_DIR}/conf/variables
include ${PETSC_DIR}/conf/rules

> myProg: myProg.o otherSource.o anotherSource.o
>        ${CLINKER} -o myProg ${PETSC_TS_LIB}


attaching a sample makefile. Also its best to build petsc with option
--with-clanguage=cxx [if using from c++].

Satish
-------------- next part --------------

CFLAGS           =
FFLAGS           =
CPPFLAGS         =
FPPFLAGS         =
CLEANFILES       =

include ${PETSC_DIR}/conf/variables
include ${PETSC_DIR}/conf/rules

ex1: ex1.o  chkopts
        -${CLINKER} -o ex1 ex1.o  ${PETSC_LIB}
        ${RM} ex1.o

Reply via email to