I've been trying to build the openmpi 1.2 branch with the Intel and
Portland Fortran compilers and was having trouble using their
First off, it seems the only way to get these options to appear in the
necessary link lines is to add them to the compiler variable itself, e.g.:
However, this causes problems with some configure checks in setting the
OMPI_F90_ABSOLUTE and similar variables, because "which" complains about
the extra arguments. I ended up making the following change:
--- openmpi-1.2-20061010/config/ompi_setup_f77.m4.which 2006-10-12
+++ openmpi-1.2-20061010/config/ompi_setup_f77.m4 2006-10-12
@@ -59,7 +59,7 @@
- OMPI_F77_ABSOLUTE="`which $F77`"
+ OMPI_F77_ABSOLUTE="`which $BASEF77`"
if test "$OMPI_WANT_F77_BINDINGS" = "0" ; then
AC_MSG_WARN([*** Fortran 77 bindings disabled by user])
--- openmpi-1.2-20061010/config/ompi_setup_f90.m4.which 2006-10-12
+++ openmpi-1.2-20061010/config/ompi_setup_f90.m4 2006-10-12
@@ -88,7 +88,7 @@
- OMPI_F90_ABSOLUTE="`which $FC`"
+ OMPI_F90_ABSOLUTE="`which $BASEF90`"
# make sure the compiler actually works, if not cross-compiling
which works for a single extra argument because basename doesn't
complain. However, basename does complain if you give it more
arguments. Something more general might be:
BASEF90=`echo $FC | sed 's/ .*//'`
I'm not sure what the most cross platform way to return only the first
Of course, if there was a way to get these passed to the appropriate
link stages, we could avoid this. But it looks like libtool strips the
-i-static argument and doesn't pass it on to the link command, not sure
about the -Bstatic_pgi argument.
System Administrator 303-415-9701 x222
NWRA/CoRA Division FAX: 303-415-9702
3380 Mitchell Lane orion_at_[hidden]
Boulder, CO 80301 http://www.cora.nwra.com