Skip to content

Instantly share code, notes, and snippets.

@mjhsieh
Created February 9, 2011 22:28
Show Gist options
  • Save mjhsieh/819457 to your computer and use it in GitHub Desktop.
Save mjhsieh/819457 to your computer and use it in GitHub Desktop.
a replacement of mpif90 for AmberTools building process
#!/bin/bash
# 345678901234567890123456789012345678901234567890123456789012345678901234567890
# Usage: (stock lammpi 7.1.4 in my OSCAR cluster was compiled with gcc/gfortran)
# env LAMMPICC=icc LAMMPIF77=ifort mpif90
# env LAMMPIF77=g95 mpif90
# 345678901234567890123456789012345678901234567890123456789012345678901234567890
mystring="$(mpif77 -show)"
if [[ "$mystring" =~ "lamf77mpi" ]]; then
# lam 7.1.4 doesn't have mpif90
mpif77 $*
else
# other mpi
mpif90 $*
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment