diff --git a/var/spack/repos/builtin/packages/mvapich2/package.py b/var/spack/repos/builtin/packages/mvapich2/package.py index 030e03b7f1..c3e9f1c2f4 100644 --- a/var/spack/repos/builtin/packages/mvapich2/package.py +++ b/var/spack/repos/builtin/packages/mvapich2/package.py @@ -199,6 +199,9 @@ def file_system_options(self): def setup_environment(self, spack_env, run_env): spec = self.spec + # mvapich2 configure fails when F90 and F90FLAGS are set + spack_env.unset('F90') + spack_env.unset('F90FLAGS') if 'process_managers=slurm' in spec: run_env.set('SLURM_MPI_TYPE', 'pmi2')