Only install sundials_mpi_types.h if MPI is enabled and works
@@ -26,7 +26,6 @@ SET(sundials_HEADERS
sundials_fnvector.h
sundials_iterative.h
sundials_math.h
- sundials_mpi_types.h
sundials_nvector.h
sundials_pcg.h
sundials_sparse.h
@@ -37,6 +36,11 @@ SET(sundials_HEADERS
sundials_types.h
)
+# append header file with sundials MPI type macros if using MPI
+IF(MPIC_FOUND)
+ LIST(APPEND sundials_HEADERS sundials_mpi_types.h)
+ENDIF()
+
# Add prefix with complete path to the SUNDIALS header files
ADD_PREFIX(${sundials_SOURCE_DIR}/include/sundials/ sundials_HEADERS)
