--- MITgcm/tools/genmake2 2009/11/04 16:58:57 1.199 +++ MITgcm/tools/genmake2 2009/11/30 21:50:35 1.200 @@ -1,6 +1,6 @@ #! /usr/bin/env bash # -# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/tools/genmake2,v 1.199 2009/11/04 16:58:57 utke Exp $ +# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/tools/genmake2,v 1.200 2009/11/30 21:50:35 jmc Exp $ # # Makefile generator for MITgcm UV codes # created by cnh 03/98 @@ -1405,7 +1405,7 @@ # Find the MITgcm ${THISVER} version_file="${ROOTDIR}/doc/tag-index" if test -f $version_file ; then - THISVER=`grep '^checkpoint' $version_file | head -1` + THISVER=`$AWK '/^checkpoint/{print $1; exit}' $version_file` #- remove ./BUILD_INFO.h file if older than version_file if test -f ./BUILD_INFO.h -a ./BUILD_INFO.h -ot $version_file ; then echo " remove ./BUILD_INFO.h (older than ${version_file})"