diff --git a/dune/istl/paamg/test/pthreadtwoleveltest.cc b/dune/istl/paamg/test/pthreadtwoleveltest.cc
index cfe098aac8af4f9b674a98a2c6a0e34a18e81466..02dee5d08ecd123717192485827f3452b18f4cd5 100644
--- a/dune/istl/paamg/test/pthreadtwoleveltest.cc
+++ b/dune/istl/paamg/test/pthreadtwoleveltest.cc
@@ -1,6 +1,7 @@
 #include"config.h"
 #include "anisotropic.hh"
 #include <dune/common/timer.hh>
+#include <dune/common/shared_ptr.hh>
 #include <dune/common/parallel/indexset.hh>
 #include <dune/common/parallel/collectivecommunication.hh>
 #include <dune/istl/paamg/twolevelmethod.hh>
diff --git a/dune/istl/paamg/test/twolevelmethodtest.cc b/dune/istl/paamg/test/twolevelmethodtest.cc
index ee23a812cfea26a58000fb0623588afb6aca6eb1..1dfa3b8ba6a90d88ef4ce741f3d6fd06bcd0e61a 100644
--- a/dune/istl/paamg/test/twolevelmethodtest.cc
+++ b/dune/istl/paamg/test/twolevelmethodtest.cc
@@ -1,6 +1,7 @@
 #include"config.h"
 #include "anisotropic.hh"
 #include <dune/common/timer.hh>
+#include <dune/common/shared_ptr.hh>
 #include <dune/common/parallel/indexset.hh>
 #include <dune/common/parallel/collectivecommunication.hh>
 #include <dune/istl/paamg/twolevelmethod.hh>