diff --git a/cmake/modules/DuneMacros.cmake b/cmake/modules/DuneMacros.cmake
index fc192bef8bd58563e732ca0ed1836c61395f1a20..3f232e763210f7e3ce80d7d5d15d64c4deebc7a2 100644
--- a/cmake/modules/DuneMacros.cmake
+++ b/cmake/modules/DuneMacros.cmake
@@ -274,7 +274,9 @@ macro(dune_create_dependency_leafs depends depends_versions suggests suggests_ve
 endmacro(dune_create_dependency_leafs)
 
 macro(dune_create_dependency_tree)
-  list(REMOVE_ITEM CMAKE_MODULE_PATH ${dune-common_MODULE_PATH})
+  if(${dune-common_MODULE_PATH})
+    list(REMOVE_ITEM CMAKE_MODULE_PATH ${dune-common_MODULE_PATH})
+  endif(${dune-common_MODULE_PATH})
   list(FIND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules start)
   set(ALL_DEPENDENCIES "")
   if(DEPENDS_MODULE OR SUGGESTS_MODULE)