Commits

Lisandro Dalcin committed 2e28383

Update after private header reorganization in petsc-dev

  • Participants
  • Parent commits 07a2d54

Comments (0)

Files changed (7)

File include/petiga.h

 */
 
 #include <petsc.h>
+#include <petsc-private/petscimpl.h>
 #include <petscts2.h>
 
 #if PETSC_VERSION_(3,2,0)

File src/petiga.c

 #ifndef PETSC_USE_DYNAMIC_LIBRARIES
   ierr = IGAInitializePackage(PETSC_NULL);CHKERRQ(ierr);
 #endif
+#if !defined(PETSC_VERSION_LE) || PETSC_VERSION_LE(3,3,0)
   ierr = PetscHeaderCreate(iga,_p_IGA,struct _IGAOps,IGA_CLASSID,-1,
                            "IGA","IGA","IGA",comm,IGADestroy,IGAView);CHKERRQ(ierr);
+#else
+  ierr = PetscHeaderCreate(iga,_p_IGA,struct _IGAOps,IGA_CLASSID,
+                           "IGA","IGA","IGA",comm,IGADestroy,IGAView);CHKERRQ(ierr);
+#endif
+
   *_iga = iga;
 
   ierr = PetscNew(struct _IGAUserOps,&iga->userops);CHKERRQ(ierr);

File src/petigagrid.c

 #include "petigagrid.h"
+#include <petsc-private/petscimpl.h>
 
 #undef  __FUNCT__
 #define __FUNCT__ "IGA_Grid_Create"

File src/petigaio.c

   PetscMPIInt    i,rank,size,tag;
   int            fd;
   PetscInt       n;
+  const PetscInt *range;
   PetscScalar    *array,*work;
   PetscErrorCode ierr;
   PetscFunctionBegin;
   if (!rank) {
     ierr = PetscBinaryRead(fd,array,n,PETSC_SCALAR);CHKERRQ(ierr);
     if (size > 1) {
-      const PetscInt *range = vec->map->range; /* XXX */
+      ierr = VecGetOwnershipRanges(vec,&range);CHKERRQ(ierr);
       n = 1;
       for (i=1; i<size; i++)
         n = PetscMax(n,range[i+1] - range[i]);

File src/petigapart.c

 #include "petigapart.h"
+#include <petsc-private/petscimpl.h>
 
 PETSC_STATIC_INLINE
 PetscInt IGA_CUT2D(PetscInt M,PetscInt N,

File src/petigavec.c

 #include "petiga.h"
+#include <petsc-private/vecimpl.h>
 
 EXTERN_C_BEGIN
 extern PetscErrorCode  VecView_MPI_DA(Vec,PetscViewer);

File src/snesfdcolor.c

 #include <petscsnes.h>
+#include <petsc-private/petscimpl.h>
 
 #undef __FUNCT__
 #define __FUNCT__ "MatFDColoringSetOptionsPrefix"