"Can the system successfully run a PETSc executable? This variable can be manually set to \"YES\" to force CMake to accept a given PETSc configuration, but this will almost always result in a broken build. If you change PETSC_DIR, PETSC_ARCH, or PETSC_CURRENT you would have to reset this variable." FORCE)
endif(${${runs}})
endmacro(PETSC_TEST_RUNS)
find_path(PETSC_INCLUDE_DIR petscts.h HINTS "${PETSC_DIR}" PATH_SUFFIXES include NO_DEFAULT_PATH)
if(petsc_works_allincludes)# It does, we just need all the includes (
message(STATUS "PETSc requires extra include paths, but links correctly with only interface libraries. This is an unexpected configuration (but it seems to work fine).")
set(petsc_includes_needed ${petsc_includes_all})
else(petsc_works_allincludes)# We are going to need to link the external libs explicitly
message(STATUS "PETSc only need minimal includes, but requires explicit linking to all dependencies. This is expected when PETSc is built with static libraries.")
message(STATUS "PETSc requires extra include paths and explicit linking to all dependencies. This probably means you have static libraries and something unexpected in PETSc headers.")
else(petsc_works_all)# We fail anyways
message(STATUS "PETSc could not be used, maybe the install is broken.")
endif(petsc_works_all)
endif(petsc_works_alllibraries)
endif(petsc_works_allincludes)
endif(petsc_works_minimal)
# We do an out-of-source build so __FILE__ will be an absolute path, hence __INSDIR__ is superfluous