summaryrefslogtreecommitdiff
path: root/version.sh
diff options
context:
space:
mode:
Diffstat (limited to 'version.sh')
-rwxr-xr-x[-rw-r--r--]version.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/version.sh b/version.sh
index c6c88f6b..c012e6af 100644..100755
--- a/version.sh
+++ b/version.sh
@@ -8,6 +8,7 @@
v="v3.18.2"
+opt=$1
lib_major=0
lib_minor=1
lib_patchlevel=1
@@ -28,6 +29,12 @@ if [ $? == 0 -a -d .git ]; then
fi
fi
+if [ "$opt" = "--configure" ]; then
+ # Omit the trailing newline, so that m4_esyscmd can use the result directly.
+ echo "$v" | tr -d '\n'
+ exit 0
+fi
+
echo "/* NOTE: this file is autogenerated by version.sh, do not edit */" > .build-version.h
echo "#ifndef __BUILD_VERSION" >> .build-version.h
echo >> .build-version.h