hongbinLi Peter
hongbinLi Peter

Reputation: 1

Install mpich with g77 compiler

I need to run Fortran77 programs with mpich3.1.4 on ubuntu 13.04. After installing mpich on my computer, there are some files in the mpi-install/bin directory, mpif77 and mpif90 files included, both files are connected to the file named mpifort.

But when I compile Fortran77 programs, I get some gfortran errors. So I think mpich3.1.4 have no relationships with g77 compiler on my computer after having installed mpich. So, I uninstalled gfortran or install mpich3.1.4 with command

./configure --disable-fc -prefix=*****

But then, I get an error:

no Fortran 77 compiler found(configure: error: No Fortran 77 compiler found. If you don't need to build any Fortran programs, you can disable Fortran support using --disable-fortran. If you do want to build Fortran programs, you need to install a Fortran compiler such as gfortran or ifort before you can proceed)

However, I am sure there is Fortran 77 compiler on my computer, the version of this compiler is GNU Fortran (GCC) 3.4.6 (Ubuntu 3.4.6-6ubuntu3) Copyright (C) 2006 Free Software Foundation, Inc.

So I want to know how to install mpich3.1.4 with g77 compiler.Is there anybody who has any suggestions about this?

Upvotes: 0

Views: 1763

Answers (1)

Rob Latham
Rob Latham

Reputation: 5223

Are you sure gfortran will not work for you? While I do not have a ton of fortran experience, MPICH does have several fortran77 test cases, and these are routinely built with gfortran.

If you really need g77, one way you can do this is to override MPICH's compiler detection:

$  configure FC=g77 --prefix=/path/to/wherever 

MPICH is trying to move away from the F77 and F90 environment variables.

Upvotes: 1

Related Questions