diff --git a/AMDiS/AMDISConfig.cmake.in b/AMDiS/AMDISConfig.cmake.in
index b2665f7a8e6fd03f640e64e6e0e4ba93b2564e05..8c84c348c4476afcf831c627c6e8b295c3a3571b 100644
--- a/AMDiS/AMDISConfig.cmake.in
+++ b/AMDiS/AMDISConfig.cmake.in
@@ -114,6 +114,77 @@ if(CMAKE_BUILD_TYPE STREQUAL "")
 	set(CMAKE_BUILD_TYPE "Release")
 endif()
 
+#load mpi-compiler for use with parmetis and parallel_domain
+if(AMDIS_HAS_PARALLEL_DOMAIN)
+	find_package(MPI REQUIRED)
+	if(MPI_FOUND)
+		list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
+		list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
+		list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
+	endif(MPI_FOUND)
+	if(AMDIS_HAS_PARALLEL_DOMAIN STREQUAL "PETSC")		
+		set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${AMDIS_DIR})
+		set(PETSC_EXECUTABLE_RUNS ON)
+		find_package(PETSc REQUIRED)
+		if(PETSC_FOUND)
+			list(APPEND AMDIS_LIBRARIES ${PETSC_LIBRARY_SYS} ${PETSC_LIBRARIES})
+			list(APPEND AMDIS_INCLUDE_DIRS ${PETSC_INCLUDES})
+		else()
+			message(FATAL_ERROR "Could not find PETSc!")
+		endif(PETSC_FOUND)
+	elseif(AMDIS_HAS_PARALLEL_DOMAIN STREQUAL "PMTL")
+		find_package(MTL REQUIRED)
+		list(APPEND AMDIS_LIBRARIES ${MTL_LIBRARIES})
+		find_library(PARMETIS_LIB parmetis)
+		if(PARMETIS_LIB)
+			list(APPEND AMDIS_LIBRARIES ${PARMETIS_LIB})
+		else(PARMETIS_LIB)
+			message(FATAL_ERROR "could not find the parmetis libraries needed by amdis")
+		endif(PARMETIS_LIB)
+		find_library(METIS_LIB metis)
+		if(METIS_LIB)
+			list(APPEND AMDIS_LIBRARIES ${METIS_LIB})
+		else(METIS_LIB)
+			message(FATAL_ERROR "could not find the metis libraries needed by amdis")
+		endif(METIS_LIB)
+	endif()
+	
+elseif(AMDIS_NEED_SEQ_PETSC)
+    find_package(MPI REQUIRED)
+    if(MPI_FOUND)
+	    list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
+	    list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
+	    list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
+    endif(MPI_FOUND)
+	
+  set(CMAKE_MODULE_PATH ${AMDIS_DIR})
+    set(PETSC_EXECUTABLE_RUNS ON)
+    find_package(PETSc REQUIRED)
+    if(PETSC_FOUND)
+	    list(APPEND AMDIS_LIBRARIES ${PETSC_LIBRARY_SYS} ${PETSC_LIBRARIES})
+	    list(APPEND AMDIS_INCLUDE_DIRS ${PETSC_INCLUDES})
+    else()
+	    message(FATAL_ERROR "Could not find PETSc!")
+    endif(PETSC_FOUND)
+endif()
+
+if(AMDIS_NEED_HYPRE)
+  find_package(HYPRE REQUIRED HINTS ${AMDIS_DIR})
+  if(HAVE_HYPRE)
+    if(NOT MPI_FOUND)
+      find_package(MPI REQUIRED)
+      if(MPI_FOUND)
+	    list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
+	    list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
+	    list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
+      endif()
+    endif()
+    list(APPEND AMDIS_INCLUDE_DIRS ${HYPRE_INCLUDE_DIRECTORIES})
+    list(APPEND AMDIS_COMPILEFLAGS "-DMTL_HAS_HYPRE")
+    list(APPEND AMDIS_LIBRARIES ${HYPRE_LIBRARIES} )
+  endif()
+endif(AMDIS_NEED_HYPRE)
+
 if(AMDIS_OPENMP)
   if(CMAKE_CXX_COMPILER MATCHES ".*icpc")
         list(APPEND AMDIS_COMPILEFLAGS "-openmp")
@@ -308,7 +379,7 @@ return (0) ;
 	    if(SUITESPARSECONFIG_LIB)
 	      list(APPEND AMDIS_LIBRARIES ${SUITESPARSECONFIG_LIB})
 	    else()
