From aee3316243ef1b9735df9572a720568e2cbf0e6d Mon Sep 17 00:00:00 2001 From: Brian Barrett Date: Wed, 7 Sep 2005 19:59:28 +0000 Subject: [PATCH] * just for George, don't try to get the SVN r number if we don't need it. This should speed up autogen.sh on platforms with really slow svnversion searches, as we only need the base version for autogen, which means we don't need the r number. * Since I can't type, add an error message if an invalid argument is given This commit was SVN r7224. --- config/ompi_get_version.sh | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/config/ompi_get_version.sh b/config/ompi_get_version.sh index 865b7ee054..e2ca5f7341 100755 --- a/config/ompi_get_version.sh +++ b/config/ompi_get_version.sh @@ -26,6 +26,16 @@ srcfile="$1" option="$2" +case "$option" in + # svnversion can take a while to run. If we don't need it, don't run it. + --major|--minor|--release|--alpha|--beta|--base|--help) + OMPI_NEED_SVN=0 + ;; + *) + OMPI_NEED_SVN=1 +esac + + if test "$srcfile" = ""; then option="--help" else @@ -50,7 +60,7 @@ else OMPI_BASE_VERSION="$OMPI_VERSION" - if test "$OMPI_WANT_SVN" = "1"; then + if test "$OMPI_WANT_SVN" = "1" -a "$OMPI_NEED_SVN" = "1" ; then if test "$OMPI_SVN_R" = "-1"; then if test -d .svn; then ver="r`svnversion .`" @@ -112,6 +122,10 @@ $0 [