[petsc-users] undefined reference error in make test

Satish Balay balay at mcs.anl.gov
Fri Jan 15 00:35:09 CST 2016


Matt already responded to this. You should be using VecSet() - not VectorSet().
I'm not sure where you got VectorSet() from...

> > http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Vec/VecSet.html

Satish

On Fri, 15 Jan 2016, praveen kumar wrote:

> I’m struggling to figure out *undefined reference to `vectorset_*. I’ve
> included both  petscvec.h and petscvec.h90 but the error appears again.
> I’m attaching makefile and code. any help will be appreciated.
> 
> On Thu, Jan 14, 2016 at 9:39 PM, Matthew Knepley <knepley at gmail.com> wrote:
> 
> > On Thu, Jan 14, 2016 at 12:03 AM, praveen kumar <praveenpetsc at gmail.com>
> > wrote:
> >
> >> I’ve written a fortan code (F90)  for domain decomposition.* I've
> >> specified **the paths of include files and libraries, but the
> >> compiler/linker still *
> >>
> >>
> >> *complained about undefined references.undefined reference to
> >> `vectorset_'*
> >>
> >
> > http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Vec/VecSet.html
> >
> >
> >>
> >> *undefined reference to `dmdagetlocalinfo_'*
> >>
> >
> > This function is not supported in Fortran since it takes a structure.
> >
> >   Thanks,
> >
> >     Matt
> >
> >
> >> I’m attaching makefile and code. any help will be appreciated.
> >>
> >
> >
> >
> > --
> > What most experimenters take for granted before they begin their
> > experiments is infinitely more interesting than any results to which their
> > experiments lead.
> > -- Norbert Wiener
> >
> 


More information about the petsc-users mailing list