[MPlayer-cvslog] r32978 - trunk/version.sh
reimar
subversion at mplayerhq.hu
Sun Feb 27 16:14:23 CET 2011
Author: reimar
Date: Sun Feb 27 16:14:23 2011
New Revision: 32978
Log:
Do not run svn or otherwise try to extract the svn revision when
we have a VERSION file we'll be using anyway.
Modified:
trunk/version.sh
Modified: trunk/version.sh
==============================================================================
--- trunk/version.sh Sun Feb 27 15:32:24 2011 (r32977)
+++ trunk/version.sh Sun Feb 27 16:14:23 2011 (r32978)
@@ -2,6 +2,10 @@
test "$1" && extra="-$1"
+# releases extract the version number from the VERSION file
+version=$(cat VERSION 2> /dev/null)
+
+if test -z $version ; then
# Extract revision number from file used by daily tarball snapshots
# or from the places different Subversion versions have it.
svn_revision=$(cat snapshot_version 2> /dev/null)
@@ -10,10 +14,8 @@ test $svn_revision || svn_revision=$(gre
test $svn_revision || svn_revision=$(sed -n -e '/^dir$/{n;p;q;}' .svn/entries 2>/dev/null)
test $svn_revision && svn_revision=SVN-r$svn_revision
test $svn_revision || svn_revision=UNKNOWN
-
-# releases extract the version number from the VERSION file
-version=$(cat VERSION 2> /dev/null)
-test $version || version=$svn_revision
+version=$svn_revision
+fi
NEW_REVISION="#define VERSION \"${version}${extra}\""
OLD_REVISION=$(head -n 1 version.h 2> /dev/null)
More information about the MPlayer-cvslog
mailing list