X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=version.sh;h=884c9e2b65f79177f4156d79796167fc03617e04;hb=c76b05fba284c68c6cb7b710dbb95a42089e8538;hp=bf4ccb9e3b71abb3a3899b0a338c479d539c51fd;hpb=8cae1840afb3ea44dcc298f32983e577480dfee4;p=platform%2Fupstream%2Fbtrfs-progs.git diff --git a/version.sh b/version.sh old mode 100644 new mode 100755 index bf4ccb9..884c9e2 --- a/version.sh +++ b/version.sh @@ -5,8 +5,10 @@ # Copyright 2008, Aron Griffis # Copyright 2008, Oracle # Released under the GNU GPLv2 - -v="v3.12" + +v="v4.13.3" + +opt=$1 which git &> /dev/null if [ $? == 0 -a -d .git ]; then @@ -24,16 +26,12 @@ if [ $? == 0 -a -d .git ]; then fi fi -echo "#ifndef __BUILD_VERSION" > .build-version.h -echo "#define __BUILD_VERSION" >> .build-version.h -echo "#define BTRFS_BUILD_VERSION \"Btrfs $v\"" >> .build-version.h -echo "#endif" >> .build-version.h - -diff -q version.h .build-version.h >& /dev/null - -if [ $? == 0 ]; then - rm .build-version.h - exit 0 +if [ "$opt" = "--configure" ]; then + # Omit the trailing newline, so that m4_esyscmd can use the result directly. + echo -n "$v" +else + echo "$v" fi -mv .build-version.h version.h +exit 0 +