diff options
author | knarf <knarf@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2013-02-21 18:58:35 +0000 |
---|---|---|
committer | knarf <knarf@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2013-02-21 18:58:35 +0000 |
commit | f9f8fb05dc03fa339e37a04608009f62e4fcc3b0 (patch) | |
tree | f04803314b60bf5f93c56e1799dc8f081bcea0d7 /lib/make/known-architectures | |
parent | 43b44fdf6a8524dda6afe9bac0342eeba5ac5835 (diff) |
Currently, known_architectures/linux only looks at the first line of '$F77
--version' to determine the version of a gnu-type fortran compiler. However, on
bluewaters this returns
{{{
/opt/cray/xt-asyncpe/5.16/bin/ftn: INFO: Compiling with CRAYPE_COMPILE_TARGET=native.
GNU Fortran (GCC) 4.7.2 20120920 (Cray Inc.)
Copyright (C) 2012 Free Software Foundation, Inc.
}}}
The information the script is actually interested in is on the second line, not
the first. Thus, I propose the attached patch (grepping for "GNU" before
choosing the first line). I didn't find a problem with this patch on other
machines, but there might be in case $F77 --version does not contain GNU in the
line with the version.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4958 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib/make/known-architectures')
-rw-r--r-- | lib/make/known-architectures/linux | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/make/known-architectures/linux b/lib/make/known-architectures/linux index 1e0475e4..990dc9a4 100644 --- a/lib/make/known-architectures/linux +++ b/lib/make/known-architectures/linux @@ -143,8 +143,8 @@ else : ${LIBS='gfortran'} : ${LIBDIRS="$gnu95_libdir"} fi - F77_VERSION="`$F77 --version 2>&1 | head -n1`" - F90_VERSION="`$F90 --version 2>&1 | head -n1`" + F77_VERSION="`$F77 --version 2>&1 | grep GNU | head -n1`" + F90_VERSION="`$F90 --version 2>&1 | grep GNU | head -n1`" # only gfortran versions 4.1 and higher support OpenMP major_version=`echo $F77_VERSION | cut -d')' -f2 | tr -d ' ' | cut -d'.' -f1` minor_version=`echo $F77_VERSION | cut -d')' -f2 | cut -d'.' -f2` |