Commit 56a0c660 authored by Timo Koch's avatar Timo Koch
Browse files

Merge branch 'cleanup/unify-guards-for-uggrid' into 'master'

Resolve "Unify guards for uggrid"

Closes #1043

See merge request !2676
parents 42d1e23e 0e1233b4
Pipeline #5151 passed with stage
in 24 seconds
......@@ -31,12 +31,12 @@
// (https://gitlab.dune-project.org/core/dune-grid/issues/78),
// it should be guarded by a DUNE_VERSION macro and removed later.
#if HAVE_UG
#if HAVE_DUNE_UGGRID
namespace Dune {
template<int dim>
class UGGrid;
} // end namespace Dumux
#endif // HAVE_UG
#endif // HAVE_DUNE_UGGRID
namespace Dumux::Temp::Capabilities {
......@@ -46,13 +46,13 @@ struct canCommunicate
static const bool v = false;
};
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<int dim, int codim>
struct canCommunicate<Dune::UGGrid<dim>, codim>
{
static const bool v = true;
};
#endif // HAVE_UG
#endif // HAVE_DUNE_UGGRID
} // namespace Dumux::Temp::Capabilities
// end workaround
......
......@@ -34,7 +34,7 @@
#include <dune/grid/common/datahandleif.hh>
// UGGrid specific includes
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......@@ -124,7 +124,7 @@ private:
mutable std::map< typename IdSet::IdType, typename Data::value_type> data_;
};
#if HAVE_UG
#if HAVE_DUNE_UGGRID
/*!
* \ingroup InputOutput
......@@ -202,7 +202,7 @@ private:
mutable std::map< typename IdSet::IdType, typename Data::value_type> data_;
};
#endif // HAVE_UG
#endif // HAVE_DUNE_UGGRID
} // namespace Dumux
......
......@@ -37,7 +37,7 @@
#include <dumux/io/vtk/vtkreader.hh>
// UGGrid specific includes
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......@@ -50,7 +50,7 @@ namespace Detail {
template<class Grid>
struct isUG : public std::false_type {};
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<int dim>
struct isUG<Dune::UGGrid<dim>> : public std::true_type {};
#endif
......
......@@ -24,7 +24,7 @@
#ifndef DUMUX_IO_GRID_MANAGER_UG_HH
#define DUMUX_IO_GRID_MANAGER_UG_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#include <dune/grid/io/file/dgfparser/dgfug.hh>
#endif
......@@ -35,7 +35,7 @@
namespace Dumux {
#if HAVE_UG
#if HAVE_DUNE_UGGRID
/*!
* \ingroup InputOutput
......@@ -175,7 +175,7 @@ private:
}
};
#endif // HAVE_UG
#endif // HAVE_DUNE_UGGRID
} // end namespace Dumux
......
......@@ -34,7 +34,7 @@
#if HAVE_DUNE_ALUGRID
#include <dune/alugrid/grid.hh>
#endif
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......@@ -78,7 +78,7 @@ struct GridImp<Dune::ALUGrid<dim, dim, Dune::cube, Dune::nonconforming>, dim>
};
#endif
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<int dim>
struct GridImp<Dune::UGGrid<dim>, dim>
{
......
......@@ -23,7 +23,7 @@
#include <dumux/freeflow/shallowwater/model.hh>
#include <dumux/discretization/cctpfa.hh>
#include <dune/grid/yaspgrid.hh>
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......
......@@ -32,7 +32,7 @@
#include <dumux/io/grid/gridmanager.hh>
#include <dumux/io/grid/cakegridmanager.hh>
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......@@ -45,7 +45,7 @@
#endif
// The grid type
#if HAVE_UG && USEUG==1
#if HAVE_DUNE_UGGRID && USEUG==1
template<int dim>
using Grid = Dune::UGGrid<dim>;
#elif HAVE_DUNE_ALUGRID
......
dumux_add_test(NAME test_md_embedded_1d3d_1p2c_richards2c
LABELS multidomain multidomain_embedded 1pnc richardsnc
SOURCES main.cc
CMAKE_GUARD "( dune-foamgrid_FOUND AND HAVE_UG )"
CMAKE_GUARD "( dune-foamgrid_FOUND AND dune-uggrid_FOUND )"
TIMEOUT 1500
COMMAND ${CMAKE_SOURCE_DIR}/bin/testing/runtest.py
CMD_ARGS --script fuzzy
......
......@@ -55,7 +55,7 @@ struct Soil { using InheritsFrom = std::tuple<RichardsNC, CCTpfaModel>; };
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::Soil> { using type = Dune::UGGrid<3>; };
#else
......
......@@ -25,7 +25,7 @@
#define DUMUX_CONVERGENCE_TEST_ONEP_PROPERTIES_HH
#include <dune/grid/yaspgrid.hh>
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
......
......@@ -25,7 +25,7 @@
#ifndef DUMUX_INCOMPRESSIBLE_ONEP_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_INCOMPRESSIBLE_ONEP_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......
......@@ -25,7 +25,7 @@
#ifndef DUMUX_1P_SINGULARITY_PROBLEM_PROPERTIES_HH
#define DUMUX_1P_SINGULARITY_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......
......@@ -26,7 +26,7 @@
#ifndef DUMUX_1P2C_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P2C_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......@@ -58,7 +58,7 @@ struct OnePTwoCTestCCMpfa { using InheritsFrom = std::tuple<OnePTwoCTest, CCMpfa
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::OnePTwoCTest> { using type = Dune::UGGrid<2>; };
#else
......
......@@ -26,7 +26,7 @@
#ifndef DUMUX_1P2CNI_CONDUCTION_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P2CNI_CONDUCTION_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......@@ -54,7 +54,7 @@ struct OnePTwoCNIConductionBox { using InheritsFrom = std::tuple<OnePTwoCNICondu
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::OnePTwoCNIConduction> { using type = Dune::UGGrid<2>; };
#else
......
......@@ -27,7 +27,7 @@
#ifndef DUMUX_1P2CNI_CONVECTION_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P2CNI_CONVECTION_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......@@ -58,7 +58,7 @@ struct OnePTwoCNIConvectionBox { using InheritsFrom = std::tuple<OnePTwoCNIConve
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::OnePTwoCNIConvection> { using type = Dune::UGGrid<2>; };
#else
......
......@@ -26,7 +26,7 @@
#ifndef DUMUX_1P2CNI_TRANSIENT_BC_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P2CNI_TRANSIENT_BC_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......@@ -54,7 +54,7 @@ struct OnePTwoCNITransientBCBox { using InheritsFrom = std::tuple<OnePTwoCNITran
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::OnePTwoCNITransientBC> { using type = Dune::UGGrid<2>; };
#else
......
......@@ -26,7 +26,7 @@
#ifndef DUMUX_1P3C_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P3C_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......@@ -56,7 +56,7 @@ struct MaxwellStefanOnePThreeCTestCCTpfa { using InheritsFrom = std::tuple<Maxwe
} // end namespace TTag
// Set the grid type
#if HAVE_UG
#if HAVE_DUNE_UGGRID
template<class TypeTag>
struct Grid<TypeTag, TTag::MaxwellStefanOnePThreeCTest> { using type = Dune::UGGrid<2>; };
#else
......
......@@ -26,7 +26,7 @@
#ifndef DUMUX_1P2CNI_CONDUCTION_TEST_PROBLEM_PROPERTIES_HH
#define DUMUX_1P2CNI_CONDUCTION_TEST_PROBLEM_PROPERTIES_HH
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......
......@@ -27,7 +27,7 @@
#if HAVE_DUNE_ALUGRID
#include <dune/alugrid/grid.hh>
#endif
#if HAVE_UG
#if HAVE_DUNE_UGGRID
#include <dune/grid/uggrid.hh>
#endif
#include <dune/grid/yaspgrid.hh>
......
......@@ -25,9 +25,9 @@
// As of versions Opm 2018.04 and Dune 2.6, using opm-grid and dune-uggrid
// together results in a compiler error. The following lines enforce that
// dune-uggrid isn't considered.
#if HAVE_UG
#undef HAVE_UG
#define HAVE_UG 0
#if HAVE_DUNE_UGGRID
#undef HAVE_DUNE_UGGRID
#define HAVE_DUNE_UGGRID 0
#endif
#include <iostream>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment