From: Wolfgang Bangerth Date: Wed, 8 Apr 2015 12:09:32 +0000 (-0500) Subject: Adjust p4est interface. X-Git-Tag: v8.3.0-rc1~309^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f764598cb4577749ab60632d817c3734d67b126c;p=dealii.git Adjust p4est interface. The p4est_connectivity_load function used to take an unsigned long as argument, but this has been changed to size_t in p4est 1.0. This makes no difference on 64 bit systems, but leads to compiler errors on 32 bit systems. Fix this. --- diff --git a/doc/news/changes.h b/doc/news/changes.h index 6cc62c39aa..88acfbe755 100644 --- a/doc/news/changes.h +++ b/doc/news/changes.h @@ -410,6 +410,12 @@ inconvenience this causes.

Specific improvements

    +
  1. Fixed: deal.II did not compile on 32-bit systems when using newer + p4est versions (1.0 and later) due to a type mismatch. This is now fixed. +
    + (Wolfgang Bangerth, 2015/04/08) +
  2. +
  3. Changed: In the spirit of the changes made to the distinction between Point and Tensor objects discussed above, the first argument to GridTools::shift() has been changed from a Point to a Tensor@<1,dim@>. diff --git a/source/distributed/tria.cc b/source/distributed/tria.cc index 32d0d9d4a3..f56143f2f2 100644 --- a/source/distributed/tria.cc +++ b/source/distributed/tria.cc @@ -1,6 +1,6 @@ // --------------------------------------------------------------------- // -// Copyright (C) 2008 - 2014 by the deal.II authors +// Copyright (C) 2008 - 2015 by the deal.II authors // // This file is part of the deal.II library. // @@ -204,7 +204,11 @@ namespace internal static int (&connectivity_is_valid) (types<2>::connectivity *connectivity); -#if DEAL_II_P4EST_VERSION_GTE(0,3,4,3) +#if DEAL_II_P4EST_VERSION_GTE(1,0,0,0) + static + types<2>::connectivity *(&connectivity_load) (const char *filename, + size_t *length); +#elif DEAL_II_P4EST_VERSION_GTE(0,3,4,3) static types<2>::connectivity *(&connectivity_load) (const char *filename, long unsigned *length); @@ -384,7 +388,12 @@ namespace internal *connectivity) = p4est_connectivity_is_valid; -#if DEAL_II_P4EST_VERSION_GTE(0,3,4,3) +#if DEAL_II_P4EST_VERSION_GTE(1,0,0,0) + types<2>::connectivity * + (&functions<2>::connectivity_load) (const char *filename, + size_t *length) + = p4est_connectivity_load; +#elif DEAL_II_P4EST_VERSION_GTE(0,3,4,3) types<2>::connectivity * (&functions<2>::connectivity_load) (const char *filename, long unsigned *length) @@ -564,7 +573,11 @@ namespace internal static int (&connectivity_is_valid) (types<3>::connectivity *connectivity); -#if DEAL_II_P4EST_VERSION_GTE(0,3,4,3) +#if DEAL_II_P4EST_VERSION_GTE(1,0,0,0) + static + types<3>::connectivity *(&connectivity_load) (const char *filename, + size_t *length); +#elif DEAL_II_P4EST_VERSION_GTE(0,3,4,3) static types<3>::connectivity *(&connectivity_load) (const char *filename, long unsigned *length); @@ -747,7 +760,12 @@ namespace internal *connectivity) = p8est_connectivity_is_valid; -#if DEAL_II_P4EST_VERSION_GTE(0,3,4,3) +#if DEAL_II_P4EST_VERSION_GTE(1,0,0,0) + types<3>::connectivity * + (&functions<3>::connectivity_load) (const char *filename, + size_t *length) + = p8est_connectivity_load; +#elif DEAL_II_P4EST_VERSION_GTE(0,3,4,3) types<3>::connectivity * (&functions<3>::connectivity_load) (const char *filename, long unsigned *length)