Restore Builds With Dune in Non-Default Installed Locations

In general we'd need to link to dune-common ("target_link_library")
to get the appropriate include directories for Dune in that case,
but in this specific instance we can get by with not specialising
Dune's 'className' function if Dune is not available.

Thanks to [at]akva2 for suggesting this workaround.
This commit is contained in:
Bård Skaflestad
2023-03-16 11:57:24 +01:00
parent 32b104f828
commit bdf6951e62

View File

@@ -336,6 +336,8 @@ inline bool isinf(quad val)
} // namespace std
#if HAVE_DUNE_COMMON
// specialize Dune::className for __float128 since it former does not work properly with
// __float128 (this is mainly the fault of GCC/libstdc++)
#include <dune/common/classname.hh>
@@ -346,6 +348,8 @@ inline std::string className<__float128>()
{ return "quad"; }
} // namespace Dune
#endif // HAVE_DUNE_COMMON
#if HAVE_DUNE_FEM
#include <dune/fem/io/streams/streams_inline.hh>