-	      message(FATAL_ERROR "your umfpack seems to need suitesparseconfig, but cmake could not find it")
+	      message(STATUS "your umfpack seems to need suitesparseconfig, but cmake could not find it")
 	    endif()
 	  endif()
 	  
diff --git a/AMDiS/AMDISUse.cmake b/AMDiS/AMDISUse.cmake
index 35ee52c2defde21569b6d6af97fd1a67ce17b315..8087fe857af2ff1616e56a0d50b7b9ceb5d99849 100644
--- a/AMDiS/AMDISUse.cmake
+++ b/AMDiS/AMDISUse.cmake
@@ -1,74 +1,3 @@
-#load mpi-compiler for use with parmetis and parallel_domain
-if(AMDIS_HAS_PARALLEL_DOMAIN)
-	find_package(MPI REQUIRED)
-	if(MPI_FOUND)
-		list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
-		list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
-		list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
-	endif(MPI_FOUND)
-	if(AMDIS_HAS_PARALLEL_DOMAIN STREQUAL "PETSC")		
-		set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${AMDIS_DIR})
-		set(PETSC_EXECUTABLE_RUNS ON)
-		find_package(PETSc REQUIRED)
-		if(PETSC_FOUND)
-			list(APPEND AMDIS_LIBRARIES ${PETSC_LIBRARY_SYS} ${PETSC_LIBRARIES})
-			list(APPEND AMDIS_INCLUDE_DIRS ${PETSC_INCLUDES})
-		else()
-			message(FATAL_ERROR "Could not find PETSc!")
-		endif(PETSC_FOUND)
-	elseif(AMDIS_HAS_PARALLEL_DOMAIN STREQUAL "PMTL")
-		find_package(MTL REQUIRED)
-		list(APPEND AMDIS_LIBRARIES ${MTL_LIBRARIES})
-		find_library(PARMETIS_LIB parmetis)
-		if(PARMETIS_LIB)
-			list(APPEND AMDIS_LIBRARIES ${PARMETIS_LIB})
-		else(PARMETIS_LIB)
-			message(FATAL_ERROR "could not find the parmetis libraries needed by amdis")
-		endif(PARMETIS_LIB)
-		find_library(METIS_LIB metis)
-		if(METIS_LIB)
-			list(APPEND AMDIS_LIBRARIES ${METIS_LIB})
-		else(METIS_LIB)
-			message(FATAL_ERROR "could not find the metis libraries needed by amdis")
-		endif(METIS_LIB)
-	endif()
-	
-elseif(AMDIS_NEED_SEQ_PETSC)
-    find_package(MPI REQUIRED)
-    if(MPI_FOUND)
-	    list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
-	    list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
-	    list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
-    endif(MPI_FOUND)
-	
-  set(CMAKE_MODULE_PATH ${AMDIS_DIR})
-    set(PETSC_EXECUTABLE_RUNS ON)
-    find_package(PETSc REQUIRED)
-    if(PETSC_FOUND)
-	    list(APPEND AMDIS_LIBRARIES ${PETSC_LIBRARY_SYS} ${PETSC_LIBRARIES})
-	    list(APPEND AMDIS_INCLUDE_DIRS ${PETSC_INCLUDES})
-    else()
-	    message(FATAL_ERROR "Could not find PETSc!")
-    endif(PETSC_FOUND)
-endif()
-
-if(AMDIS_NEED_HYPRE)
-  find_package(HYPRE REQUIRED HINTS ${AMDIS_DIR})
-  if(HAVE_HYPRE)
-    list(APPEND AMDIS_INCLUDE_DIRS ${HYPRE_INCLUDE_DIRECTORIES})
-    list(APPEND AMDIS_COMPILEFLAGS "-DMTL_HAS_HYPRE")
-    list(APPEND AMDIS_LIBRARIES ${HYPRE_LIBRARIES} )
-    if(NOT MPI_FOUND)
-      find_package(MPI REQUIRED)
-      if(MPI_FOUND)
-	    list(APPEND AMDIS_LIBRARIES ${MPI_LIBRARIES})
-	    list(APPEND AMDIS_COMPILEFLAGS ${MPI_COMPILE_FLAGS})
-	    list(APPEND AMDIS_INCLUDE_DIRS ${MPI_INCLUDE_PATH})
-      endif()
-    endif()
-  endif()
-endif(AMDIS_NEED_HYPRE)
-
 #thats bad because it affects each target
 add_definitions(${AMDIS_COMPILEFLAGS})
 include_directories(${AMDIS_INCLUDE_DIRS})