mpich2: add Fortran support (enabled by default)
A user can pass `--disable-fortran` to avoid compiling the Fortran bindings. Also remove the redundant default `--with-device=ch3:nemesis` argument to configure. Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
This commit is contained in:
parent
491dacde27
commit
02de6060f9
1 changed files with 18 additions and 6 deletions
|
@ -6,13 +6,25 @@ class Mpich2 < Formula
|
|||
version '1.4.1p1'
|
||||
md5 'b470666749bcb4a0449a072a18e2c204'
|
||||
|
||||
def options
|
||||
[
|
||||
['--disable-fortran', "Do not attempt to build Fortran bindings"],
|
||||
]
|
||||
end
|
||||
|
||||
def install
|
||||
system "./configure", "--prefix=#{prefix}",
|
||||
"--mandir=#{man}",
|
||||
"--disable-f77",
|
||||
"--disable-fc",
|
||||
"--with-device=ch3:nemesis",
|
||||
"--enable-shared"
|
||||
args = [
|
||||
"--prefix=#{prefix}",
|
||||
"--mandir=#{man}",
|
||||
"--enable-shared"
|
||||
]
|
||||
if ARGV.include? '--disable-fortran'
|
||||
args << "--disable-f77" << "--disable-fc"
|
||||
else
|
||||
ENV.fortran
|
||||
end
|
||||
|
||||
system "./configure", *args
|
||||
system "make"
|
||||
system "make install"
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue