diff --git a/Makefile.am b/Makefile.am
index fe68dd3ecfd63c3fd5a32312108fe9282b2bf542..17c3a973f2ad656533ff54cadecb5f3778a1b471 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -14,8 +14,8 @@ endif
 AUTOMAKE_OPTIONS = foreign 1.5
 
 # pass most important options when "make distcheck" is used
-DISTCHECK_CONFIGURE_FLAGS = --with-dune-common=$(DUNE_COMMON_ROOT) --with-dune-grid=$(DUNE_GRID_ROOT) --with-dune-istl=$(DUNE_ISTL_ROOT)  CXX="$(CXX)" CC="$(CC)"
+# dune-geometry is a dependency of dune-grid.
+DISTCHECK_CONFIGURE_FLAGS = --with-dune-common=$(DUNE_COMMON_ROOT) --with-dune-geometry=$(DUNE_GEOMETRY_ROOT) --with-dune-grid=$(DUNE_GRID_ROOT) --with-dune-istl=$(DUNE_ISTL_ROOT) --with-dune-localfunctions=$(DUNE_LOCALFUNCTIONS_ROOT) CXX="$(CXX)" CC="$(CC)"
 
 include $(top_srcdir)/am/top-rules
 include $(top_srcdir)/am/global-rules
-