1) Make sure you have updated BuildSystem: cd $PETSC_DIR/config/BuildSystem hg pull -u
2) Reconfigure and rebuild 3) If its still broken, send configure.log to petsc-maint at mcs.anl.gov Matt On Thu, Jul 5, 2012 at 3:02 PM, hbui <hgbk2008 at gmail.com> wrote: > Hi > > When compiling a small petsc example, i got an error as such: > > ------------------------------**------------------------------** > -------------------------- > In file included from /opt/petsc/petsc-dev/include/**petscis.h:8:0, > from /opt/petsc/petsc-dev/include/**petscvec.h:9, > from /opt/petsc/petsc-dev/include/**petscmat.h:6, > from /opt/petsc/petsc-dev/include/**petscdm.h:6, > from /opt/petsc/petsc-dev/include/**petscpc.h:6, > from /opt/petsc/petsc-dev/include/**petscksp.h:6, > from ../PETScSolver.h:14, > from ../PETScSolver.cpp:8: > /opt/petsc/petsc-dev/include/**petscsf.h:69:119: error: 'MPI_Win' has not > been declared > /opt/petsc/petsc-dev/include/**petscsf.h:70:80: error: 'MPI_Win' has not > been declared > /opt/petsc/petsc-dev/include/**petscsf.h:71:105: error: 'MPI_Win' has not > been declared > In file included from /opt/petsc/petsc-dev/include/**petscvec.h:482:0, > from /opt/petsc/petsc-dev/include/**petscmat.h:6, > from /opt/petsc/petsc-dev/include/**petscdm.h:6, > from /opt/petsc/petsc-dev/include/**petscpc.h:6, > from /opt/petsc/petsc-dev/include/**petscksp.h:6, > from ../PETScSolver.h:14, > from ../PETScSolver.cpp:8: > /opt/petsc/petsc-dev/include/**petsc-private/vecimpl.h:498:3: error: > 'MPI_Win' does not name a type > ------------------------------**------------------------------** > -------------------------- > > I search over the mailing list and see a post which related to this error > but i didn't quite understand the answer and the user has also discontinued > the thread. > http://lists.mcs.anl.gov/**pipermail/petsc-dev/2011-**November/006227.html<http://lists.mcs.anl.gov/pipermail/petsc-dev/2011-November/006227.html> > > I tried to trace back the definition of MPI_Win struct and see as below: > > #ifndef PETSC_HAVE_MPI_WIN_CREATE > #define PETSC_HAVE_MPI_WIN_CREATE 1 > #endif > > #if !defined(PETSC_HAVE_MPI_WIN_**CREATE) /* The intent here is to be > able to compile even without a complete MPI. */ > typedef struct MPI_Win_MISSING *MPI_Win; > #endif > > For some reason the ./configure define PETSC_HAVE_MPI_WIN_CREATE and > compiler skip the MPI_Win definition. However, i also don't know where the > struct MPI_Win_MISSING is defined. > > Please advise the method to resolve this compilation error. > > My system is Ubuntu 12.04, Gcc 4.6.3. > > Regards, > Giang Bui > > -- 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120705/f744c4ef/attachment.html>
